scratch-blocks 1.2.0-beta.1 → 2.0.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1064) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/package.json +1 -1
  3. package/blockly-rc/.eslintignore +0 -28
  4. package/blockly-rc/.eslintrc.js +0 -187
  5. package/blockly-rc/.gitattributes +0 -1
  6. package/blockly-rc/.github/CODEOWNERS +0 -1
  7. package/blockly-rc/.github/CONTRIBUTING.md +0 -46
  8. package/blockly-rc/.github/ISSUE_TEMPLATE/bug_report.yaml +0 -58
  9. package/blockly-rc/.github/ISSUE_TEMPLATE/config.yml +0 -7
  10. package/blockly-rc/.github/ISSUE_TEMPLATE/documentation.yaml +0 -38
  11. package/blockly-rc/.github/ISSUE_TEMPLATE/feature_request.yaml +0 -39
  12. package/blockly-rc/.github/PULL_REQUEST_TEMPLATE.md +0 -42
  13. package/blockly-rc/.github/dependabot.yml +0 -27
  14. package/blockly-rc/.github/release.yml +0 -32
  15. package/blockly-rc/.github/workflows/appengine_deploy.yml +0 -54
  16. package/blockly-rc/.github/workflows/assign_reviewers.yml +0 -41
  17. package/blockly-rc/.github/workflows/browser_test.yml +0 -55
  18. package/blockly-rc/.github/workflows/build.yml +0 -86
  19. package/blockly-rc/.github/workflows/conventional-label.yml +0 -17
  20. package/blockly-rc/.github/workflows/develop_freeze.yml +0 -26
  21. package/blockly-rc/.github/workflows/tag_module_cleanup.yml +0 -37
  22. package/blockly-rc/.github/workflows/welcome_new_contributors.yml +0 -36
  23. package/blockly-rc/.prettierignore +0 -30
  24. package/blockly-rc/.prettierrc.js +0 -13
  25. package/blockly-rc/CHANGELOG.md +0 -77
  26. package/blockly-rc/LICENSE +0 -202
  27. package/blockly-rc/README.md +0 -80
  28. package/blockly-rc/_config.yml +0 -1
  29. package/blockly-rc/api-extractor.json +0 -385
  30. package/blockly-rc/appengine/.gcloudignore +0 -20
  31. package/blockly-rc/appengine/README.txt +0 -42
  32. package/blockly-rc/appengine/add_timestamps.py +0 -69
  33. package/blockly-rc/appengine/app.yaml +0 -104
  34. package/blockly-rc/appengine/apple-touch-icon.png +0 -0
  35. package/blockly-rc/appengine/blockly_compressed.js +0 -11
  36. package/blockly-rc/appengine/expiration.py +0 -52
  37. package/blockly-rc/appengine/favicon.ico +0 -0
  38. package/blockly-rc/appengine/index.yaml +0 -11
  39. package/blockly-rc/appengine/main.py +0 -39
  40. package/blockly-rc/appengine/redirect.html +0 -107
  41. package/blockly-rc/appengine/requirements.txt +0 -1
  42. package/blockly-rc/appengine/robots.txt +0 -2
  43. package/blockly-rc/appengine/storage.js +0 -190
  44. package/blockly-rc/appengine/storage.py +0 -125
  45. package/blockly-rc/blocks/blocks.ts +0 -44
  46. package/blockly-rc/blocks/lists.ts +0 -1085
  47. package/blockly-rc/blocks/logic.ts +0 -712
  48. package/blockly-rc/blocks/loops.ts +0 -408
  49. package/blockly-rc/blocks/math.ts +0 -591
  50. package/blockly-rc/blocks/procedures.ts +0 -1364
  51. package/blockly-rc/blocks/text.ts +0 -1007
  52. package/blockly-rc/blocks/variables.ts +0 -183
  53. package/blockly-rc/blocks/variables_dynamic.ts +0 -194
  54. package/blockly-rc/core/any_aliases.ts +0 -8
  55. package/blockly-rc/core/block.ts +0 -2523
  56. package/blockly-rc/core/block_animations.ts +0 -225
  57. package/blockly-rc/core/block_flyout_inflater.ts +0 -262
  58. package/blockly-rc/core/block_svg.ts +0 -1768
  59. package/blockly-rc/core/blockly.ts +0 -605
  60. package/blockly-rc/core/blockly_options.ts +0 -71
  61. package/blockly-rc/core/blocks.ts +0 -18
  62. package/blockly-rc/core/browser_events.ts +0 -244
  63. package/blockly-rc/core/bubbles/bubble.ts +0 -658
  64. package/blockly-rc/core/bubbles/mini_workspace_bubble.ts +0 -280
  65. package/blockly-rc/core/bubbles/text_bubble.ts +0 -103
  66. package/blockly-rc/core/bubbles/textinput_bubble.ts +0 -344
  67. package/blockly-rc/core/bubbles.ts +0 -12
  68. package/blockly-rc/core/bump_objects.ts +0 -192
  69. package/blockly-rc/core/button_flyout_inflater.ts +0 -63
  70. package/blockly-rc/core/clipboard/block_paster.ts +0 -142
  71. package/blockly-rc/core/clipboard/registry.ts +0 -31
  72. package/blockly-rc/core/clipboard/workspace_comment_paster.ts +0 -94
  73. package/blockly-rc/core/clipboard.ts +0 -113
  74. package/blockly-rc/core/comments/comment_view.ts +0 -899
  75. package/blockly-rc/core/comments/rendered_workspace_comment.ts +0 -297
  76. package/blockly-rc/core/comments/workspace_comment.ts +0 -237
  77. package/blockly-rc/core/comments.ts +0 -9
  78. package/blockly-rc/core/common.ts +0 -305
  79. package/blockly-rc/core/component_manager.ts +0 -235
  80. package/blockly-rc/core/config.ts +0 -65
  81. package/blockly-rc/core/connection.ts +0 -793
  82. package/blockly-rc/core/connection_checker.ts +0 -348
  83. package/blockly-rc/core/connection_db.ts +0 -297
  84. package/blockly-rc/core/connection_type.ts +0 -21
  85. package/blockly-rc/core/constants.ts +0 -23
  86. package/blockly-rc/core/contextmenu.ts +0 -268
  87. package/blockly-rc/core/contextmenu_items.ts +0 -700
  88. package/blockly-rc/core/contextmenu_registry.ts +0 -194
  89. package/blockly-rc/core/css.ts +0 -481
  90. package/blockly-rc/core/delete_area.ts +0 -77
  91. package/blockly-rc/core/dialog.ts +0 -121
  92. package/blockly-rc/core/drag_target.ts +0 -97
  93. package/blockly-rc/core/dragging/block_drag_strategy.ts +0 -454
  94. package/blockly-rc/core/dragging/bubble_drag_strategy.ts +0 -52
  95. package/blockly-rc/core/dragging/comment_drag_strategy.ts +0 -91
  96. package/blockly-rc/core/dragging/dragger.ts +0 -163
  97. package/blockly-rc/core/dragging.ts +0 -12
  98. package/blockly-rc/core/dropdowndiv.ts +0 -768
  99. package/blockly-rc/core/events/events.ts +0 -163
  100. package/blockly-rc/core/events/events_abstract.ts +0 -130
  101. package/blockly-rc/core/events/events_block_base.ts +0 -88
  102. package/blockly-rc/core/events/events_block_change.ts +0 -259
  103. package/blockly-rc/core/events/events_block_create.ts +0 -185
  104. package/blockly-rc/core/events/events_block_delete.ts +0 -182
  105. package/blockly-rc/core/events/events_block_drag.ts +0 -116
  106. package/blockly-rc/core/events/events_block_field_intermediate_change.ts +0 -167
  107. package/blockly-rc/core/events/events_block_move.ts +0 -307
  108. package/blockly-rc/core/events/events_bubble_open.ts +0 -120
  109. package/blockly-rc/core/events/events_click.ts +0 -110
  110. package/blockly-rc/core/events/events_comment_base.ts +0 -126
  111. package/blockly-rc/core/events/events_comment_change.ts +0 -161
  112. package/blockly-rc/core/events/events_comment_collapse.ts +0 -103
  113. package/blockly-rc/core/events/events_comment_create.ts +0 -118
  114. package/blockly-rc/core/events/events_comment_delete.ts +0 -117
  115. package/blockly-rc/core/events/events_comment_drag.ts +0 -99
  116. package/blockly-rc/core/events/events_comment_move.ts +0 -207
  117. package/blockly-rc/core/events/events_comment_resize.ts +0 -174
  118. package/blockly-rc/core/events/events_marker_move.ts +0 -134
  119. package/blockly-rc/core/events/events_selected.ts +0 -98
  120. package/blockly-rc/core/events/events_theme_change.ts +0 -84
  121. package/blockly-rc/core/events/events_toolbox_item_select.ts +0 -96
  122. package/blockly-rc/core/events/events_trashcan_open.ts +0 -88
  123. package/blockly-rc/core/events/events_ui_base.ts +0 -47
  124. package/blockly-rc/core/events/events_var_base.ts +0 -89
  125. package/blockly-rc/core/events/events_var_create.ts +0 -129
  126. package/blockly-rc/core/events/events_var_delete.ts +0 -124
  127. package/blockly-rc/core/events/events_var_rename.ts +0 -133
  128. package/blockly-rc/core/events/events_var_type_change.ts +0 -122
  129. package/blockly-rc/core/events/events_viewport.ts +0 -149
  130. package/blockly-rc/core/events/utils.ts +0 -595
  131. package/blockly-rc/core/events/workspace_events.ts +0 -46
  132. package/blockly-rc/core/extensions.ts +0 -491
  133. package/blockly-rc/core/field.ts +0 -1471
  134. package/blockly-rc/core/field_checkbox.ts +0 -271
  135. package/blockly-rc/core/field_dropdown.ts +0 -857
  136. package/blockly-rc/core/field_image.ts +0 -297
  137. package/blockly-rc/core/field_input.ts +0 -755
  138. package/blockly-rc/core/field_label.ts +0 -150
  139. package/blockly-rc/core/field_label_serializable.ts +0 -73
  140. package/blockly-rc/core/field_number.ts +0 -381
  141. package/blockly-rc/core/field_registry.ts +0 -115
  142. package/blockly-rc/core/field_textinput.ts +0 -117
  143. package/blockly-rc/core/field_variable.ts +0 -651
  144. package/blockly-rc/core/flyout_base.ts +0 -968
  145. package/blockly-rc/core/flyout_button.ts +0 -416
  146. package/blockly-rc/core/flyout_horizontal.ts +0 -374
  147. package/blockly-rc/core/flyout_metrics_manager.ts +0 -90
  148. package/blockly-rc/core/flyout_separator.ts +0 -61
  149. package/blockly-rc/core/flyout_vertical.ts +0 -353
  150. package/blockly-rc/core/generator.ts +0 -611
  151. package/blockly-rc/core/gesture.ts +0 -1191
  152. package/blockly-rc/core/grid.ts +0 -252
  153. package/blockly-rc/core/icons/comment_icon.ts +0 -435
  154. package/blockly-rc/core/icons/exceptions.ts +0 -23
  155. package/blockly-rc/core/icons/icon.ts +0 -147
  156. package/blockly-rc/core/icons/icon_types.ts +0 -32
  157. package/blockly-rc/core/icons/mutator_icon.ts +0 -354
  158. package/blockly-rc/core/icons/registry.ts +0 -33
  159. package/blockly-rc/core/icons/warning_icon.ts +0 -219
  160. package/blockly-rc/core/icons.ts +0 -24
  161. package/blockly-rc/core/inject.ts +0 -428
  162. package/blockly-rc/core/inputs/align.ts +0 -14
  163. package/blockly-rc/core/inputs/dummy_input.ts +0 -26
  164. package/blockly-rc/core/inputs/end_row_input.ts +0 -31
  165. package/blockly-rc/core/inputs/input.ts +0 -318
  166. package/blockly-rc/core/inputs/input_types.ts +0 -27
  167. package/blockly-rc/core/inputs/statement_input.ts +0 -34
  168. package/blockly-rc/core/inputs/value_input.ts +0 -30
  169. package/blockly-rc/core/inputs.ts +0 -23
  170. package/blockly-rc/core/insertion_marker_manager.ts +0 -742
  171. package/blockly-rc/core/insertion_marker_previewer.ts +0 -254
  172. package/blockly-rc/core/interfaces/i_ast_node_location.ts +0 -12
  173. package/blockly-rc/core/interfaces/i_ast_node_location_svg.ts +0 -28
  174. package/blockly-rc/core/interfaces/i_ast_node_location_with_block.ts +0 -22
  175. package/blockly-rc/core/interfaces/i_autohideable.ts +0 -22
  176. package/blockly-rc/core/interfaces/i_bounded_element.ts +0 -30
  177. package/blockly-rc/core/interfaces/i_bubble.ts +0 -63
  178. package/blockly-rc/core/interfaces/i_collapsible_toolbox_item.ts +0 -33
  179. package/blockly-rc/core/interfaces/i_comment_icon.ts +0 -47
  180. package/blockly-rc/core/interfaces/i_component.ts +0 -19
  181. package/blockly-rc/core/interfaces/i_connection_checker.ts +0 -100
  182. package/blockly-rc/core/interfaces/i_connection_previewer.ts +0 -50
  183. package/blockly-rc/core/interfaces/i_contextmenu.ts +0 -16
  184. package/blockly-rc/core/interfaces/i_copyable.ts +0 -31
  185. package/blockly-rc/core/interfaces/i_deletable.ts +0 -34
  186. package/blockly-rc/core/interfaces/i_delete_area.ts +0 -28
  187. package/blockly-rc/core/interfaces/i_drag_target.ts +0 -69
  188. package/blockly-rc/core/interfaces/i_draggable.ts +0 -72
  189. package/blockly-rc/core/interfaces/i_dragger.ts +0 -35
  190. package/blockly-rc/core/interfaces/i_flyout.ts +0 -189
  191. package/blockly-rc/core/interfaces/i_flyout_inflater.ts +0 -41
  192. package/blockly-rc/core/interfaces/i_has_bubble.ts +0 -20
  193. package/blockly-rc/core/interfaces/i_icon.ts +0 -114
  194. package/blockly-rc/core/interfaces/i_keyboard_accessible.ts +0 -21
  195. package/blockly-rc/core/interfaces/i_legacy_procedure_blocks.ts +0 -50
  196. package/blockly-rc/core/interfaces/i_metrics_manager.ts +0 -149
  197. package/blockly-rc/core/interfaces/i_movable.ts +0 -19
  198. package/blockly-rc/core/interfaces/i_observable.ts +0 -24
  199. package/blockly-rc/core/interfaces/i_parameter_model.ts +0 -51
  200. package/blockly-rc/core/interfaces/i_paster.ts +0 -25
  201. package/blockly-rc/core/interfaces/i_positionable.ts +0 -33
  202. package/blockly-rc/core/interfaces/i_procedure_block.ts +0 -27
  203. package/blockly-rc/core/interfaces/i_procedure_map.ts +0 -18
  204. package/blockly-rc/core/interfaces/i_procedure_model.ts +0 -71
  205. package/blockly-rc/core/interfaces/i_registrable.ts +0 -12
  206. package/blockly-rc/core/interfaces/i_rendered_element.ts +0 -22
  207. package/blockly-rc/core/interfaces/i_selectable.ts +0 -34
  208. package/blockly-rc/core/interfaces/i_selectable_toolbox_item.ts +0 -63
  209. package/blockly-rc/core/interfaces/i_serializable.ts +0 -28
  210. package/blockly-rc/core/interfaces/i_serializer.ts +0 -55
  211. package/blockly-rc/core/interfaces/i_styleable.ts +0 -26
  212. package/blockly-rc/core/interfaces/i_toolbox.ts +0 -112
  213. package/blockly-rc/core/interfaces/i_toolbox_item.ts +0 -81
  214. package/blockly-rc/core/interfaces/i_variable_backed_parameter_model.ts +0 -23
  215. package/blockly-rc/core/interfaces/i_variable_map.ts +0 -65
  216. package/blockly-rc/core/interfaces/i_variable_model.ts +0 -57
  217. package/blockly-rc/core/internal_constants.ts +0 -47
  218. package/blockly-rc/core/keyboard_nav/ast_node.ts +0 -884
  219. package/blockly-rc/core/keyboard_nav/basic_cursor.ts +0 -223
  220. package/blockly-rc/core/keyboard_nav/cursor.ts +0 -138
  221. package/blockly-rc/core/keyboard_nav/marker.ts +0 -113
  222. package/blockly-rc/core/keyboard_nav/tab_navigate_cursor.ts +0 -46
  223. package/blockly-rc/core/label_flyout_inflater.ts +0 -59
  224. package/blockly-rc/core/layer_manager.ts +0 -186
  225. package/blockly-rc/core/layers.ts +0 -17
  226. package/blockly-rc/core/main.ts +0 -31
  227. package/blockly-rc/core/marker_manager.ts +0 -189
  228. package/blockly-rc/core/menu.ts +0 -463
  229. package/blockly-rc/core/menuitem.ts +0 -221
  230. package/blockly-rc/core/metrics_manager.ts +0 -486
  231. package/blockly-rc/core/msg.ts +0 -27
  232. package/blockly-rc/core/names.ts +0 -275
  233. package/blockly-rc/core/observable_procedure_map.ts +0 -66
  234. package/blockly-rc/core/options.ts +0 -377
  235. package/blockly-rc/core/positionable_helpers.ts +0 -186
  236. package/blockly-rc/core/procedures.ts +0 -510
  237. package/blockly-rc/core/registry.ts +0 -400
  238. package/blockly-rc/core/render_management.ts +0 -193
  239. package/blockly-rc/core/rendered_connection.ts +0 -571
  240. package/blockly-rc/core/renderers/common/block_rendering.ts +0 -120
  241. package/blockly-rc/core/renderers/common/constants.ts +0 -1198
  242. package/blockly-rc/core/renderers/common/drawer.ts +0 -518
  243. package/blockly-rc/core/renderers/common/i_path_object.ts +0 -137
  244. package/blockly-rc/core/renderers/common/info.ts +0 -767
  245. package/blockly-rc/core/renderers/common/marker_svg.ts +0 -765
  246. package/blockly-rc/core/renderers/common/path_object.ts +0 -324
  247. package/blockly-rc/core/renderers/common/renderer.ts +0 -281
  248. package/blockly-rc/core/renderers/geras/constants.ts +0 -46
  249. package/blockly-rc/core/renderers/geras/drawer.ts +0 -167
  250. package/blockly-rc/core/renderers/geras/geras.ts +0 -31
  251. package/blockly-rc/core/renderers/geras/highlight_constants.ts +0 -342
  252. package/blockly-rc/core/renderers/geras/highlighter.ts +0 -313
  253. package/blockly-rc/core/renderers/geras/info.ts +0 -478
  254. package/blockly-rc/core/renderers/geras/measurables/inline_input.ts +0 -37
  255. package/blockly-rc/core/renderers/geras/measurables/statement_input.ts +0 -36
  256. package/blockly-rc/core/renderers/geras/path_object.ts +0 -135
  257. package/blockly-rc/core/renderers/geras/renderer.ts +0 -124
  258. package/blockly-rc/core/renderers/measurables/base.ts +0 -41
  259. package/blockly-rc/core/renderers/measurables/bottom_row.ts +0 -104
  260. package/blockly-rc/core/renderers/measurables/connection.ts +0 -43
  261. package/blockly-rc/core/renderers/measurables/external_value_input.ts +0 -53
  262. package/blockly-rc/core/renderers/measurables/field.ts +0 -50
  263. package/blockly-rc/core/renderers/measurables/hat.ts +0 -33
  264. package/blockly-rc/core/renderers/measurables/icon.ts +0 -42
  265. package/blockly-rc/core/renderers/measurables/in_row_spacer.ts +0 -29
  266. package/blockly-rc/core/renderers/measurables/inline_input.ts +0 -63
  267. package/blockly-rc/core/renderers/measurables/input_connection.ts +0 -57
  268. package/blockly-rc/core/renderers/measurables/input_row.ts +0 -67
  269. package/blockly-rc/core/renderers/measurables/jagged_edge.ts +0 -28
  270. package/blockly-rc/core/renderers/measurables/next_connection.ts +0 -34
  271. package/blockly-rc/core/renderers/measurables/output_connection.ts +0 -43
  272. package/blockly-rc/core/renderers/measurables/previous_connection.ts +0 -34
  273. package/blockly-rc/core/renderers/measurables/round_corner.ts +0 -34
  274. package/blockly-rc/core/renderers/measurables/row.ts +0 -191
  275. package/blockly-rc/core/renderers/measurables/spacer_row.ts +0 -44
  276. package/blockly-rc/core/renderers/measurables/square_corner.ts +0 -32
  277. package/blockly-rc/core/renderers/measurables/statement_input.ts +0 -41
  278. package/blockly-rc/core/renderers/measurables/top_row.ts +0 -110
  279. package/blockly-rc/core/renderers/measurables/types.ts +0 -319
  280. package/blockly-rc/core/renderers/thrasos/info.ts +0 -328
  281. package/blockly-rc/core/renderers/thrasos/renderer.ts +0 -40
  282. package/blockly-rc/core/renderers/thrasos/thrasos.ts +0 -14
  283. package/blockly-rc/core/renderers/zelos/constants.ts +0 -877
  284. package/blockly-rc/core/renderers/zelos/drawer.ts +0 -274
  285. package/blockly-rc/core/renderers/zelos/info.ts +0 -652
  286. package/blockly-rc/core/renderers/zelos/marker_svg.ts +0 -145
  287. package/blockly-rc/core/renderers/zelos/measurables/bottom_row.ts +0 -44
  288. package/blockly-rc/core/renderers/zelos/measurables/inputs.ts +0 -41
  289. package/blockly-rc/core/renderers/zelos/measurables/row_elements.ts +0 -29
  290. package/blockly-rc/core/renderers/zelos/measurables/top_row.ts +0 -50
  291. package/blockly-rc/core/renderers/zelos/path_object.ts +0 -209
  292. package/blockly-rc/core/renderers/zelos/renderer.ts +0 -143
  293. package/blockly-rc/core/renderers/zelos/zelos.ts +0 -33
  294. package/blockly-rc/core/scrollbar.ts +0 -898
  295. package/blockly-rc/core/scrollbar_pair.ts +0 -349
  296. package/blockly-rc/core/separator_flyout_inflater.ts +0 -69
  297. package/blockly-rc/core/serialization/blocks.ts +0 -868
  298. package/blockly-rc/core/serialization/exceptions.ts +0 -112
  299. package/blockly-rc/core/serialization/priorities.ts +0 -25
  300. package/blockly-rc/core/serialization/procedures.ts +0 -158
  301. package/blockly-rc/core/serialization/registry.ts +0 -30
  302. package/blockly-rc/core/serialization/variables.ts +0 -68
  303. package/blockly-rc/core/serialization/workspace_comments.ts +0 -143
  304. package/blockly-rc/core/serialization/workspaces.ts +0 -94
  305. package/blockly-rc/core/serialization.ts +0 -32
  306. package/blockly-rc/core/shortcut_items.ts +0 -338
  307. package/blockly-rc/core/shortcut_registry.ts +0 -368
  308. package/blockly-rc/core/sprites.ts +0 -15
  309. package/blockly-rc/core/theme/classic.ts +0 -40
  310. package/blockly-rc/core/theme/themes.ts +0 -12
  311. package/blockly-rc/core/theme/zelos.ts +0 -80
  312. package/blockly-rc/core/theme.ts +0 -232
  313. package/blockly-rc/core/theme_manager.ts +0 -192
  314. package/blockly-rc/core/toolbox/category.ts +0 -739
  315. package/blockly-rc/core/toolbox/collapsible_category.ts +0 -288
  316. package/blockly-rc/core/toolbox/separator.ts +0 -105
  317. package/blockly-rc/core/toolbox/toolbox.ts +0 -1134
  318. package/blockly-rc/core/toolbox/toolbox_item.ts +0 -152
  319. package/blockly-rc/core/tooltip.ts +0 -466
  320. package/blockly-rc/core/touch.ts +0 -155
  321. package/blockly-rc/core/trashcan.ts +0 -748
  322. package/blockly-rc/core/utils/aria.ts +0 -144
  323. package/blockly-rc/core/utils/array.ts +0 -24
  324. package/blockly-rc/core/utils/colour.ts +0 -265
  325. package/blockly-rc/core/utils/coordinate.ts +0 -129
  326. package/blockly-rc/core/utils/deprecation.ts +0 -47
  327. package/blockly-rc/core/utils/dom.ts +0 -356
  328. package/blockly-rc/core/utils/idgenerator.ts +0 -70
  329. package/blockly-rc/core/utils/keycodes.ts +0 -154
  330. package/blockly-rc/core/utils/math.ts +0 -50
  331. package/blockly-rc/core/utils/metrics.ts +0 -86
  332. package/blockly-rc/core/utils/object.ts +0 -28
  333. package/blockly-rc/core/utils/parsing.ts +0 -287
  334. package/blockly-rc/core/utils/rect.ts +0 -69
  335. package/blockly-rc/core/utils/size.ts +0 -62
  336. package/blockly-rc/core/utils/string.ts +0 -289
  337. package/blockly-rc/core/utils/style.ts +0 -219
  338. package/blockly-rc/core/utils/svg.ts +0 -84
  339. package/blockly-rc/core/utils/svg_math.ts +0 -208
  340. package/blockly-rc/core/utils/svg_paths.ts +0 -133
  341. package/blockly-rc/core/utils/toolbox.ts +0 -419
  342. package/blockly-rc/core/utils/useragent.ts +0 -86
  343. package/blockly-rc/core/utils/xml.ts +0 -165
  344. package/blockly-rc/core/utils.ts +0 -59
  345. package/blockly-rc/core/variable_map.ts +0 -437
  346. package/blockly-rc/core/variable_model.ts +0 -149
  347. package/blockly-rc/core/variables.ts +0 -773
  348. package/blockly-rc/core/variables_dynamic.ts +0 -142
  349. package/blockly-rc/core/widgetdiv.ts +0 -319
  350. package/blockly-rc/core/workspace.ts +0 -957
  351. package/blockly-rc/core/workspace_audio.ts +0 -171
  352. package/blockly-rc/core/workspace_dragger.ts +0 -97
  353. package/blockly-rc/core/workspace_svg.ts +0 -2519
  354. package/blockly-rc/core/xml.ts +0 -1133
  355. package/blockly-rc/core/zoom_controls.ts +0 -492
  356. package/blockly-rc/demos/blockfactory/analytics.js +0 -195
  357. package/blockly-rc/demos/blockfactory/app_controller.js +0 -726
  358. package/blockly-rc/demos/blockfactory/block_definition_extractor.js +0 -742
  359. package/blockly-rc/demos/blockfactory/block_exporter_controller.js +0 -311
  360. package/blockly-rc/demos/blockfactory/block_exporter_tools.js +0 -212
  361. package/blockly-rc/demos/blockfactory/block_exporter_view.js +0 -101
  362. package/blockly-rc/demos/blockfactory/block_library_controller.js +0 -325
  363. package/blockly-rc/demos/blockfactory/block_library_storage.js +0 -149
  364. package/blockly-rc/demos/blockfactory/block_library_view.js +0 -178
  365. package/blockly-rc/demos/blockfactory/block_option.js +0 -151
  366. package/blockly-rc/demos/blockfactory/blocks.js +0 -916
  367. package/blockly-rc/demos/blockfactory/cp.css +0 -46
  368. package/blockly-rc/demos/blockfactory/cp.js +0 -179
  369. package/blockly-rc/demos/blockfactory/factory.css +0 -586
  370. package/blockly-rc/demos/blockfactory/factory.js +0 -337
  371. package/blockly-rc/demos/blockfactory/factory_utils.js +0 -1036
  372. package/blockly-rc/demos/blockfactory/icon.png +0 -0
  373. package/blockly-rc/demos/blockfactory/index.html +0 -767
  374. package/blockly-rc/demos/blockfactory/link.png +0 -0
  375. package/blockly-rc/demos/blockfactory/standard_categories.js +0 -384
  376. package/blockly-rc/demos/blockfactory/workspacefactory/wfactory_controller.js +0 -1332
  377. package/blockly-rc/demos/blockfactory/workspacefactory/wfactory_generator.js +0 -224
  378. package/blockly-rc/demos/blockfactory/workspacefactory/wfactory_init.js +0 -541
  379. package/blockly-rc/demos/blockfactory/workspacefactory/wfactory_model.js +0 -548
  380. package/blockly-rc/demos/blockfactory/workspacefactory/wfactory_view.js +0 -424
  381. package/blockly-rc/demos/code/code.js +0 -626
  382. package/blockly-rc/demos/code/icon.png +0 -0
  383. package/blockly-rc/demos/code/icons.png +0 -0
  384. package/blockly-rc/demos/code/index.html +0 -359
  385. package/blockly-rc/demos/code/msg/ar.js +0 -24
  386. package/blockly-rc/demos/code/msg/be-tarask.js +0 -24
  387. package/blockly-rc/demos/code/msg/br.js +0 -24
  388. package/blockly-rc/demos/code/msg/ca.js +0 -24
  389. package/blockly-rc/demos/code/msg/cs.js +0 -24
  390. package/blockly-rc/demos/code/msg/da.js +0 -24
  391. package/blockly-rc/demos/code/msg/de.js +0 -24
  392. package/blockly-rc/demos/code/msg/el.js +0 -24
  393. package/blockly-rc/demos/code/msg/en.js +0 -24
  394. package/blockly-rc/demos/code/msg/es.js +0 -24
  395. package/blockly-rc/demos/code/msg/et.js +0 -24
  396. package/blockly-rc/demos/code/msg/fa.js +0 -24
  397. package/blockly-rc/demos/code/msg/fr.js +0 -24
  398. package/blockly-rc/demos/code/msg/he.js +0 -24
  399. package/blockly-rc/demos/code/msg/hr.js +0 -24
  400. package/blockly-rc/demos/code/msg/hrx.js +0 -24
  401. package/blockly-rc/demos/code/msg/hu.js +0 -24
  402. package/blockly-rc/demos/code/msg/ia.js +0 -24
  403. package/blockly-rc/demos/code/msg/is.js +0 -24
  404. package/blockly-rc/demos/code/msg/it.js +0 -24
  405. package/blockly-rc/demos/code/msg/ja.js +0 -24
  406. package/blockly-rc/demos/code/msg/kab.js +0 -24
  407. package/blockly-rc/demos/code/msg/ko.js +0 -24
  408. package/blockly-rc/demos/code/msg/mk.js +0 -24
  409. package/blockly-rc/demos/code/msg/ms.js +0 -24
  410. package/blockly-rc/demos/code/msg/nb.js +0 -24
  411. package/blockly-rc/demos/code/msg/nl.js +0 -24
  412. package/blockly-rc/demos/code/msg/oc.js +0 -24
  413. package/blockly-rc/demos/code/msg/pl.js +0 -24
  414. package/blockly-rc/demos/code/msg/pms.js +0 -24
  415. package/blockly-rc/demos/code/msg/pt-br.js +0 -24
  416. package/blockly-rc/demos/code/msg/ro.js +0 -24
  417. package/blockly-rc/demos/code/msg/ru.js +0 -24
  418. package/blockly-rc/demos/code/msg/sc.js +0 -24
  419. package/blockly-rc/demos/code/msg/sk.js +0 -24
  420. package/blockly-rc/demos/code/msg/sr.js +0 -24
  421. package/blockly-rc/demos/code/msg/sv.js +0 -24
  422. package/blockly-rc/demos/code/msg/ta.js +0 -24
  423. package/blockly-rc/demos/code/msg/th.js +0 -24
  424. package/blockly-rc/demos/code/msg/tlh.js +0 -24
  425. package/blockly-rc/demos/code/msg/tr.js +0 -24
  426. package/blockly-rc/demos/code/msg/uk.js +0 -24
  427. package/blockly-rc/demos/code/msg/vi.js +0 -24
  428. package/blockly-rc/demos/code/msg/zh-hans.js +0 -24
  429. package/blockly-rc/demos/code/msg/zh-hant.js +0 -24
  430. package/blockly-rc/demos/code/style.css +0 -184
  431. package/blockly-rc/demos/index.html +0 -68
  432. package/blockly-rc/demos/minimap/icon.png +0 -0
  433. package/blockly-rc/demos/minimap/index.html +0 -91
  434. package/blockly-rc/demos/minimap/minimap.js +0 -302
  435. package/blockly-rc/demos/mobile/README.md +0 -53
  436. package/blockly-rc/demos/mobile/android/README.md +0 -45
  437. package/blockly-rc/demos/mobile/android/app/build.gradle +0 -64
  438. package/blockly-rc/demos/mobile/android/app/proguard-rules.pro +0 -21
  439. package/blockly-rc/demos/mobile/android/app/src/androidTest/java/com/example/blocklywebview/ExampleInstrumentedTest.java +0 -26
  440. package/blockly-rc/demos/mobile/android/app/src/main/AndroidManifest.xml +0 -21
  441. package/blockly-rc/demos/mobile/android/app/src/main/java/com/google/blockly/android/webview/BlocklyWebViewFragment.java +0 -40
  442. package/blockly-rc/demos/mobile/android/app/src/main/java/com/google/blockly/android/webview/JsDialogHelper.java +0 -150
  443. package/blockly-rc/demos/mobile/android/app/src/main/java/com/google/blockly/android/webview/WebChromeClient.java +0 -32
  444. package/blockly-rc/demos/mobile/android/app/src/main/java/com/google/blockly/android/webview/demo/MainActivity.java +0 -18
  445. package/blockly-rc/demos/mobile/android/app/src/main/res/drawable/ic_launcher_background.xml +0 -74
  446. package/blockly-rc/demos/mobile/android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml +0 -34
  447. package/blockly-rc/demos/mobile/android/app/src/main/res/layout/activity_main.xml +0 -17
  448. package/blockly-rc/demos/mobile/android/app/src/main/res/layout/js_prompt.xml +0 -37
  449. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml +0 -5
  450. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml +0 -5
  451. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
  452. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
  453. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
  454. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
  455. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
  456. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
  457. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
  458. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
  459. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
  460. package/blockly-rc/demos/mobile/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
  461. package/blockly-rc/demos/mobile/android/app/src/main/res/values/colors.xml +0 -6
  462. package/blockly-rc/demos/mobile/android/app/src/main/res/values/js_dialog_helper.xml +0 -7
  463. package/blockly-rc/demos/mobile/android/app/src/main/res/values/strings.xml +0 -3
  464. package/blockly-rc/demos/mobile/android/app/src/main/res/values/styles.xml +0 -11
  465. package/blockly-rc/demos/mobile/android/app/src/test/java/com/example/blocklywebview/ExampleUnitTest.java +0 -17
  466. package/blockly-rc/demos/mobile/android/build.gradle +0 -27
  467. package/blockly-rc/demos/mobile/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  468. package/blockly-rc/demos/mobile/android/gradle/wrapper/gradle-wrapper.properties +0 -6
  469. package/blockly-rc/demos/mobile/android/gradle.properties +0 -13
  470. package/blockly-rc/demos/mobile/android/gradlew +0 -172
  471. package/blockly-rc/demos/mobile/android/gradlew.bat +0 -84
  472. package/blockly-rc/demos/mobile/android/settings.gradle +0 -1
  473. package/blockly-rc/demos/mobile/html/index.html +0 -31
  474. package/blockly-rc/demos/mobile/html/ln_resources.sh +0 -22
  475. package/blockly-rc/demos/mobile/html/toolbox_standard.js +0 -333
  476. package/blockly-rc/demos/mobile/ios/Blockly WebView/AppDelegate.swift +0 -46
  477. package/blockly-rc/demos/mobile/ios/Blockly WebView/Assets.xcassets/AppIcon.appiconset/Contents.json +0 -98
  478. package/blockly-rc/demos/mobile/ios/Blockly WebView/Assets.xcassets/Contents.json +0 -6
  479. package/blockly-rc/demos/mobile/ios/Blockly WebView/Base.lproj/LaunchScreen.storyboard +0 -25
  480. package/blockly-rc/demos/mobile/ios/Blockly WebView/Base.lproj/Main.storyboard +0 -44
  481. package/blockly-rc/demos/mobile/ios/Blockly WebView/Info.plist +0 -45
  482. package/blockly-rc/demos/mobile/ios/Blockly WebView/ViewController.swift +0 -110
  483. package/blockly-rc/demos/mobile/ios/Blockly WebView.xcodeproj/project.pbxproj +0 -390
  484. package/blockly-rc/demos/mobile/ios/Blockly WebView.xcodeproj/project.xcworkspace/contents.xcworkspacedata +0 -7
  485. package/blockly-rc/demos/mobile/ios/Blockly WebView.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -8
  486. package/blockly-rc/demos/mobile/ios/cp_resources.sh +0 -21
  487. package/blockly-rc/demos/storage/icon.png +0 -0
  488. package/blockly-rc/demos/storage/index.html +0 -104
  489. package/blockly-rc/generators/dart/dart_generator.ts +0 -321
  490. package/blockly-rc/generators/dart/lists.ts +0 -525
  491. package/blockly-rc/generators/dart/logic.ts +0 -155
  492. package/blockly-rc/generators/dart/loops.ts +0 -217
  493. package/blockly-rc/generators/dart/math.ts +0 -559
  494. package/blockly-rc/generators/dart/procedures.ts +0 -138
  495. package/blockly-rc/generators/dart/text.ts +0 -405
  496. package/blockly-rc/generators/dart/variables.ts +0 -32
  497. package/blockly-rc/generators/dart/variables_dynamic.ts +0 -17
  498. package/blockly-rc/generators/dart.ts +0 -50
  499. package/blockly-rc/generators/javascript/javascript_generator.ts +0 -346
  500. package/blockly-rc/generators/javascript/lists.ts +0 -465
  501. package/blockly-rc/generators/javascript/logic.ts +0 -153
  502. package/blockly-rc/generators/javascript/loops.ts +0 -245
  503. package/blockly-rc/generators/javascript/math.ts +0 -450
  504. package/blockly-rc/generators/javascript/procedures.ts +0 -142
  505. package/blockly-rc/generators/javascript/text.ts +0 -418
  506. package/blockly-rc/generators/javascript/variables.ts +0 -32
  507. package/blockly-rc/generators/javascript/variables_dynamic.ts +0 -17
  508. package/blockly-rc/generators/javascript.ts +0 -46
  509. package/blockly-rc/generators/lua/lists.ts +0 -445
  510. package/blockly-rc/generators/lua/logic.ts +0 -142
  511. package/blockly-rc/generators/lua/loops.ts +0 -192
  512. package/blockly-rc/generators/lua/lua_generator.ts +0 -225
  513. package/blockly-rc/generators/lua/math.ts +0 -473
  514. package/blockly-rc/generators/lua/procedures.ts +0 -144
  515. package/blockly-rc/generators/lua/text.ts +0 -380
  516. package/blockly-rc/generators/lua/variables.ts +0 -31
  517. package/blockly-rc/generators/lua/variables_dynamic.ts +0 -17
  518. package/blockly-rc/generators/lua.ts +0 -44
  519. package/blockly-rc/generators/php/lists.ts +0 -585
  520. package/blockly-rc/generators/php/logic.ts +0 -155
  521. package/blockly-rc/generators/php/loops.ts +0 -218
  522. package/blockly-rc/generators/php/math.ts +0 -408
  523. package/blockly-rc/generators/php/php_generator.ts +0 -320
  524. package/blockly-rc/generators/php/procedures.ts +0 -159
  525. package/blockly-rc/generators/php/text.ts +0 -315
  526. package/blockly-rc/generators/php/variables.ts +0 -32
  527. package/blockly-rc/generators/php/variables_dynamic.ts +0 -17
  528. package/blockly-rc/generators/php.ts +0 -46
  529. package/blockly-rc/generators/python/lists.ts +0 -398
  530. package/blockly-rc/generators/python/logic.ts +0 -148
  531. package/blockly-rc/generators/python/loops.ts +0 -251
  532. package/blockly-rc/generators/python/math.ts +0 -434
  533. package/blockly-rc/generators/python/procedures.ts +0 -159
  534. package/blockly-rc/generators/python/python_generator.ts +0 -355
  535. package/blockly-rc/generators/python/text.ts +0 -338
  536. package/blockly-rc/generators/python/variables.ts +0 -31
  537. package/blockly-rc/generators/python/variables_dynamic.ts +0 -17
  538. package/blockly-rc/generators/python.ts +0 -51
  539. package/blockly-rc/gulpfile.js +0 -54
  540. package/blockly-rc/jsconfig.json +0 -7
  541. package/blockly-rc/media/1x1.gif +0 -0
  542. package/blockly-rc/media/click.mp3 +0 -0
  543. package/blockly-rc/media/click.ogg +0 -0
  544. package/blockly-rc/media/click.wav +0 -0
  545. package/blockly-rc/media/delete-icon.svg +0 -1
  546. package/blockly-rc/media/delete.mp3 +0 -0
  547. package/blockly-rc/media/delete.ogg +0 -0
  548. package/blockly-rc/media/delete.wav +0 -0
  549. package/blockly-rc/media/disconnect.mp3 +0 -0
  550. package/blockly-rc/media/disconnect.ogg +0 -0
  551. package/blockly-rc/media/disconnect.wav +0 -0
  552. package/blockly-rc/media/dropdown-arrow.svg +0 -1
  553. package/blockly-rc/media/foldout-icon.svg +0 -1
  554. package/blockly-rc/media/handclosed.cur +0 -0
  555. package/blockly-rc/media/handdelete.cur +0 -0
  556. package/blockly-rc/media/handopen.cur +0 -0
  557. package/blockly-rc/media/pilcrow.png +0 -0
  558. package/blockly-rc/media/quote0.png +0 -0
  559. package/blockly-rc/media/quote1.png +0 -0
  560. package/blockly-rc/media/resize-handle.svg +0 -3
  561. package/blockly-rc/media/sprites.png +0 -0
  562. package/blockly-rc/media/sprites.svg +0 -74
  563. package/blockly-rc/msg/json/README.md +0 -33
  564. package/blockly-rc/msg/json/ab.json +0 -222
  565. package/blockly-rc/msg/json/ace.json +0 -7
  566. package/blockly-rc/msg/json/af.json +0 -34
  567. package/blockly-rc/msg/json/am.json +0 -30
  568. package/blockly-rc/msg/json/ar.json +0 -355
  569. package/blockly-rc/msg/json/ast.json +0 -10
  570. package/blockly-rc/msg/json/az.json +0 -332
  571. package/blockly-rc/msg/json/ba.json +0 -211
  572. package/blockly-rc/msg/json/bcc.json +0 -290
  573. package/blockly-rc/msg/json/be-tarask.json +0 -334
  574. package/blockly-rc/msg/json/be.json +0 -324
  575. package/blockly-rc/msg/json/bg.json +0 -345
  576. package/blockly-rc/msg/json/bn.json +0 -189
  577. package/blockly-rc/msg/json/br.json +0 -334
  578. package/blockly-rc/msg/json/bs.json +0 -166
  579. package/blockly-rc/msg/json/ca.json +0 -341
  580. package/blockly-rc/msg/json/cdo.json +0 -6
  581. package/blockly-rc/msg/json/ce.json +0 -326
  582. package/blockly-rc/msg/json/constants.json +0 -12
  583. package/blockly-rc/msg/json/cs.json +0 -343
  584. package/blockly-rc/msg/json/da.json +0 -346
  585. package/blockly-rc/msg/json/de.json +0 -369
  586. package/blockly-rc/msg/json/diq.json +0 -258
  587. package/blockly-rc/msg/json/dtp.json +0 -198
  588. package/blockly-rc/msg/json/dty.json +0 -97
  589. package/blockly-rc/msg/json/ee.json +0 -160
  590. package/blockly-rc/msg/json/el.json +0 -356
  591. package/blockly-rc/msg/json/en-gb.json +0 -199
  592. package/blockly-rc/msg/json/en.json +0 -400
  593. package/blockly-rc/msg/json/eo.json +0 -337
  594. package/blockly-rc/msg/json/es.json +0 -358
  595. package/blockly-rc/msg/json/et.json +0 -326
  596. package/blockly-rc/msg/json/eu.json +0 -219
  597. package/blockly-rc/msg/json/fa.json +0 -341
  598. package/blockly-rc/msg/json/fi.json +0 -350
  599. package/blockly-rc/msg/json/fo.json +0 -46
  600. package/blockly-rc/msg/json/fr.json +0 -373
  601. package/blockly-rc/msg/json/frr.json +0 -6
  602. package/blockly-rc/msg/json/gl.json +0 -338
  603. package/blockly-rc/msg/json/gn.json +0 -54
  604. package/blockly-rc/msg/json/gor.json +0 -87
  605. package/blockly-rc/msg/json/ha.json +0 -313
  606. package/blockly-rc/msg/json/hak.json +0 -17
  607. package/blockly-rc/msg/json/he.json +0 -354
  608. package/blockly-rc/msg/json/hi.json +0 -318
  609. package/blockly-rc/msg/json/hr.json +0 -327
  610. package/blockly-rc/msg/json/hrx.json +0 -287
  611. package/blockly-rc/msg/json/hsb.json +0 -128
  612. package/blockly-rc/msg/json/hu.json +0 -349
  613. package/blockly-rc/msg/json/hy.json +0 -337
  614. package/blockly-rc/msg/json/ia.json +0 -337
  615. package/blockly-rc/msg/json/id.json +0 -335
  616. package/blockly-rc/msg/json/ig.json +0 -323
  617. package/blockly-rc/msg/json/inh.json +0 -80
  618. package/blockly-rc/msg/json/is.json +0 -331
  619. package/blockly-rc/msg/json/it.json +0 -346
  620. package/blockly-rc/msg/json/ja.json +0 -361
  621. package/blockly-rc/msg/json/ka.json +0 -14
  622. package/blockly-rc/msg/json/kab.json +0 -323
  623. package/blockly-rc/msg/json/kbd-cyrl.json +0 -84
  624. package/blockly-rc/msg/json/km.json +0 -29
  625. package/blockly-rc/msg/json/kn.json +0 -332
  626. package/blockly-rc/msg/json/ko.json +0 -372
  627. package/blockly-rc/msg/json/ksh.json +0 -43
  628. package/blockly-rc/msg/json/ku-latn.json +0 -41
  629. package/blockly-rc/msg/json/ky.json +0 -71
  630. package/blockly-rc/msg/json/la.json +0 -6
  631. package/blockly-rc/msg/json/lb.json +0 -156
  632. package/blockly-rc/msg/json/lki.json +0 -282
  633. package/blockly-rc/msg/json/lo.json +0 -92
  634. package/blockly-rc/msg/json/lrc.json +0 -123
  635. package/blockly-rc/msg/json/lt.json +0 -321
  636. package/blockly-rc/msg/json/lv.json +0 -324
  637. package/blockly-rc/msg/json/mg.json +0 -58
  638. package/blockly-rc/msg/json/mk.json +0 -178
  639. package/blockly-rc/msg/json/ml.json +0 -35
  640. package/blockly-rc/msg/json/mnw.json +0 -90
  641. package/blockly-rc/msg/json/ms.json +0 -300
  642. package/blockly-rc/msg/json/my.json +0 -57
  643. package/blockly-rc/msg/json/mzn.json +0 -6
  644. package/blockly-rc/msg/json/nb.json +0 -330
  645. package/blockly-rc/msg/json/ne.json +0 -247
  646. package/blockly-rc/msg/json/nl.json +0 -357
  647. package/blockly-rc/msg/json/oc.json +0 -194
  648. package/blockly-rc/msg/json/olo.json +0 -37
  649. package/blockly-rc/msg/json/pa.json +0 -69
  650. package/blockly-rc/msg/json/pl.json +0 -357
  651. package/blockly-rc/msg/json/pms.json +0 -324
  652. package/blockly-rc/msg/json/ps.json +0 -50
  653. package/blockly-rc/msg/json/pt-br.json +0 -369
  654. package/blockly-rc/msg/json/pt.json +0 -358
  655. package/blockly-rc/msg/json/qqq.json +0 -406
  656. package/blockly-rc/msg/json/ro.json +0 -333
  657. package/blockly-rc/msg/json/ru.json +0 -363
  658. package/blockly-rc/msg/json/sc.json +0 -283
  659. package/blockly-rc/msg/json/sco.json +0 -11
  660. package/blockly-rc/msg/json/sd.json +0 -158
  661. package/blockly-rc/msg/json/shn.json +0 -109
  662. package/blockly-rc/msg/json/si.json +0 -16
  663. package/blockly-rc/msg/json/sk.json +0 -332
  664. package/blockly-rc/msg/json/skr-arab.json +0 -117
  665. package/blockly-rc/msg/json/sl.json +0 -355
  666. package/blockly-rc/msg/json/smn.json +0 -133
  667. package/blockly-rc/msg/json/sq.json +0 -343
  668. package/blockly-rc/msg/json/sr-latn.json +0 -324
  669. package/blockly-rc/msg/json/sr.json +0 -348
  670. package/blockly-rc/msg/json/sv.json +0 -347
  671. package/blockly-rc/msg/json/sw.json +0 -12
  672. package/blockly-rc/msg/json/synonyms.json +0 -22
  673. package/blockly-rc/msg/json/ta.json +0 -306
  674. package/blockly-rc/msg/json/tcy.json +0 -316
  675. package/blockly-rc/msg/json/tdd.json +0 -109
  676. package/blockly-rc/msg/json/te.json +0 -101
  677. package/blockly-rc/msg/json/th.json +0 -333
  678. package/blockly-rc/msg/json/ti.json +0 -50
  679. package/blockly-rc/msg/json/tl.json +0 -129
  680. package/blockly-rc/msg/json/tlh.json +0 -179
  681. package/blockly-rc/msg/json/tr.json +0 -369
  682. package/blockly-rc/msg/json/ug-arab.json +0 -132
  683. package/blockly-rc/msg/json/uk.json +0 -345
  684. package/blockly-rc/msg/json/ur.json +0 -117
  685. package/blockly-rc/msg/json/uz.json +0 -36
  686. package/blockly-rc/msg/json/vi.json +0 -345
  687. package/blockly-rc/msg/json/xmf.json +0 -96
  688. package/blockly-rc/msg/json/yo.json +0 -316
  689. package/blockly-rc/msg/json/zgh.json +0 -83
  690. package/blockly-rc/msg/json/zh-hans.json +0 -372
  691. package/blockly-rc/msg/json/zh-hant.json +0 -362
  692. package/blockly-rc/msg/messages.js +0 -1616
  693. package/blockly-rc/package-lock.json +0 -12324
  694. package/blockly-rc/package.json +0 -149
  695. package/blockly-rc/patches/@microsoft+api-documenter+7.22.4.patch +0 -81
  696. package/blockly-rc/scripts/goog_module/convert-file.sh +0 -406
  697. package/blockly-rc/scripts/gulpfiles/appengine_tasks.js +0 -195
  698. package/blockly-rc/scripts/gulpfiles/build_tasks.js +0 -752
  699. package/blockly-rc/scripts/gulpfiles/config.js +0 -41
  700. package/blockly-rc/scripts/gulpfiles/docs_tasks.js +0 -147
  701. package/blockly-rc/scripts/gulpfiles/git_tasks.js +0 -181
  702. package/blockly-rc/scripts/gulpfiles/helper_tasks.js +0 -19
  703. package/blockly-rc/scripts/gulpfiles/package_tasks.js +0 -262
  704. package/blockly-rc/scripts/gulpfiles/release_tasks.js +0 -183
  705. package/blockly-rc/scripts/gulpfiles/test_tasks.js +0 -405
  706. package/blockly-rc/scripts/helpers.js +0 -74
  707. package/blockly-rc/scripts/i18n/common.py +0 -233
  708. package/blockly-rc/scripts/i18n/create_messages.py +0 -167
  709. package/blockly-rc/scripts/i18n/dedup_json.py +0 -72
  710. package/blockly-rc/scripts/i18n/js_to_json.py +0 -135
  711. package/blockly-rc/scripts/i18n/tests.py +0 -46
  712. package/blockly-rc/scripts/migration/cjs2esm +0 -162
  713. package/blockly-rc/scripts/migration/js2ts +0 -168
  714. package/blockly-rc/scripts/migration/renamings.json5 +0 -1599
  715. package/blockly-rc/scripts/package/README.md +0 -93
  716. package/blockly-rc/scripts/package/core-node.js +0 -31
  717. package/blockly-rc/scripts/package/index.js +0 -23
  718. package/blockly-rc/scripts/package/templates/umd-msg.template +0 -16
  719. package/blockly-rc/scripts/package/templates/umd.template +0 -13
  720. package/blockly-rc/scripts/themes/blockStyles_example.json +0 -11
  721. package/blockly-rc/scripts/themes/create_blockStyles.py +0 -181
  722. package/blockly-rc/scripts/tsick.js +0 -86
  723. package/blockly-rc/tests/.eslintrc.json +0 -10
  724. package/blockly-rc/tests/browser/.eslintrc.json +0 -29
  725. package/blockly-rc/tests/browser/.mocharc.js +0 -6
  726. package/blockly-rc/tests/browser/test/basic_block_factory_test.mjs +0 -44
  727. package/blockly-rc/tests/browser/test/basic_block_test.mjs +0 -39
  728. package/blockly-rc/tests/browser/test/basic_playground_test.mjs +0 -198
  729. package/blockly-rc/tests/browser/test/block_undo_test.mjs +0 -50
  730. package/blockly-rc/tests/browser/test/delete_blocks_test.mjs +0 -211
  731. package/blockly-rc/tests/browser/test/extensive_test.mjs +0 -195
  732. package/blockly-rc/tests/browser/test/field_edits_test.mjs +0 -61
  733. package/blockly-rc/tests/browser/test/hooks.mjs +0 -23
  734. package/blockly-rc/tests/browser/test/mutator_test.mjs +0 -88
  735. package/blockly-rc/tests/browser/test/procedure_test.mjs +0 -109
  736. package/blockly-rc/tests/browser/test/test_setup.mjs +0 -589
  737. package/blockly-rc/tests/browser/test/toolbox_drag_test.mjs +0 -207
  738. package/blockly-rc/tests/browser/test/workspace_comment_test.mjs +0 -224
  739. package/blockly-rc/tests/compile/index.html +0 -43
  740. package/blockly-rc/tests/compile/main.js +0 -53
  741. package/blockly-rc/tests/compile/test_blocks.js +0 -47
  742. package/blockly-rc/tests/compile/webdriver.js +0 -81
  743. package/blockly-rc/tests/generators/functions.xml +0 -561
  744. package/blockly-rc/tests/generators/golden/generated.dart +0 -1604
  745. package/blockly-rc/tests/generators/golden/generated.js +0 -1552
  746. package/blockly-rc/tests/generators/golden/generated.lua +0 -1828
  747. package/blockly-rc/tests/generators/golden/generated.php +0 -1611
  748. package/blockly-rc/tests/generators/golden/generated.py +0 -1407
  749. package/blockly-rc/tests/generators/index.html +0 -405
  750. package/blockly-rc/tests/generators/lists.xml +0 -8675
  751. package/blockly-rc/tests/generators/logic.xml +0 -1019
  752. package/blockly-rc/tests/generators/loops1.xml +0 -345
  753. package/blockly-rc/tests/generators/loops2.xml +0 -891
  754. package/blockly-rc/tests/generators/loops3.xml +0 -735
  755. package/blockly-rc/tests/generators/math.xml +0 -2077
  756. package/blockly-rc/tests/generators/text.xml +0 -4651
  757. package/blockly-rc/tests/generators/unittest.js +0 -103
  758. package/blockly-rc/tests/generators/unittest_dart.js +0 -163
  759. package/blockly-rc/tests/generators/unittest_javascript.js +0 -167
  760. package/blockly-rc/tests/generators/unittest_lua.js +0 -165
  761. package/blockly-rc/tests/generators/unittest_php.js +0 -154
  762. package/blockly-rc/tests/generators/unittest_python.js +0 -138
  763. package/blockly-rc/tests/generators/variables.xml +0 -68
  764. package/blockly-rc/tests/generators/webdriver.js +0 -123
  765. package/blockly-rc/tests/media/200px.png +0 -0
  766. package/blockly-rc/tests/media/30px.png +0 -0
  767. package/blockly-rc/tests/media/50px.png +0 -0
  768. package/blockly-rc/tests/media/a.png +0 -0
  769. package/blockly-rc/tests/media/arrow.png +0 -0
  770. package/blockly-rc/tests/media/b.png +0 -0
  771. package/blockly-rc/tests/media/c.png +0 -0
  772. package/blockly-rc/tests/media/d.png +0 -0
  773. package/blockly-rc/tests/media/e.png +0 -0
  774. package/blockly-rc/tests/media/f.png +0 -0
  775. package/blockly-rc/tests/media/g.png +0 -0
  776. package/blockly-rc/tests/media/h.png +0 -0
  777. package/blockly-rc/tests/media/i.png +0 -0
  778. package/blockly-rc/tests/media/j.png +0 -0
  779. package/blockly-rc/tests/media/k.png +0 -0
  780. package/blockly-rc/tests/media/l.png +0 -0
  781. package/blockly-rc/tests/media/m.png +0 -0
  782. package/blockly-rc/tests/migration/renamings.schema.json +0 -59
  783. package/blockly-rc/tests/migration/validate-renamings.mjs +0 -60
  784. package/blockly-rc/tests/mocha/.eslintrc.json +0 -21
  785. package/blockly-rc/tests/mocha/.mocharc.js +0 -6
  786. package/blockly-rc/tests/mocha/astnode_test.js +0 -850
  787. package/blockly-rc/tests/mocha/block_json_test.js +0 -777
  788. package/blockly-rc/tests/mocha/block_test.js +0 -2743
  789. package/blockly-rc/tests/mocha/blocks/lists_test.js +0 -196
  790. package/blockly-rc/tests/mocha/blocks/logic_ternary_test.js +0 -320
  791. package/blockly-rc/tests/mocha/blocks/loops_test.js +0 -56
  792. package/blockly-rc/tests/mocha/blocks/procedures_test.js +0 -2495
  793. package/blockly-rc/tests/mocha/blocks/variables_test.js +0 -311
  794. package/blockly-rc/tests/mocha/clipboard_test.js +0 -136
  795. package/blockly-rc/tests/mocha/comment_deserialization_test.js +0 -122
  796. package/blockly-rc/tests/mocha/comment_test.js +0 -170
  797. package/blockly-rc/tests/mocha/comment_view_test.js +0 -188
  798. package/blockly-rc/tests/mocha/connection_checker_test.js +0 -666
  799. package/blockly-rc/tests/mocha/connection_db_test.js +0 -362
  800. package/blockly-rc/tests/mocha/connection_test.js +0 -3738
  801. package/blockly-rc/tests/mocha/contextmenu_items_test.js +0 -488
  802. package/blockly-rc/tests/mocha/contextmenu_test.js +0 -71
  803. package/blockly-rc/tests/mocha/cursor_test.js +0 -134
  804. package/blockly-rc/tests/mocha/dropdowndiv_test.js +0 -116
  805. package/blockly-rc/tests/mocha/event_block_change_test.js +0 -126
  806. package/blockly-rc/tests/mocha/event_block_create_test.js +0 -109
  807. package/blockly-rc/tests/mocha/event_block_delete_test.js +0 -55
  808. package/blockly-rc/tests/mocha/event_block_drag_test.js +0 -36
  809. package/blockly-rc/tests/mocha/event_block_field_intermediate_change_test.js +0 -67
  810. package/blockly-rc/tests/mocha/event_block_move_test.js +0 -39
  811. package/blockly-rc/tests/mocha/event_bubble_open_test.js +0 -42
  812. package/blockly-rc/tests/mocha/event_click_test.js +0 -40
  813. package/blockly-rc/tests/mocha/event_comment_change_test.js +0 -39
  814. package/blockly-rc/tests/mocha/event_comment_collapse_test.js +0 -34
  815. package/blockly-rc/tests/mocha/event_comment_create_test.js +0 -38
  816. package/blockly-rc/tests/mocha/event_comment_delete_test.js +0 -38
  817. package/blockly-rc/tests/mocha/event_comment_drag_test.js +0 -35
  818. package/blockly-rc/tests/mocha/event_comment_move_test.js +0 -40
  819. package/blockly-rc/tests/mocha/event_comment_resize_test.js +0 -38
  820. package/blockly-rc/tests/mocha/event_marker_move_test.js +0 -44
  821. package/blockly-rc/tests/mocha/event_selected_test.js +0 -41
  822. package/blockly-rc/tests/mocha/event_test.js +0 -1578
  823. package/blockly-rc/tests/mocha/event_theme_change_test.js +0 -36
  824. package/blockly-rc/tests/mocha/event_toolbox_item_select_test.js +0 -64
  825. package/blockly-rc/tests/mocha/event_trashcan_open_test.js +0 -36
  826. package/blockly-rc/tests/mocha/event_var_create_test.js +0 -54
  827. package/blockly-rc/tests/mocha/event_var_delete_test.js +0 -54
  828. package/blockly-rc/tests/mocha/event_var_rename_test.js +0 -39
  829. package/blockly-rc/tests/mocha/event_var_type_change_test.js +0 -43
  830. package/blockly-rc/tests/mocha/event_viewport_test.js +0 -39
  831. package/blockly-rc/tests/mocha/extensions_test.js +0 -613
  832. package/blockly-rc/tests/mocha/field_checkbox_test.js +0 -299
  833. package/blockly-rc/tests/mocha/field_colour_test.js +0 -395
  834. package/blockly-rc/tests/mocha/field_dropdown_test.js +0 -282
  835. package/blockly-rc/tests/mocha/field_image_test.js +0 -241
  836. package/blockly-rc/tests/mocha/field_label_serializable_test.js +0 -252
  837. package/blockly-rc/tests/mocha/field_label_test.js +0 -226
  838. package/blockly-rc/tests/mocha/field_number_test.js +0 -505
  839. package/blockly-rc/tests/mocha/field_registry_test.js +0 -116
  840. package/blockly-rc/tests/mocha/field_test.js +0 -822
  841. package/blockly-rc/tests/mocha/field_textinput_test.js +0 -297
  842. package/blockly-rc/tests/mocha/field_variable_test.js +0 -611
  843. package/blockly-rc/tests/mocha/flyout_test.js +0 -638
  844. package/blockly-rc/tests/mocha/generator_test.js +0 -233
  845. package/blockly-rc/tests/mocha/gesture_test.js +0 -97
  846. package/blockly-rc/tests/mocha/icon_test.js +0 -369
  847. package/blockly-rc/tests/mocha/index.html +0 -229
  848. package/blockly-rc/tests/mocha/input_test.js +0 -296
  849. package/blockly-rc/tests/mocha/insertion_marker_manager_test.js +0 -443
  850. package/blockly-rc/tests/mocha/insertion_marker_test.js +0 -432
  851. package/blockly-rc/tests/mocha/jso_deserialization_test.js +0 -849
  852. package/blockly-rc/tests/mocha/jso_serialization_test.js +0 -1067
  853. package/blockly-rc/tests/mocha/json_test.js +0 -315
  854. package/blockly-rc/tests/mocha/keydown_test.js +0 -364
  855. package/blockly-rc/tests/mocha/layering_test.js +0 -95
  856. package/blockly-rc/tests/mocha/metrics_test.js +0 -671
  857. package/blockly-rc/tests/mocha/mutator_test.js +0 -87
  858. package/blockly-rc/tests/mocha/names_test.js +0 -97
  859. package/blockly-rc/tests/mocha/old_workspace_comment_test.js +0 -256
  860. package/blockly-rc/tests/mocha/procedure_map_test.js +0 -57
  861. package/blockly-rc/tests/mocha/registry_test.js +0 -281
  862. package/blockly-rc/tests/mocha/render_management_test.js +0 -127
  863. package/blockly-rc/tests/mocha/serializer_test.js +0 -2104
  864. package/blockly-rc/tests/mocha/shortcut_registry_test.js +0 -450
  865. package/blockly-rc/tests/mocha/test_helpers/block_definitions.js +0 -204
  866. package/blockly-rc/tests/mocha/test_helpers/code_generation.js +0 -115
  867. package/blockly-rc/tests/mocha/test_helpers/common.js +0 -106
  868. package/blockly-rc/tests/mocha/test_helpers/events.js +0 -290
  869. package/blockly-rc/tests/mocha/test_helpers/fields.js +0 -310
  870. package/blockly-rc/tests/mocha/test_helpers/icon_mocks.js +0 -81
  871. package/blockly-rc/tests/mocha/test_helpers/procedures.js +0 -302
  872. package/blockly-rc/tests/mocha/test_helpers/serialization.js +0 -124
  873. package/blockly-rc/tests/mocha/test_helpers/setup_teardown.js +0 -209
  874. package/blockly-rc/tests/mocha/test_helpers/toolbox_definitions.js +0 -271
  875. package/blockly-rc/tests/mocha/test_helpers/user_input.js +0 -62
  876. package/blockly-rc/tests/mocha/test_helpers/variables.js +0 -23
  877. package/blockly-rc/tests/mocha/test_helpers/warnings.js +0 -83
  878. package/blockly-rc/tests/mocha/test_helpers/workspace.js +0 -1691
  879. package/blockly-rc/tests/mocha/theme_test.js +0 -307
  880. package/blockly-rc/tests/mocha/toolbox_test.js +0 -761
  881. package/blockly-rc/tests/mocha/tooltip_test.js +0 -276
  882. package/blockly-rc/tests/mocha/touch_test.js +0 -109
  883. package/blockly-rc/tests/mocha/trashcan_test.js +0 -375
  884. package/blockly-rc/tests/mocha/utils_test.js +0 -536
  885. package/blockly-rc/tests/mocha/variable_map_test.js +0 -509
  886. package/blockly-rc/tests/mocha/variable_model_test.js +0 -85
  887. package/blockly-rc/tests/mocha/webdriver.js +0 -96
  888. package/blockly-rc/tests/mocha/widget_div_test.js +0 -272
  889. package/blockly-rc/tests/mocha/workspace_comment_test.js +0 -171
  890. package/blockly-rc/tests/mocha/workspace_svg_test.js +0 -414
  891. package/blockly-rc/tests/mocha/workspace_test.js +0 -27
  892. package/blockly-rc/tests/mocha/xml_test.js +0 -951
  893. package/blockly-rc/tests/mocha/zoom_controls_test.js +0 -81
  894. package/blockly-rc/tests/multi_playground.html +0 -482
  895. package/blockly-rc/tests/node/.eslintrc.json +0 -12
  896. package/blockly-rc/tests/node/.mocharc.js +0 -6
  897. package/blockly-rc/tests/node/run_node_test.mjs +0 -72
  898. package/blockly-rc/tests/playground.html +0 -1280
  899. package/blockly-rc/tests/playgrounds/advanced_playground.html +0 -158
  900. package/blockly-rc/tests/playgrounds/iframe.html +0 -40
  901. package/blockly-rc/tests/playgrounds/screenshot.js +0 -123
  902. package/blockly-rc/tests/scripts/check_metadata.sh +0 -166
  903. package/blockly-rc/tests/scripts/compile_typings.sh +0 -32
  904. package/blockly-rc/tests/scripts/load.mjs +0 -140
  905. package/blockly-rc/tests/scripts/setup_linux_env.sh +0 -7
  906. package/blockly-rc/tests/scripts/update_metadata.sh +0 -46
  907. package/blockly-rc/tests/themes/test_themes.js +0 -62
  908. package/blockly-rc/tests/typescript/README.md +0 -4
  909. package/blockly-rc/tests/typescript/src/field/different_user_input.ts +0 -81
  910. package/blockly-rc/tests/typescript/src/generators/dart.ts +0 -24
  911. package/blockly-rc/tests/typescript/src/generators/javascript.ts +0 -28
  912. package/blockly-rc/tests/typescript/src/generators/lua.ts +0 -24
  913. package/blockly-rc/tests/typescript/src/generators/php.ts +0 -24
  914. package/blockly-rc/tests/typescript/src/generators/python.ts +0 -24
  915. package/blockly-rc/tests/typescript/src/generators.ts +0 -31
  916. package/blockly-rc/tests/typescript/src/msg.ts +0 -20
  917. package/blockly-rc/tests/typescript/tsconfig.json +0 -20
  918. package/blockly-rc/tests/xml/README.txt +0 -11
  919. package/blockly-rc/tests/xml/blockly.xsd +0 -178
  920. package/blockly-rc/tests/xml/invalid.xml +0 -6
  921. package/blockly-rc/tests/xml/toolbox.xml +0 -311
  922. package/blockly-rc/tests/xml/workspace.xml +0 -114
  923. package/blockly-rc/tsconfig.json +0 -37
  924. package/blockly-rc/tsdoc.json +0 -35
  925. package/blockly-rc/typings/README.md +0 -5
  926. package/blockly-rc/typings/blocks.d.ts +0 -17
  927. package/blockly-rc/typings/core.d.ts +0 -7
  928. package/blockly-rc/typings/dart.d.ts +0 -7
  929. package/blockly-rc/typings/index.d.ts +0 -10
  930. package/blockly-rc/typings/javascript.d.ts +0 -7
  931. package/blockly-rc/typings/lua.d.ts +0 -7
  932. package/blockly-rc/typings/msg/ab.d.ts +0 -8
  933. package/blockly-rc/typings/msg/ace.d.ts +0 -8
  934. package/blockly-rc/typings/msg/af.d.ts +0 -8
  935. package/blockly-rc/typings/msg/am.d.ts +0 -8
  936. package/blockly-rc/typings/msg/ar.d.ts +0 -8
  937. package/blockly-rc/typings/msg/ast.d.ts +0 -8
  938. package/blockly-rc/typings/msg/az.d.ts +0 -8
  939. package/blockly-rc/typings/msg/ba.d.ts +0 -8
  940. package/blockly-rc/typings/msg/bcc.d.ts +0 -8
  941. package/blockly-rc/typings/msg/be-tarask.d.ts +0 -8
  942. package/blockly-rc/typings/msg/be.d.ts +0 -8
  943. package/blockly-rc/typings/msg/bg.d.ts +0 -8
  944. package/blockly-rc/typings/msg/bn.d.ts +0 -8
  945. package/blockly-rc/typings/msg/br.d.ts +0 -8
  946. package/blockly-rc/typings/msg/bs.d.ts +0 -8
  947. package/blockly-rc/typings/msg/ca.d.ts +0 -8
  948. package/blockly-rc/typings/msg/cdo.d.ts +0 -8
  949. package/blockly-rc/typings/msg/ce.d.ts +0 -8
  950. package/blockly-rc/typings/msg/cs.d.ts +0 -8
  951. package/blockly-rc/typings/msg/da.d.ts +0 -8
  952. package/blockly-rc/typings/msg/de.d.ts +0 -8
  953. package/blockly-rc/typings/msg/diq.d.ts +0 -8
  954. package/blockly-rc/typings/msg/dtp.d.ts +0 -8
  955. package/blockly-rc/typings/msg/dty.d.ts +0 -8
  956. package/blockly-rc/typings/msg/ee.d.ts +0 -8
  957. package/blockly-rc/typings/msg/el.d.ts +0 -8
  958. package/blockly-rc/typings/msg/en-gb.d.ts +0 -8
  959. package/blockly-rc/typings/msg/en.d.ts +0 -8
  960. package/blockly-rc/typings/msg/eo.d.ts +0 -8
  961. package/blockly-rc/typings/msg/es.d.ts +0 -8
  962. package/blockly-rc/typings/msg/et.d.ts +0 -8
  963. package/blockly-rc/typings/msg/eu.d.ts +0 -8
  964. package/blockly-rc/typings/msg/fa.d.ts +0 -8
  965. package/blockly-rc/typings/msg/fi.d.ts +0 -8
  966. package/blockly-rc/typings/msg/fo.d.ts +0 -8
  967. package/blockly-rc/typings/msg/fr.d.ts +0 -8
  968. package/blockly-rc/typings/msg/frr.d.ts +0 -8
  969. package/blockly-rc/typings/msg/gl.d.ts +0 -8
  970. package/blockly-rc/typings/msg/gn.d.ts +0 -8
  971. package/blockly-rc/typings/msg/gor.d.ts +0 -8
  972. package/blockly-rc/typings/msg/ha.d.ts +0 -8
  973. package/blockly-rc/typings/msg/hak.d.ts +0 -8
  974. package/blockly-rc/typings/msg/he.d.ts +0 -8
  975. package/blockly-rc/typings/msg/hi.d.ts +0 -8
  976. package/blockly-rc/typings/msg/hr.d.ts +0 -8
  977. package/blockly-rc/typings/msg/hrx.d.ts +0 -8
  978. package/blockly-rc/typings/msg/hsb.d.ts +0 -8
  979. package/blockly-rc/typings/msg/hu.d.ts +0 -8
  980. package/blockly-rc/typings/msg/hy.d.ts +0 -8
  981. package/blockly-rc/typings/msg/ia.d.ts +0 -8
  982. package/blockly-rc/typings/msg/id.d.ts +0 -8
  983. package/blockly-rc/typings/msg/ig.d.ts +0 -8
  984. package/blockly-rc/typings/msg/inh.d.ts +0 -8
  985. package/blockly-rc/typings/msg/is.d.ts +0 -8
  986. package/blockly-rc/typings/msg/it.d.ts +0 -8
  987. package/blockly-rc/typings/msg/ja.d.ts +0 -8
  988. package/blockly-rc/typings/msg/ka.d.ts +0 -8
  989. package/blockly-rc/typings/msg/kab.d.ts +0 -8
  990. package/blockly-rc/typings/msg/kbd-cyrl.d.ts +0 -8
  991. package/blockly-rc/typings/msg/km.d.ts +0 -8
  992. package/blockly-rc/typings/msg/kn.d.ts +0 -8
  993. package/blockly-rc/typings/msg/ko.d.ts +0 -8
  994. package/blockly-rc/typings/msg/ksh.d.ts +0 -8
  995. package/blockly-rc/typings/msg/ku-latn.d.ts +0 -8
  996. package/blockly-rc/typings/msg/ky.d.ts +0 -8
  997. package/blockly-rc/typings/msg/la.d.ts +0 -8
  998. package/blockly-rc/typings/msg/lb.d.ts +0 -8
  999. package/blockly-rc/typings/msg/lki.d.ts +0 -8
  1000. package/blockly-rc/typings/msg/lo.d.ts +0 -8
  1001. package/blockly-rc/typings/msg/lrc.d.ts +0 -8
  1002. package/blockly-rc/typings/msg/lt.d.ts +0 -8
  1003. package/blockly-rc/typings/msg/lv.d.ts +0 -8
  1004. package/blockly-rc/typings/msg/mg.d.ts +0 -8
  1005. package/blockly-rc/typings/msg/mk.d.ts +0 -8
  1006. package/blockly-rc/typings/msg/ml.d.ts +0 -8
  1007. package/blockly-rc/typings/msg/mnw.d.ts +0 -8
  1008. package/blockly-rc/typings/msg/ms.d.ts +0 -8
  1009. package/blockly-rc/typings/msg/msg.d.ts +0 -440
  1010. package/blockly-rc/typings/msg/my.d.ts +0 -8
  1011. package/blockly-rc/typings/msg/mzn.d.ts +0 -8
  1012. package/blockly-rc/typings/msg/nb.d.ts +0 -8
  1013. package/blockly-rc/typings/msg/ne.d.ts +0 -8
  1014. package/blockly-rc/typings/msg/nl.d.ts +0 -8
  1015. package/blockly-rc/typings/msg/oc.d.ts +0 -8
  1016. package/blockly-rc/typings/msg/olo.d.ts +0 -8
  1017. package/blockly-rc/typings/msg/pa.d.ts +0 -8
  1018. package/blockly-rc/typings/msg/pl.d.ts +0 -8
  1019. package/blockly-rc/typings/msg/pms.d.ts +0 -8
  1020. package/blockly-rc/typings/msg/ps.d.ts +0 -8
  1021. package/blockly-rc/typings/msg/pt-br.d.ts +0 -8
  1022. package/blockly-rc/typings/msg/pt.d.ts +0 -8
  1023. package/blockly-rc/typings/msg/ro.d.ts +0 -8
  1024. package/blockly-rc/typings/msg/ru.d.ts +0 -8
  1025. package/blockly-rc/typings/msg/sc.d.ts +0 -8
  1026. package/blockly-rc/typings/msg/sco.d.ts +0 -8
  1027. package/blockly-rc/typings/msg/sd.d.ts +0 -8
  1028. package/blockly-rc/typings/msg/shn.d.ts +0 -8
  1029. package/blockly-rc/typings/msg/si.d.ts +0 -8
  1030. package/blockly-rc/typings/msg/sk.d.ts +0 -8
  1031. package/blockly-rc/typings/msg/skr-arab.d.ts +0 -8
  1032. package/blockly-rc/typings/msg/sl.d.ts +0 -8
  1033. package/blockly-rc/typings/msg/smn.d.ts +0 -8
  1034. package/blockly-rc/typings/msg/sq.d.ts +0 -8
  1035. package/blockly-rc/typings/msg/sr-latn.d.ts +0 -8
  1036. package/blockly-rc/typings/msg/sr.d.ts +0 -8
  1037. package/blockly-rc/typings/msg/sv.d.ts +0 -8
  1038. package/blockly-rc/typings/msg/sw.d.ts +0 -8
  1039. package/blockly-rc/typings/msg/ta.d.ts +0 -8
  1040. package/blockly-rc/typings/msg/tcy.d.ts +0 -8
  1041. package/blockly-rc/typings/msg/tdd.d.ts +0 -8
  1042. package/blockly-rc/typings/msg/te.d.ts +0 -8
  1043. package/blockly-rc/typings/msg/th.d.ts +0 -8
  1044. package/blockly-rc/typings/msg/ti.d.ts +0 -8
  1045. package/blockly-rc/typings/msg/tl.d.ts +0 -8
  1046. package/blockly-rc/typings/msg/tlh.d.ts +0 -8
  1047. package/blockly-rc/typings/msg/tr.d.ts +0 -8
  1048. package/blockly-rc/typings/msg/ug-arab.d.ts +0 -8
  1049. package/blockly-rc/typings/msg/uk.d.ts +0 -8
  1050. package/blockly-rc/typings/msg/ur.d.ts +0 -8
  1051. package/blockly-rc/typings/msg/uz.d.ts +0 -8
  1052. package/blockly-rc/typings/msg/vi.d.ts +0 -8
  1053. package/blockly-rc/typings/msg/xmf.d.ts +0 -8
  1054. package/blockly-rc/typings/msg/yo.d.ts +0 -8
  1055. package/blockly-rc/typings/msg/zgh.d.ts +0 -8
  1056. package/blockly-rc/typings/msg/zh-hans.d.ts +0 -8
  1057. package/blockly-rc/typings/msg/zh-hant.d.ts +0 -8
  1058. package/blockly-rc/typings/php.d.ts +0 -7
  1059. package/blockly-rc/typings/python.d.ts +0 -7
  1060. package/blockly-rc/typings/templates/blockly-header.template +0 -11
  1061. package/blockly-rc/typings/templates/blockly-interfaces.template +0 -83
  1062. package/blockly-rc/typings/templates/msg.template +0 -15
  1063. package/blockly-rc/typings/tsconfig.json +0 -23
  1064. package/temp-use-blockly-v12-rc.sh +0 -26
