Commit Graph

354 Commits

Author SHA1 Message Date
Rachel Fenichel
7ff27bcfc9 Add license; translate the group, not the start point of the path 2019-03-22 11:13:04 -07:00
Rachel Fenichel
74adb31961 Add a playgound for debugging SVG paths 2019-03-14 17:46:19 -07:00
amber-cd
a655e48841 Update playground.html 2019-03-05 08:42:31 -05:00
Rachel Fenichel
dfc74b8c4f Use dropdownDiv for the angle field as well 2019-02-26 14:54:21 -08:00
Beka Westberg
9dec2da5c5 Movement Updates (#2247)
This is a squash and merge of a large set of changes by @BeksOmega 

* Added functionality to scrolling, dragging, and zooming.

* Fixed incorrect changes to workspaceChanged function.

* Fixed comment.

* Fixed typo.

* Removed scrollbar.set calls from workspace_svg.

* Removed scrollbar.resize() call.

* Added move options to playground.

* Fixed scroll_ calls that replaced scrollbar.set calls.

* Removed this.scrollbar checks.

* Changed zoom so that it always zooms towards the coordinates. Changed isContentBounded_ to be separate from isMovable_ (b/c of the previous change zoomControls had to be added to the bounded check). Fixed scroll_() calls... again.

* Changed procedures so the Highlight definition option is only available if the workspace is moveable.

* Fixed scrollCenter so that it works with flyout toolboxes.

* Fixed zoomToFit so that it works with horizontal flyout toolboxes.

* Fixed Typo.

* Fixed bumping blocks when the workspace is not movable.

* Fixed bumping not working with left and top toolbox positions.

* Re-Added not allowing scrollCenter if the workspace is not movable. Disabled scrollCenter button for this case.

* Cleaned up formatting.

* Fixed bumping... again. Reformatted workspaceChanged a bit.

* Changed blocks to be completely bumped into the workspace.

* Reorganized metrics-getting for workspaceChanged.

* Added bumping workspace comments. Moved event checking.

* Renamed workspaceChanged to bumpObjects.

* Added a bumpObjects developer reminder.

* Added warning to zoomToFit.

* Cleaned up some text.

* Added better inline documentation.

* Fixed up inline docs.

* Cleaned up comments.

* Fixed zoomCenter not actually zooming towards the center.

* Fixed zoomControls error on unmovable bottom-toolbox workspaces

* Fixed programatically placing blocks in an unmovable workspace.

* Removed unnecessary translate call in inject.

* Reversed removal of translate. (apparently it was necessary)

* Cleaned up code in response to first round of reviews.

* Added unit comments to the zoom function.

* Removed bumpObjectsEventChecker. Added BUMP_EVENTS list to Blockly.Events.

* Changed getWorkspaceObjectMetrics call to getBoundingRectangle().

* Fixed utils.mouseToSvg (was causing problems with zoom on wheel if the page was scrolled).

* Fixed zoom when page is scrolled (actually this time). Reverted changes to utils.mouseToSvg.

* Fixed centerOnBlock.

* Added unit docs to translate. Moved setting the grid position to the translate function.

* Added TODO's.
2019-02-18 15:28:51 -08:00
Andrew n marshall
f05eed64eb Check against healing child shadow blocks.
Fixes #2227, healing values.
Also applies to shadow next blocks.
Added a playground test block group with a shadow statement.
2019-02-07 13:15:41 -08:00
Andrew n marshall
b61ce94e8d Added a Test Block for a Dynamic Dropdown (PR#2252)
Merged from BeksOmega/tests/DynamicDropdown
2019-02-07 10:26:33 -08:00
Andrew n marshall
114171ada8 language-neutral text -> language-neutral id 2019-02-07 10:22:36 -08:00
alschmiedt
c7b748c4d1 Merge pull request #2270 from alschmiedt/changeStyleNames
Changes colour names
2019-02-06 15:35:59 -08:00
alschmiedt
58c365e377 Changes colour names 2019-02-06 14:24:41 -08:00
Beka Westberg
74e5c49e0d Fixed comments and defaults. 2019-02-05 14:32:40 -08:00
alschmiedt
99f4f48321 Fix event description for theme 2019-02-05 13:43:54 -08:00
Andrew n marshall
463e42e375 New label and title case 2019-02-05 09:13:53 -08:00
Rachel Fenichel
71e91534e8 Update connection_db_test 2019-02-04 08:59:55 -08:00
Beka Westberg
a47ddcb976 Added a test block for a dynamic dropdown. 2019-02-02 09:57:07 -08:00
Rachel Fenichel
a778ce0384 Merge pull request #2212 from rachel-fenichel/cleanup/remove_eslintrc
Remove old eslintrc and use .json for mocha eslintrc
2019-01-22 17:39:05 -08:00
alschmiedt
59e4d985aa Remove unnecessary scripts 2019-01-11 14:36:53 -08:00
alschmiedt
0d78f1dcd5 Fixing compiler error for blockly themes 2019-01-11 14:28:49 -08:00
Rachel Fenichel
c13833b6c5 Remove old eslintrc and use .json for mocha eslintrc 2019-01-11 12:30:34 -08:00
alschmiedt
7941651444 Merge pull request #2184 from alschmiedt/blockly_colours
Blockly Themes
2019-01-11 10:57:57 -08:00
Beka Westberg
969687ec34 Added flipRtl Support for FieldImages (#2203)
* Added flipRtl support for FieldImages. Added a flipRtl test block.

* Added blockfactory support.

* Fixed JSDoc.
2019-01-10 08:59:35 -08:00
alschmiedt
caf664db04 Small fixes 2019-01-09 15:38:30 -08:00
alschmiedt
55a46f8299 Fixes error thrown for style defined inline 2019-01-09 13:44:22 -08:00
Rachel Fenichel
089c30baa1 Add eslintrc to mocha directory 2019-01-09 13:31:07 -08:00
alschmiedt
40a1ae752b Adds support for category styles 2019-01-09 11:18:44 -08:00
alschmiedt
4fad29bf15 Fixes problem with hat style 2019-01-08 14:52:14 -08:00
alschmiedt
e7a120e69f Merge branch 'develop' of https://github.com/alschmiedt/blockly into blockly_colours 2019-01-08 13:36:39 -08:00
Rachel Fenichel
298b93c025 Fix eslint errors with in-file comments 2019-01-08 11:54:57 -08:00
Rachel Fenichel
0ec471332b Delete commented-out code 2019-01-08 11:44:15 -08:00
Rachel Fenichel
ecb8b4fb44 Remove dependenceis and use unpkg 2019-01-08 11:41:57 -08:00
alschmiedt
f480b1ff79 Changes Blockly style to be Blockly theme. 2019-01-08 11:40:57 -08:00
Rachel Fenichel
35f05ce582 Skip two broken test suites 2019-01-08 11:31:35 -08:00
Rachel Fenichel
1c413f0442 More testing with mocha 2019-01-08 11:31:35 -08:00
Rachel Fenichel
e27f58ada7 Add jsunit->chai assert converters, and block tests 2019-01-08 11:30:54 -08:00
Rachel Fenichel
376bed8c46 First pass at creating mocha tests 2019-01-08 11:30:54 -08:00
alschmiedt
1f742bf83d Fixing review comments 2019-01-07 10:38:49 -08:00
alschmiedt
1b3955d9d6 Fixing review comments 2018-12-21 07:52:50 -08:00
alschmiedt
d7de588aef Fix generator tests 2018-12-19 16:48:23 -08:00
alschmiedt
b8a2ccddb0 Debuggin 2018-12-19 16:10:45 -08:00
alschmiedt
3a63ae6feb Comment out removing tmp directory for testing 2018-12-19 15:22:49 -08:00
alschmiedt
8544491228 Small fixes 2018-12-19 09:53:54 -08:00
alschmiedt
692555cf1c Fixes broken set_style test 2018-12-18 13:58:09 -08:00
alschmiedt
efb51eec6a Fix multi playground to work with style 2018-12-18 12:42:33 -08:00
alschmiedt
75212a7413 Adds ability to choose different styles in playground 2018-12-18 10:03:55 -08:00
alschmiedt
4918da9538 Adds ability to provide a hue value for primary colour 2018-12-12 11:39:23 -08:00
alschmiedt
fbd44c80f9 Adds tests for adding blockly styles 2018-12-11 13:25:53 -08:00
Rachel Fenichel
7ec5599829 Merge pull request #2124 from google/update_chromedriver_develop
Update chromedriver version
2018-11-30 13:46:24 -08:00
Rachel Fenichel
b8d7ed1c14 Chromedriver 2.43 -> 2.44 2018-11-30 13:38:40 -08:00
BeksOmega
1c4ba38300 Added Max Instances Property to Workspace Options (#2130)
* Added Max Instances property to Blocks

* eslint cleanup

* eslint cleanup 2

* Moved maxInstances property from block to workspace (as a map of block type to max instances). isDuplicate() changed to correctly handle siblings/branches.

* eslint cleanup

* Changed checking types to map. Added hasBlockLimits. Fixed Nits.

* Added limit_instances test block. eslint fixes.

* fixup! Added limit_instances test block. eslint fixes.

* Changed sorting objects to a private static function of the workspace. Fixed nits. Undeleted .eslintrc

* Reverted .gitignore file.

* Added getBlockTypeCounts() to utils. Added isCapacityAvailable() to workspace. Changed clipboard to save typeCountsMap rather than object.
2018-11-27 16:34:21 -08:00
Rachel Fenichel
6169a6488f Merge pull request #2139 from rachel-fenichel/bugfix/2107
Bugfix/2107
2018-11-27 13:57:10 -08:00