This default Closure image was always being overridden and was never fetched. But it takes some research to determine that this is not in effect a potential monitoring point.
Adds the ability to set the tooltip titles for each colour.
Note that Closure’s colour picker in Blockly used to have keyboard controls (as of > 3 years ago); but no longer seems to. This replacement does not currently have keyboard controls either.
Replace the fixed dropdown height with one responsive to the document's viewport.
This is adapted from Bohdan-Tereta's proposed solution:
https://github.com/google/blockly/pull/1483#issuecomment-381638639
It is sub-optimal, in that is does not adapt to field height (variable
due to workspace zoom), and it does not fully utilize the space above
or below the field if the block is near the top or the bottom.
* Add skeleton for workspace comments
* XML parsing and encoding of workspace comments.
* Minor fix: piping the height and width from xml to newWorkspaceComment
* Move height and width into workspace_comment_svg
* rename newWorkspaceComment to newComment
* minor refactoring. PR changes
* Functions for managing the comment's lifecycle
* Add initial tests
* Add another test
* Add basic rendering of a comment.
* Cleanup remaining highlighting steps from render
* Fix lint
* Fix aslant
* Add basic comment translate
* Simplify render code into one setPath method
* Move steps to setPath_
* Remove svg elements when disposing of a comment; some code cleanup
* Add a workspace comment on context menu click and position it where the initial context menu was clicked.
* Minor rendering changes, fixes RTL. Fix positioning of new (context menu) comments while workspace is scaled.
* PR feedback
* Gesture code for dragging comments
* Add comment (block drag) surface methods
* minor comment fix
* Comment fixes
* Add comment dragger
* Making rendered private
* Require CommentDragger
* Make basic comment dragging work
* Increase the border around the comment to make a bigger drag handle
* Remove typo
* Allow comments to be selected. Highlight selected comment. Only edit comment on click. Updated comment rendering.
* minor refactor: remove commented out code
* PR comments
* lint and rebuild
* Fix renamed function call
* Fix workspace getMetrics by storing comment size as a number, not a string
* Enable comment deletion when dragging over the toolbox or trash can
* Give issue references to some todos
* Create a helper function for workspace comment creation
* Integrate sam's workspace comments, using the bubble dragger
* Remove comment_dragger references
* Remove comment dragger.js
* Remove pointer handling
* Fix lint
* Move comment XML functions into the comment files.
* Fix tests
* Fix type annotations
* Fix comments on comments
* Fix compiler errors related to visibility.
* Fix merge issues and add an issue number to a TODO
* Add a new message for default text on workspace comments, and rebuild
* Add support for a context menu on workspace comment showing delete and duplication options.
Add copy and paste support.
* PR comment feedback
* Show a delete icon on the comment when selected. Delete icon deletes the comment. Comment can be deleted if dragged onto the toolbox or the trash icon. A normal bubble cannot be deleted that way.
* use isDeletable instead
* Support drag of the comment during editing mode using the top handle.
* Add skeletons for all workspace comment events
* Rebuild with new comments
* Get rid of confused TODO
* JSDoc on a function
* Fix broken tests
* More PR feedback
* Fix lint
* Delete comment on mouse out, highlight on mouse down.
* Fix lint.
* Show delete hand cursor when dragging a comment to delete over the toolbox
* Focus textarea on select
* Add delete events
* Remove workspace comment create event, and add TODO placeholder
* Provide default values if comment height and width are missing in XML
* Set comment handle fill to none by default
* Rebuild
* Comment de/serialization should include location.
* Add comment move events, with undo and redo
* Add comment change events
* Move files up to core
* Add package/private annotations wherever possible
* Move the workspace comment events up to core and into a single file
* Mark things package or private where possible
* Get rid of unnecessary changes to messge files
* Fix lint
* Fix some review feedback
* Make changes to the comment db happen in addTopComment and removeTopComment
* Add css classes for toggling comment focus
* Clean up css for comment focus
* Rebuild
* Fix#1487 and only add the delete cursor if the block is not deletable. Also add a grab cursor when it is not deletable so the cursor keeps the grab hand when over the toolbox. This changes the toolbox api slightly, but the methods it touches are @package so it should be okay.
* Fix#1275 by adding a more specific rule for overflow:visible on the drag surface svg. This wins out over a common bootstrap rule that says: svg:not(:root) {overflow:hidden} and helps avoid a difficult problem for Blockly users to diagnose.
* Update css.js
* Add block drag surface translateSurfaceBy
* Add dragged connection manager
* Add gesture.js
* Add GestureHandler
* Implemented gesture skeleton
* Most basic workspace dragging
* Add dragged connection manager
* cleanup
* doc
* more cleanup
* Add gesture handler
* Add translateSurfaceInternal
* core/block_dragger.js
* cleanup
* Pull in changes to dragged connection manager
* Pull in changes to dragged connection manager
* comments
* more annotations
* Add workspace dragger
* Add coordinate annotations
* Start on block dragging
* Limit number of concurrent gestures
* Add some TODOs
* start using dragged connection manager
* Set origin correctly for dragging blocks
* Connect or delete at the end of a block drag.
* cleanup
* handle field clicks and block + workspace right-clicks
* move code into BlockDragger class, but still reach into Gesture internals a lot
* Clean up block dragger
* Call blockDragger constructor with correct arguments
* Enable block dragging in a mutator workspace
* Add workspace dragger
* click todos
* Drag flyout with background
* more dragging from flyout
* nit
* fix dragging from flyouts
* Remove unused code and rename gestureHandler to gestureDB
* Rename gesture handler
* Added some jsdoc in gesture.js
* Update some docs
* Move some code to block_svg and clean up code
* Lots of coordinate annotations
* Fix block dragging when zoomed.
* Remove built files from branch
* More dragging work (#1026)
-- Drag bubbles while dragging blocks
-- Use bindEventWithChecks to work in touch on Android. Not tested anywhere else yet.
-- Handle dragging blocks while zoomed
-- Handle dragging blocks in mutators
-- Handle right-clicks (I hope)
-- Removed lots of unused code
* More dragging work (#1048)
- Removed gestureDB
- Removing uses of terminateDrag
- Cleaned up disposal code
* Dragging bugfixes (#1058)
- Get rid of flyout.dragMode_ and blockly.dragMode_
- Make drags from the flyout start from the top block in the group
- Block tooltips from being scheduled or shown during gestures
- Don't resize mutator bubbles mid-drag
* Fix events in new dragging (#1060)
* rebuild for testing
* unbuild
* Fix events
* rebuild
* Fix up cursors
* Use language files from develop
* Remove handled TODOS
* attempt to fix IE rerendering bug, and recalculate workspace positions on scroll
* Rebuild all the things
* Comment cleanup; annotations; delete unused variables.
* Change how blockly handles cursors. The old way was quite slow because it changed the stylesheet directly. See issue #981 for more details on implementation and tradeoffs. This changes makes the following high level changes: deprecate Blockly.Css.setCursor, use built in open and closed hand cursor instead of custom .cur files, add css to draggable objects to set the open and closed hand cursors.
* Add ability to add a class to a scrollbar so that different types of scrollbars can
be distinguished from each other. You used to be able to do this by looking at the parent
element but now all the scrollbars are siblings in the dom.
Also, use this new class to fix#816 so that layering of the flyout and workspace scrollbars
are done correctly.
* Add a workspace drag surface that blocks and bubble get moved to during a workspace drag.
The surface is translated using translate3d instead of svg's translate attribute so that
the browser does not have to repaint the entire workspace on every mouse move.
This is very similar to the block drag surface.
* Address code review comments
* add back hasClass_ utility removed in #748 and stop using contains since it is not supported in IE
* Split the scrollbar and flyout out into their own SVG elements. They
are siblings of the workpsace SVG. This paves the way to make performance
improvements to workspace dragging.
Improve performance of block dragging. This is a backport of the block drag surface from scratch-blocks. At the beginning of a block drag, blocks get moved to a drag surface which then translates using translate3d to avoid repainting the entire svg on every mouse move. At the end of the drag, the blocks are dropped back in the svg in their new position.
* * apply bootstrap3 integration fixes
* Injection subcontainer
Include svg and div into a master container, which allow css better
positioning (overflow scrolling problem)
* * Fix toolbox positioning (rtl and ltr). Because toolbox if relative to injection div, only adjust it to left (ltr) or right (rtl) edge
* * fix style (thanks to @NeilFraser)
* * revert msg files