@@ -1,968 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright 2011 Google LLC
4
- * SPDX-License-Identifier: Apache-2.0
5
- */
6
-
7
- /**
8
- * Flyout tray containing blocks which may be created.
9
- *
10
- * @class
11
- */
12
- // Former goog.module ID: Blockly.Flyout
13
-
14
- import type {Abstract as AbstractEvent} from './events/events_abstract.js';
15
- import {BlockSvg} from './block_svg.js';
16
- import * as browserEvents from './browser_events.js';
17
- import {ComponentManager} from './component_manager.js';
18
- import {DeleteArea} from './delete_area.js';
19
- import * as eventUtils from './events/utils.js';
20
- import {FlyoutMetricsManager} from './flyout_metrics_manager.js';
21
- import type {IFlyout} from './interfaces/i_flyout.js';
22
- import type {IFlyoutInflater} from './interfaces/i_flyout_inflater.js';
23
- import type {IBoundedElement} from './interfaces/i_bounded_element.js';
24
- import type {Options} from './options.js';
25
- import {ScrollbarPair} from './scrollbar_pair.js';
26
- import * as blocks from './serialization/blocks.js';
27
- import {Coordinate} from './utils/coordinate.js';
28
- import * as dom from './utils/dom.js';
29
- import * as idGenerator from './utils/idgenerator.js';
30
- import {Svg} from './utils/svg.js';
31
- import * as toolbox from './utils/toolbox.js';
32
- import * as Variables from './variables.js';
33
- import {WorkspaceSvg} from './workspace_svg.js';
34
- import * as registry from './registry.js';
35
- import * as renderManagement from './render_management.js';
36
- import {IAutoHideable} from './interfaces/i_autohideable.js';
37
- import {FlyoutSeparator, SeparatorAxis} from './flyout_separator.js';
38
-
39
- /**
40
- * Class for a flyout.
41
- */
42
- export abstract class Flyout
43
- extends DeleteArea
44
- implements IAutoHideable, IFlyout
45
- {
46
- /**
47
- * Position the flyout.
48
- */
49
- abstract position(): void;
50
-
51
- /**
52
- * Determine if a drag delta is toward the workspace, based on the position
53
- * and orientation of the flyout. This is used in determineDragIntention_ to
54
- * determine if a new block should be created or if the flyout should scroll.
55
- *
56
- * @param currentDragDeltaXY How far the pointer has
57
- * moved from the position at mouse down, in pixel units.
58
- * @returns True if the drag is toward the workspace.
59
- */
60
- abstract isDragTowardWorkspace(currentDragDeltaXY: Coordinate): boolean;
61
-
62
- /**
63
- * Sets the translation of the flyout to match the scrollbars.
64
- *
65
- * @param xyRatio Contains a y property which is a float
66
- * between 0 and 1 specifying the degree of scrolling and a
67
- * similar x property.
68
- */
69
- protected abstract setMetrics_(xyRatio: {x?: number; y?: number}): void;
70
-
71
- /**
72
- * Lay out the elements in the flyout.
73
- *
74
- * @param contents The flyout elements to lay out.
75
- */
76
- protected abstract layout_(contents: FlyoutItem[]): void;
77
-
78
- /**
79
- * Scroll the flyout.
80
- *
81
- * @param e Mouse wheel scroll event.
82
- */
83
- protected abstract wheel_(e: WheelEvent): void;
84
-
85
- /**
86
- * Compute bounds of flyout.
87
- * For RTL: Lay out the elements right-aligned.
88
- */
89
- protected abstract reflowInternal_(): void;
90
-
91
- /**
92
- * Calculates the x coordinate for the flyout position.
93
- *
94
- * @returns X coordinate.
95
- */
96
- abstract getX(): number;
97
-
98
- /**
99
- * Calculates the y coordinate for the flyout position.
100
- *
101
- * @returns Y coordinate.
102
- */
103
- abstract getY(): number;
104
-
105
- /**
106
- * Scroll the flyout to the beginning of its contents.
107
- */
108
- abstract scrollToStart(): void;
109
-
110
- protected workspace_: WorkspaceSvg;
111
- RTL: boolean;
112
- /**
113
- * Whether the flyout should be laid out horizontally or not.
114
- *
115
- * @internal
116
- */
117
- horizontalLayout = false;
118
- protected toolboxPosition_: number;
119
-
120
- /**
121
- * Array holding info needed to unbind events.
122
- * Used for disposing.
123
- * Ex: [[node, name, func], [node, name, func]].
124
- */
125
- private boundEvents: browserEvents.Data[] = [];
126
-
127
- /**
128
- * Function that will be registered as a change listener on the workspace
129
- * to reflow when elements in the flyout workspace change.
130
- */
131
- private reflowWrapper: ((e: AbstractEvent) => void) | null = null;
132
-
133
- /**
134
- * List of flyout elements.
135
- */
136
- protected contents: FlyoutItem[] = [];
137
-
138
- protected readonly tabWidth_: number;
139
-
140
- /**
141
- * The target workspace.
142
- *
143
- * @internal
144
- */
145
- targetWorkspace!: WorkspaceSvg;
146
-
147
- /**
148
- * Does the flyout automatically close when a block is created?
149
- */
150
- autoClose = true;
151
-
152
- /**
153
- * Whether the flyout is visible.
154
- */
155
- private isVisible_ = false;
156
-
157
- /**
158
- * Whether the workspace containing this flyout is visible.
159
- */
160
- private containerVisible = true;
161
-
162
- /**
163
- * Corner radius of the flyout background.
164
- */
165
- readonly CORNER_RADIUS: number = 8;
166
- readonly MARGIN: number;
167
- readonly GAP_X: number;
168
- readonly GAP_Y: number;
169
-
170
- /**
171
- * Top/bottom padding between scrollbar and edge of flyout background.
172
- */
173
- readonly SCROLLBAR_MARGIN: number = 2.5;
174
-
175
- /**
176
- * Width of flyout.
177
- */
178
- protected width_ = 0;
179
-
180
- /**
181
- * Height of flyout.
182
- */
183
- protected height_ = 0;
184
- // clang-format off
185
- /**
186
- * Range of a drag angle from a flyout considered "dragging toward
187
- * workspace". Drags that are within the bounds of this many degrees from
188
- * the orthogonal line to the flyout edge are considered to be "drags toward
189
- * the workspace".
190
- *
191
- * @example
192
- *
193
- * ```
194
- * Flyout Edge Workspace
195
- * [block] / <-within this angle, drags "toward workspace" |
196
- * [block] ---- orthogonal to flyout boundary ---- |
197
- * [block] \ |
198
- * ```
199
- *
200
- * The angle is given in degrees from the orthogonal.
201
- *
202
- * This is used to know when to create a new block and when to scroll the
203
- * flyout. Setting it to 360 means that all drags create a new block.
204
- */
205
- // clang-format on
206
- protected dragAngleRange_ = 70;
207
-
208
- /**
209
- * The path around the background of the flyout, which will be filled with a
210
- * background colour.
211
- */
212
- protected svgBackground_: SVGPathElement | null = null;
213
-
214
- /**
215
- * The root SVG group for the button or label.
216
- */
217
- protected svgGroup_: SVGGElement | null = null;
218
-
219
- /**
220
- * Map from flyout content type to the corresponding inflater class
221
- * responsible for creating concrete instances of the content type.
222
- */
223
- protected inflaters = new Map<string, IFlyoutInflater>();
224
-
225
- /**
226
- * @param workspaceOptions Dictionary of options for the
227
- * workspace.
228
- */
229
- constructor(workspaceOptions: Options) {
230
- super();
231
- workspaceOptions.setMetrics = this.setMetrics_.bind(this);
232
-
233
- this.workspace_ = new WorkspaceSvg(workspaceOptions);
234
- this.workspace_.setMetricsManager(
235
- new FlyoutMetricsManager(this.workspace_, this),
236
- );
237
-
238
- this.workspace_.internalIsFlyout = true;
239
- // Keep the workspace visibility consistent with the flyout's visibility.
240
- this.workspace_.setVisible(this.isVisible_);
241
-
242
- /**
243
- * The unique id for this component that is used to register with the
244
- * ComponentManager.
245
- */
246
- this.id = idGenerator.genUid();
247
-
248
- /**
249
- * Is RTL vs LTR.
250
- */
251
- this.RTL = !!workspaceOptions.RTL;
252
-
253
- /**
254
- * Position of the toolbox and flyout relative to the workspace.
255
- */
256
- this.toolboxPosition_ = workspaceOptions.toolboxPosition;
257
-
258
- /**
259
- * Width of output tab.
260
- */
261
- this.tabWidth_ = this.workspace_.getRenderer().getConstants().TAB_WIDTH;
262
-
263
- /**
264
- * Margin around the edges of the elements in the flyout.
265
- */
266
- this.MARGIN = this.CORNER_RADIUS;
267
-
268
- // TODO: Move GAP_X and GAP_Y to their appropriate files.
269
- /**
270
- * Gap between items in horizontal flyouts. Can be overridden with the "sep"
271
- * element.
272
- */
273
- this.GAP_X = this.MARGIN * 3;
274
-
275
- /**
276
- * Gap between items in vertical flyouts. Can be overridden with the "sep"
277
- * element.
278
- */
279
- this.GAP_Y = this.MARGIN * 3;
280
- }
281
-
282
- /**
283
- * Creates the flyout's DOM. Only needs to be called once. The flyout can
284
- * either exist as its own SVG element or be a g element nested inside a
285
- * separate SVG element.
286
- *
287
- * @param tagName The type of tag to
288
- * put the flyout in. This should be <svg> or <g>.
289
- * @returns The flyout's SVG group.
290
- */
291
- createDom(
292
- tagName: string | Svg<SVGSVGElement> | Svg<SVGGElement>,
293
- ): SVGElement {
294
- /*
295
- <svg | g>
296
- <path class="blocklyFlyoutBackground"/>
297
- <g class="blocklyFlyout"></g>
298
- </ svg | g>
299
- */
300
- // Setting style to display:none to start. The toolbox and flyout
301
- // hide/show code will set up proper visibility and size later.
302
- this.svgGroup_ = dom.createSvgElement(tagName, {
303
- 'class': 'blocklyFlyout',
304
- });
305
- this.svgGroup_.style.display = 'none';
306
- this.svgBackground_ = dom.createSvgElement(
307
- Svg.PATH,
308
- {'class': 'blocklyFlyoutBackground'},
309
- this.svgGroup_,
310
- );
311
- this.svgGroup_.appendChild(this.workspace_.createDom());
312
- this.workspace_
313
- .getThemeManager()
314
- .subscribe(this.svgBackground_, 'flyoutBackgroundColour', 'fill');
315
- this.workspace_
316
- .getThemeManager()
317
- .subscribe(this.svgBackground_, 'flyoutOpacity', 'fill-opacity');
318
- return this.svgGroup_;
319
- }
320
-
321
- /**
322
- * Initializes the flyout.
323
- *
324
- * @param targetWorkspace The workspace in which to
325
- * create new blocks.
326
- */
327
- init(targetWorkspace: WorkspaceSvg) {
328
- this.targetWorkspace = targetWorkspace;
329
- this.workspace_.targetWorkspace = targetWorkspace;
330
-
331
- this.workspace_.scrollbar = new ScrollbarPair(
332
- this.workspace_,
333
- this.horizontalLayout,
334
- !this.horizontalLayout,
335
- 'blocklyFlyoutScrollbar',
336
- this.SCROLLBAR_MARGIN,
337
- );
338
-
339
- this.hide();
340
-
341
- this.boundEvents.push(
342
- browserEvents.conditionalBind(
343
- this.svgGroup_ as SVGGElement,
344
- 'wheel',
345
- this,
346
- this.wheel_,
347
- ),
348
- );
349
-
350
- // Dragging the flyout up and down.
351
- this.boundEvents.push(
352
- browserEvents.conditionalBind(
353
- this.svgBackground_ as SVGPathElement,
354
- 'pointerdown',
355
- this,
356
- this.onMouseDown,
357
- ),
358
- );
359
-
360
- // A flyout connected to a workspace doesn't have its own current gesture.
361
- this.workspace_.getGesture = this.targetWorkspace.getGesture.bind(
362
- this.targetWorkspace,
363
- );
364
-
365
- // Get variables from the main workspace rather than the target workspace.
366
- this.workspace_.setVariableMap(this.targetWorkspace.getVariableMap());
367
-
368
- this.workspace_.createPotentialVariableMap();
369
-
370
- targetWorkspace.getComponentManager().addComponent({
371
- component: this,
372
- weight: 1,
373
- capabilities: [
374
- ComponentManager.Capability.AUTOHIDEABLE,
375
- ComponentManager.Capability.DELETE_AREA,
376
- ComponentManager.Capability.DRAG_TARGET,
377
- ],
378
- });
379
- }
380
-
381
- /**
382
- * Dispose of this flyout.
383
- * Unlink from all DOM elements to prevent memory leaks.
384
- */
385
- dispose() {
386
- this.hide();
387
- this.targetWorkspace.getComponentManager().removeComponent(this.id);
388
- for (const event of this.boundEvents) {
389
- browserEvents.unbind(event);
390
- }
391
- this.boundEvents.length = 0;
392
- if (this.workspace_) {
393
- this.workspace_.getThemeManager().unsubscribe(this.svgBackground_!);
394
- this.workspace_.dispose();
395
- }
396
- if (this.svgGroup_) {
397
- dom.removeNode(this.svgGroup_);
398
- }
399
- }
400
-
401
- /**
402
- * Get the width of the flyout.
403
- *
404
- * @returns The width of the flyout.
405
- */
406
- getWidth(): number {
407
- return this.width_;
408
- }
409
-
410
- /**
411
- * Get the height of the flyout.
412
- *
413
- * @returns The width of the flyout.
414
- */
415
- getHeight(): number {
416
- return this.height_;
417
- }
418
-
419
- /**
420
- * Get the scale (zoom level) of the flyout. By default,
421
- * this matches the target workspace scale, but this can be overridden.
422
- *
423
- * @returns Flyout workspace scale.
424
- */
425
- getFlyoutScale(): number {
426
- return this.targetWorkspace.scale;
427
- }
428
-
429
- /**
430
- * Get the workspace inside the flyout.
431
- *
432
- * @returns The workspace inside the flyout.
433
- */
434
- getWorkspace(): WorkspaceSvg {
435
- return this.workspace_;
436
- }
437
-
438
- /**
439
- * Sets whether this flyout automatically closes when blocks are dragged out,
440
- * the workspace is clicked, etc, or not.
441
- */
442
- setAutoClose(autoClose: boolean) {
443
- this.autoClose = autoClose;
444
- this.targetWorkspace.recordDragTargets();
445
- this.targetWorkspace.resizeContents();
446
- }
447
-
448
- /** Automatically hides the flyout if it is an autoclosing flyout. */
449
- autoHide(onlyClosePopups: boolean): void {
450
- if (
451
- !onlyClosePopups &&
452
- this.targetWorkspace.getFlyout(true) === this &&
453
- this.autoClose
454
- )
455
- this.hide();
456
- }
457
-
458
- /**
459
- * Get the target workspace inside the flyout.
460
- *
461
- * @returns The target workspace inside the flyout.
462
- */
463
- getTargetWorkspace(): WorkspaceSvg {
464
- return this.targetWorkspace;
465
- }
466
-
467
- /**
468
- * Is the flyout visible?
469
- *
470
- * @returns True if visible.
471
- */
472
- isVisible(): boolean {
473
- return this.isVisible_;
474
- }
475
-
476
- /**
477
- * Set whether the flyout is visible. A value of true does not necessarily
478
- * mean that the flyout is shown. It could be hidden because its container is
479
- * hidden.
480
- *
481
- * @param visible True if visible.
482
- */
483
- setVisible(visible: boolean) {
484
- const visibilityChanged = visible !== this.isVisible();
485
-
486
- this.isVisible_ = visible;
487
- if (visibilityChanged) {
488
- if (!this.autoClose) {
489
- // Auto-close flyouts are ignored as drag targets, so only non
490
- // auto-close flyouts need to have their drag target updated.
491
- this.targetWorkspace.recordDragTargets();
492
- }
493
- this.updateDisplay();
494
- }
495
- }
496
-
497
- /**
498
- * Set whether this flyout's container is visible.
499
- *
500
- * @param visible Whether the container is visible.
501
- */
502
- setContainerVisible(visible: boolean) {
503
- const visibilityChanged = visible !== this.containerVisible;
504
- this.containerVisible = visible;
505
- if (visibilityChanged) {
506
- this.updateDisplay();
507
- }
508
- }
509
-
510
- /**
511
- * Get the list of elements of the current flyout.
512
- *
513
- * @returns The array of flyout elements.
514
- */
515
- getContents(): FlyoutItem[] {
516
- return this.contents;
517
- }
518
-
519
- /**
520
- * Store the list of elements on the flyout.
521
- *
522
- * @param contents - The array of items for the flyout.
523
- */
524
- setContents(contents: FlyoutItem[]): void {
525
- this.contents = contents;
526
- }
527
- /**
528
- * Update the display property of the flyout based whether it thinks it should
529
- * be visible and whether its containing workspace is visible.
530
- */
531
- private updateDisplay() {
532
- let show = true;
533
- if (!this.containerVisible) {
534
- show = false;
535
- } else {
536
- show = this.isVisible();
537
- }
538
- if (this.svgGroup_) {
539
- this.svgGroup_.style.display = show ? 'block' : 'none';
540
- }
541
- // Update the scrollbar's visibility too since it should mimic the
542
- // flyout's visibility.
543
- this.workspace_.scrollbar?.setContainerVisible(show);
544
- }
545
-
546
- /**
547
- * Update the view based on coordinates calculated in position().
548
- *
549
- * @param width The computed width of the flyout's SVG group
550
- * @param height The computed height of the flyout's SVG group.
551
- * @param x The computed x origin of the flyout's SVG group.
552
- * @param y The computed y origin of the flyout's SVG group.
553
- */
554
- protected positionAt_(width: number, height: number, x: number, y: number) {
555
- this.svgGroup_?.setAttribute('width', `${width}`);
556
- this.svgGroup_?.setAttribute('height', `${height}`);
557
- this.workspace_.setCachedParentSvgSize(width, height);
558
-
559
- if (this.svgGroup_) {
560
- const transform = 'translate(' + x + 'px,' + y + 'px)';
561
- dom.setCssTransform(this.svgGroup_, transform);
562
- }
563
-
564
- // Update the scrollbar (if one exists).
565
- const scrollbar = this.workspace_.scrollbar;
566
- if (scrollbar) {
567
- // Set the scrollbars origin to be the top left of the flyout.
568
- scrollbar.setOrigin(x, y);
569
- scrollbar.resize();
570
- // If origin changed and metrics haven't changed enough to trigger
571
- // reposition in resize, we need to call setPosition. See issue #4692.
572
- if (scrollbar.hScroll) {
573
- scrollbar.hScroll.setPosition(
574
- scrollbar.hScroll.position.x,
575
- scrollbar.hScroll.position.y,
576
- );
577
- }
578
- if (scrollbar.vScroll) {
579
- scrollbar.vScroll.setPosition(
580
- scrollbar.vScroll.position.x,
581
- scrollbar.vScroll.position.y,
582
- );
583
- }
584
- }
585
- }
586
-
587
- /**
588
- * Hide and empty the flyout.
589
- */
590
- hide() {
591
- if (!this.isVisible()) {
592
- return;
593
- }
594
- this.setVisible(false);
595
- if (this.reflowWrapper) {
596
- this.workspace_.removeChangeListener(this.reflowWrapper);
597
- this.reflowWrapper = null;
598
- }
599
- // Do NOT delete the flyout contents here. Wait until Flyout.show.
600
- // https://neil.fraser.name/news/2014/08/09/
601
- }
602
-
603
- /**
604
- * Show and populate the flyout.
605
- *
606
- * @param flyoutDef Contents to display
607
- * in the flyout. This is either an array of Nodes, a NodeList, a
608
- * toolbox definition, or a string with the name of the dynamic category.
609
- */
610
- show(flyoutDef: toolbox.FlyoutDefinition | string) {
611
- this.workspace_.setResizesEnabled(false);
612
- this.hide();
613
- this.clearOldBlocks();
614
-
615
- // Handle dynamic categories, represented by a name instead of a list.
616
- if (typeof flyoutDef === 'string') {
617
- flyoutDef = this.getDynamicCategoryContents(flyoutDef);
618
- }
619
- this.setVisible(true);
620
-
621
- // Parse the Array, Node or NodeList into a a list of flyout items.
622
- const parsedContent = toolbox.convertFlyoutDefToJsonArray(flyoutDef);
623
- const flyoutInfo = this.createFlyoutInfo(parsedContent);
624
-
625
- renderManagement.triggerQueuedRenders(this.workspace_);
626
-
627
- this.setContents(flyoutInfo);
628
-
629
- this.layout_(flyoutInfo);
630
-
631
- if (this.horizontalLayout) {
632
- this.height_ = 0;
633
- } else {
634
- this.width_ = 0;
635
- }
636
- this.workspace_.setResizesEnabled(true);
637
- this.reflow();
638
-
639
- // Listen for block change events, and reflow the flyout in response. This
640
- // accommodates e.g. resizing a non-autoclosing flyout in response to the
641
- // user typing long strings into fields on the blocks in the flyout.
642
- this.reflowWrapper = (event) => {
643
- if (
644
- event.type === eventUtils.BLOCK_CHANGE ||
645
- event.type === eventUtils.BLOCK_FIELD_INTERMEDIATE_CHANGE
646
- ) {
647
- this.reflow();
648
- }
649
- };
650
- this.workspace_.addChangeListener(this.reflowWrapper);
651
- }
652
-
653
- /**
654
- * Create the contents array and gaps array necessary to create the layout for
655
- * the flyout.
656
- *
657
- * @param parsedContent The array
658
- * of objects to show in the flyout.
659
- * @returns The list of contents needed to lay out the flyout.
660
- */
661
- private createFlyoutInfo(
662
- parsedContent: toolbox.FlyoutItemInfoArray,
663
- ): FlyoutItem[] {
664
- const contents: FlyoutItem[] = [];
665
- const defaultGap = this.horizontalLayout ? this.GAP_X : this.GAP_Y;
666
- for (const info of parsedContent) {
667
- if ('custom' in info) {
668
- const customInfo = info as toolbox.DynamicCategoryInfo;
669
- const categoryName = customInfo['custom'];
670
- const flyoutDef = this.getDynamicCategoryContents(categoryName);
671
- const parsedDynamicContent =
672
- toolbox.convertFlyoutDefToJsonArray(flyoutDef);
673
- contents.push(...this.createFlyoutInfo(parsedDynamicContent));
674
- }
675
-
676
- const type = info['kind'].toLowerCase();
677
- const inflater = this.getInflaterForType(type);
678
- if (inflater) {
679
- const element = inflater.load(info, this.getWorkspace());
680
- contents.push({
681
- type,
682
- element,
683
- });
684
- const gap = inflater.gapForElement(info, defaultGap);
685
- if (gap) {
686
- contents.push({
687
- type: 'sep',
688
- element: new FlyoutSeparator(
689
- gap,
690
- this.horizontalLayout ? SeparatorAxis.X : SeparatorAxis.Y,
691
- ),
692
- });
693
- }
694
- }
695
- }
696
-
697
- return this.normalizeSeparators(contents);
698
- }
699
-
700
- /**
701
- * Updates and returns the provided list of flyout contents to flatten
702
- * separators as needed.
703
- *
704
- * When multiple separators occur one after another, the value of the last one
705
- * takes precedence and the earlier separators in the group are removed.
706
- *
707
- * @param contents The list of flyout contents to flatten separators in.
708
- * @returns An updated list of flyout contents with only one separator between
709
- * each non-separator item.
710
- */
711
- protected normalizeSeparators(contents: FlyoutItem[]): FlyoutItem[] {
712
- for (let i = contents.length - 1; i > 0; i--) {
713
- const elementType = contents[i].type.toLowerCase();
714
- const previousElementType = contents[i - 1].type.toLowerCase();
715
- if (elementType === 'sep' && previousElementType === 'sep') {
716
- // Remove previousElement from the array, shifting the current element
717
- // forward as a result. This preserves the behavior where explicit
718
- // separator elements override the value of prior implicit (or explicit)
719
- // separator elements.
720
- contents.splice(i - 1, 1);
721
- }
722
- }
723
-
724
- return contents;
725
- }
726
-
727
- /**
728
- * Gets the flyout definition for the dynamic category.
729
- *
730
- * @param categoryName The name of the dynamic category.
731
- * @returns The definition of the
732
- * flyout in one of its many forms.
733
- */
734
- private getDynamicCategoryContents(
735
- categoryName: string,
736
- ): toolbox.FlyoutDefinition {
737
- // Look up the correct category generation function and call that to get a
738
- // valid XML list.
739
- const fnToApply =
740
- this.workspace_.targetWorkspace!.getToolboxCategoryCallback(categoryName);
741
- if (typeof fnToApply !== 'function') {
742
- throw TypeError(
743
- "Couldn't find a callback function when opening" +
744
- ' a toolbox category.',
745
- );
746
- }
747
- return fnToApply(this.workspace_.targetWorkspace!);
748
- }
749
-
750
- /**
751
- * Delete elements from a previous showing of the flyout.
752
- */
753
- private clearOldBlocks() {
754
- this.getContents().forEach((element) => {
755
- const inflater = this.getInflaterForType(element.type);
756
- inflater?.disposeElement(element.element);
757
- });
758
-
759
- // Clear potential variables from the previous showing.
760
- this.workspace_.getPotentialVariableMap()?.clear();
761
- }
762
-
763
- /**
764
- * Pointer down on the flyout background. Start a vertical scroll drag.
765
- *
766
- * @param e Pointer down event.
767
- */
768
- private onMouseDown(e: PointerEvent) {
769
- const gesture = this.targetWorkspace.getGesture(e);
770
- if (gesture) {
771
- gesture.handleFlyoutStart(e, this);
772
- }
773
- }
774
-
775
- /**
776
- * Does this flyout allow you to create a new instance of the given block?
777
- * Used for deciding if a block can be "dragged out of" the flyout.
778
- *
779
- * @param block The block to copy from the flyout.
780
- * @returns True if you can create a new instance of the block, false
781
- * otherwise.
782
- * @internal
783
- */
784
- isBlockCreatable(block: BlockSvg): boolean {
785
- return block.isEnabled();
786
- }
787
-
788
- /**
789
- * Create a copy of this block on the workspace.
790
- *
791
- * @param originalBlock The block to copy from the flyout.
792
- * @returns The newly created block.
793
- * @throws {Error} if something went wrong with deserialization.
794
- * @internal
795
- */
796
- createBlock(originalBlock: BlockSvg): BlockSvg {
797
- let newBlock = null;
798
- eventUtils.disable();
799
- const variablesBeforeCreation = this.targetWorkspace.getAllVariables();
800
- this.targetWorkspace.setResizesEnabled(false);
801
- try {
802
- newBlock = this.placeNewBlock(originalBlock);
803
- } finally {
804
- eventUtils.enable();
805
- }
806
-
807
- // Close the flyout.
808
- this.targetWorkspace.hideChaff();
809
-
810
- const newVariables = Variables.getAddedVariables(
811
- this.targetWorkspace,
812
- variablesBeforeCreation,
813
- );
814
-
815
- if (eventUtils.isEnabled()) {
816
- eventUtils.setGroup(true);
817
- // Fire a VarCreate event for each (if any) new variable created.
818
- for (let i = 0; i < newVariables.length; i++) {
819
- const thisVariable = newVariables[i];
820
- eventUtils.fire(
821
- new (eventUtils.get(eventUtils.VAR_CREATE))(thisVariable),
822
- );
823
- }
824
-
825
- // Block events come after var events, in case they refer to newly created
826
- // variables.
827
- eventUtils.fire(new (eventUtils.get(eventUtils.BLOCK_CREATE))(newBlock));
828
- }
829
- if (this.autoClose) {
830
- this.hide();
831
- }
832
- return newBlock;
833
- }
834
-
835
- /**
836
- * Reflow flyout contents.
837
- */
838
- reflow() {
839
- if (this.reflowWrapper) {
840
- this.workspace_.removeChangeListener(this.reflowWrapper);
841
- }
842
- this.reflowInternal_();
843
- if (this.reflowWrapper) {
844
- this.workspace_.addChangeListener(this.reflowWrapper);
845
- }
846
- }
847
-
848
- /**
849
- * @returns True if this flyout may be scrolled with a scrollbar or
850
- * by dragging.
851
- * @internal
852
- */
853
- isScrollable(): boolean {
854
- return this.workspace_.scrollbar
855
- ? this.workspace_.scrollbar.isVisible()
856
- : false;
857
- }
858
-
859
- /**
860
- * Copy a block from the flyout to the workspace and position it correctly.
861
- *
862
- * @param oldBlock The flyout block to copy.
863
- * @returns The new block in the main workspace.
864
- */
865
- private placeNewBlock(oldBlock: BlockSvg): BlockSvg {
866
- const targetWorkspace = this.targetWorkspace;
867
- const svgRootOld = oldBlock.getSvgRoot();
868
- if (!svgRootOld) {
869
- throw Error('oldBlock is not rendered');
870
- }
871
-
872
- // Clone the block.
873
- const json = this.serializeBlock(oldBlock);
874
- // Normally this resizes leading to weird jumps. Save it for terminateDrag.
875
- targetWorkspace.setResizesEnabled(false);
876
- const block = blocks.append(json, targetWorkspace) as BlockSvg;
877
-
878
- this.positionNewBlock(oldBlock, block);
879
-
880
- return block;
881
- }
882
-
883
- /**
884
- * Serialize a block to JSON.
885
- *
886
- * @param block The block to serialize.
887
- * @returns A serialized representation of the block.
888
- */
889
- protected serializeBlock(block: BlockSvg): blocks.State {
890
- return blocks.save(block) as blocks.State;
891
- }
892
-
893
- /**
894
- * Positions a block on the target workspace.
895
- *
896
- * @param oldBlock The flyout block being copied.
897
- * @param block The block to posiiton.
898
- */
899
- private positionNewBlock(oldBlock: BlockSvg, block: BlockSvg) {
900
- const targetWorkspace = this.targetWorkspace;
901
-
902
- // The offset in pixels between the main workspace's origin and the upper
903
- // left corner of the injection div.
904
- const mainOffsetPixels = targetWorkspace.getOriginOffsetInPixels();
905
-
906
- // The offset in pixels between the flyout workspace's origin and the upper
907
- // left corner of the injection div.
908
- const flyoutOffsetPixels = this.workspace_.getOriginOffsetInPixels();
909
-
910
- // The position of the old block in flyout workspace coordinates.
911
- const oldBlockPos = oldBlock.getRelativeToSurfaceXY();
912
- // The position of the old block in pixels relative to the flyout
913
- // workspace's origin.
914
- oldBlockPos.scale(this.workspace_.scale);
915
-
916
- // The position of the old block in pixels relative to the upper left corner
917
- // of the injection div.
918
- const oldBlockOffsetPixels = Coordinate.sum(
919
- flyoutOffsetPixels,
920
- oldBlockPos,
921
- );
922
-
923
- // The position of the old block in pixels relative to the origin of the
924
- // main workspace.
925
- const finalOffset = Coordinate.difference(
926
- oldBlockOffsetPixels,
927
- mainOffsetPixels,
928
- );
929
- // The position of the old block in main workspace coordinates.
930
- finalOffset.scale(1 / targetWorkspace.scale);
931
-
932
- // No 'reason' provided since events are disabled.
933
- block.moveTo(new Coordinate(finalOffset.x, finalOffset.y));
934
- }
935
-
936
- /**
937
- * Returns the inflater responsible for constructing items of the given type.
938
- *
939
- * @param type The type of flyout content item to provide an inflater for.
940
- * @returns An inflater object for the given type, or null if no inflater
941
- * is registered for that type.
942
- */
943
- protected getInflaterForType(type: string): IFlyoutInflater | null {
944
- if (this.inflaters.has(type)) {
945
- return this.inflaters.get(type) ?? null;
946
- }
947
-
948
- const InflaterClass = registry.getClass(
949
- registry.Type.FLYOUT_INFLATER,
950
- type,
951
- );
952
- if (InflaterClass) {
953
- const inflater = new InflaterClass();
954
- this.inflaters.set(type, inflater);
955
- return inflater;
956
- }
957
-
958
- return null;
959
- }
960
- }
961
-
962
- /**
963
- * A flyout content item.
964
- */
965
- export interface FlyoutItem {
966
- type: string;
967
- element: IBoundedElement;
968
- }