From a9223b0b2231ac4c7f081bd664e831d8f2d53b10 Mon Sep 17 00:00:00 2001 From: Monica Kozbial Date: Wed, 25 Mar 2020 15:47:27 -0700 Subject: [PATCH] Typo fixes. (#3769) --- .travis.yml | 2 +- blocks/math.js | 2 +- blocks/text.js | 2 +- core/block.js | 2 +- core/block_svg.js | 2 +- core/components/tree/basenode.js | 4 ++-- core/components/tree/treenode.js | 2 +- core/connection.js | 2 +- core/field.js | 2 +- core/grid.js | 2 +- core/keyboard_nav/ast_node.js | 2 +- core/keyboard_nav/basic_cursor.js | 2 +- core/keyboard_nav/navigation.js | 10 +++++----- core/mutator.js | 2 +- core/names.js | 2 +- core/renderers/common/constants.js | 4 ++-- core/renderers/measurables/types.js | 2 +- core/renderers/zelos/constants.js | 4 ++-- core/renderers/zelos/info.js | 4 ++-- core/renderers/zelos/path_object.js | 2 +- core/theme/tritanopia.js | 2 +- core/utils.js | 2 +- core/utils/svg_paths.js | 2 +- core/workspace_svg.js | 2 +- demos/blockfactory/app_controller.js | 2 +- demos/blockfactory/block_definition_extractor.js | 6 +++--- demos/blockfactory/block_exporter_view.js | 2 +- demos/blockfactory/blocks.js | 2 +- demos/blockfactory/factory_utils.js | 4 ++-- demos/blockfactory_old/blocks.js | 2 +- demos/blockfactory_old/factory.js | 6 +++--- demos/interpreter/async-execution.html | 2 +- demos/keyboard_nav/line_cursor.js | 2 +- demos/mobile/README.md | 2 +- demos/plane/soy/soyutils.js | 4 ++-- demos/storage/index.html | 2 +- scripts/gulpfiles/license_tasks.js | 2 +- scripts/gulpfiles/package_tasks.js | 2 +- tests/blocks/test_blocks.js | 6 +++--- 39 files changed, 55 insertions(+), 55 deletions(-) diff --git a/.travis.yml b/.travis.yml index 643c96a63..287cf1f5a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ node_js: addons: chrome: stable firefox: latest - # TODO (#2114): reenable osx build. + # TODO (#2114): re-enable osx build. # - os: osx # node_js: stable # osx_image: xcode8.3 diff --git a/blocks/math.js b/blocks/math.js index 3583d8d23..b6827c5b1 100644 --- a/blocks/math.js +++ b/blocks/math.js @@ -487,7 +487,7 @@ Blockly.Constants.Math.IS_DIVISIBLEBY_MUTATOR_MIXIN = { /** * 'math_is_divisibleby_mutator' extension to the 'math_property' block that * can update the block shape (add/remove divisor input) based on whether - * property is "divisble by". + * property is "divisible by". * @this {Blockly.Block} * @package */ diff --git a/blocks/text.js b/blocks/text.js index 5f04063e6..65710f1aa 100644 --- a/blocks/text.js +++ b/blocks/text.js @@ -285,7 +285,7 @@ Blockly.Blocks['text_getSubstring'] = { }, /** * Create or delete an input for a numeric index. - * This block has two such inputs, independant of each other. + * This block has two such inputs, independent of each other. * @param {number} n Specify first or second input (1 or 2). * @param {boolean} isAt True if the input should exist. * @private diff --git a/core/block.js b/core/block.js index 029677857..724e76777 100644 --- a/core/block.js +++ b/core/block.js @@ -939,7 +939,7 @@ Blockly.Block.prototype.setStyle = function(blockStyleName) { * initializer function. * @param {function(Blockly.Events.Abstract)} onchangeFn The callback to call * when the block's workspace changes. - * @throws {Error} if onchangeFn is not falsey or a function. + * @throws {Error} if onchangeFn is not falsey and not a function. */ Blockly.Block.prototype.setOnChange = function(onchangeFn) { if (onchangeFn && typeof onchangeFn != 'function') { diff --git a/core/block_svg.js b/core/block_svg.js index b0cff9c7e..bebf725b3 100644 --- a/core/block_svg.js +++ b/core/block_svg.js @@ -583,7 +583,7 @@ Blockly.BlockSvg.prototype.getBoundingRectangle = function() { /** * Notify every input on this block to mark its fields as dirty. - * A dirty field is a field that needs to be re-rendererd. + * A dirty field is a field that needs to be re-rendered. */ Blockly.BlockSvg.prototype.markDirty = function() { this.pathObject.constants = diff --git a/core/components/tree/basenode.js b/core/components/tree/basenode.js index a2ae42c20..1a9c8ca1c 100644 --- a/core/components/tree/basenode.js +++ b/core/components/tree/basenode.js @@ -498,7 +498,7 @@ Blockly.tree.BaseNode.prototype.setExpanded = function(expanded) { /** * Used to notify a node of that we have expanded it. - * Can be overidden by subclasses, see Blockly.tree.TreeNode. + * Can be overridden by subclasses, see Blockly.tree.TreeNode. * @protected */ Blockly.tree.BaseNode.prototype.doNodeExpanded = function() { @@ -507,7 +507,7 @@ Blockly.tree.BaseNode.prototype.doNodeExpanded = function() { /** * Used to notify a node that we have collapsed it. - * Can be overidden by subclasses, see Blockly.tree.TreeNode. + * Can be overridden by subclasses, see Blockly.tree.TreeNode. * @protected */ Blockly.tree.BaseNode.prototype.doNodeCollapsed = function() { diff --git a/core/components/tree/treenode.js b/core/components/tree/treenode.js index 30f72bfd5..612dcb4f4 100644 --- a/core/components/tree/treenode.js +++ b/core/components/tree/treenode.js @@ -167,7 +167,7 @@ Blockly.tree.TreeNode.prototype.doNodeExpanded = Blockly.tree.TreeNode.prototype.resizeToolbox_; /** - * Resize the toolbox when a node is collased. + * Resize the toolbox when a node is collapsed. * @override */ Blockly.tree.TreeNode.prototype.doNodeCollapsed = diff --git a/core/connection.js b/core/connection.js index 1a0d921d8..88d183157 100644 --- a/core/connection.js +++ b/core/connection.js @@ -158,7 +158,7 @@ Blockly.Connection.prototype.connect_ = function(childConnection) { // Bump it off to the side after a moment. var group = Blockly.Events.getGroup(); setTimeout(function() { - // Verify orphan hasn't been deleted or reconnected (user on meth). + // Verify orphan hasn't been deleted or reconnected. if (orphanBlock.workspace && !orphanBlock.getParent()) { Blockly.Events.setGroup(group); if (orphanBlock.outputConnection) { diff --git a/core/field.js b/core/field.js index fdfc8e4c0..2c6328fc8 100644 --- a/core/field.js +++ b/core/field.js @@ -935,7 +935,7 @@ Blockly.Field.prototype.doValueUpdate_ = function(newValue) { }; /** - * Used to notify the field an invalid value was input. Can be overidden by + * Used to notify the field an invalid value was input. Can be overridden by * subclasses, see FieldTextInput. * No-op by default. * @param {*} _invalidValue The input value that was determined to be invalid. diff --git a/core/grid.js b/core/grid.js index b687dbb7d..89b1a4ca8 100644 --- a/core/grid.js +++ b/core/grid.js @@ -167,7 +167,7 @@ Blockly.Grid.prototype.setLineAttributes_ = function(line, width, * Move the grid to a new x and y position, and make sure that change is * visible. * @param {number} x The new x position of the grid (in px). - * @param {number} y The new y position ofthe grid (in px). + * @param {number} y The new y position of the grid (in px). * @package */ Blockly.Grid.prototype.moveTo = function(x, y) { diff --git a/core/keyboard_nav/ast_node.js b/core/keyboard_nav/ast_node.js index e85614766..4f111b84c 100644 --- a/core/keyboard_nav/ast_node.js +++ b/core/keyboard_nav/ast_node.js @@ -20,7 +20,7 @@ goog.require('Blockly.utils.Coordinate'); * It is recommended that you use one of the createNode methods instead of * creating a node directly. * @param {string} type The type of the location. - * Must be in Bockly.ASTNode.types. + * Must be in Blockly.ASTNode.types. * @param {!(Blockly.Block|Blockly.Connection|Blockly.Field|Blockly.Workspace)} * location The position in the AST. * @param {!Object=} opt_params Optional dictionary of options. diff --git a/core/keyboard_nav/basic_cursor.js b/core/keyboard_nav/basic_cursor.js index cb5e017c7..981c8cc89 100644 --- a/core/keyboard_nav/basic_cursor.js +++ b/core/keyboard_nav/basic_cursor.js @@ -79,7 +79,7 @@ Blockly.BasicCursor.prototype.prev = function() { }; /** - * For a basic cursor we only have the ability to go next and previou, so + * For a basic cursor we only have the ability to go next and previous, so * out will allow the user to get to the previous node in the pre order traversal. * @return {Blockly.ASTNode} The previous node, or null if the current node is * not set or there is no previous value. diff --git a/core/keyboard_nav/navigation.js b/core/keyboard_nav/navigation.js index 6738af1a0..385ef676a 100644 --- a/core/keyboard_nav/navigation.js +++ b/core/keyboard_nav/navigation.js @@ -782,7 +782,7 @@ Blockly.navigation.onBlocklyAction = function(action) { } else if (Blockly.navigation.READONLY_ACTION_LIST.indexOf(action) > -1) { actionHandled = Blockly.navigation.handleActions_(action); } - // If not in accessibility mode only hanlde turning on keyboard navigation. + // If not in accessibility mode only handle turning on keyboard navigation. } else if (action.name === Blockly.navigation.actionNames.TOGGLE_KEYBOARD_NAV) { Blockly.navigation.enableKeyboardAccessibility(); actionHandled = true; @@ -1031,7 +1031,7 @@ Blockly.navigation.ACTION_TOGGLE_KEYBOARD_NAV = new Blockly.Action( 'Turns on and off keyboard navigation.'); /** - * The action to move the cursor to the keft on a worksapce. + * The action to move the cursor to the left on a workspace. * @type {!Blockly.Action} */ Blockly.navigation.ACTION_MOVE_WS_CURSOR_LEFT = new Blockly.Action( @@ -1039,7 +1039,7 @@ Blockly.navigation.ACTION_MOVE_WS_CURSOR_LEFT = new Blockly.Action( 'Move the workspace cursor to the lefts.'); /** - * The action to move the cursor to the right on a worksapce. + * The action to move the cursor to the right on a workspace. * @type {!Blockly.Action} */ Blockly.navigation.ACTION_MOVE_WS_CURSOR_RIGHT = new Blockly.Action( @@ -1047,7 +1047,7 @@ Blockly.navigation.ACTION_MOVE_WS_CURSOR_RIGHT = new Blockly.Action( 'Move the workspace cursor to the right.'); /** - * The action to move the cursor up on a worksapce. + * The action to move the cursor up on a workspace. * @type {!Blockly.Action} */ Blockly.navigation.ACTION_MOVE_WS_CURSOR_UP = new Blockly.Action( @@ -1055,7 +1055,7 @@ Blockly.navigation.ACTION_MOVE_WS_CURSOR_UP = new Blockly.Action( 'Move the workspace cursor up.'); /** - * The action to move the cursor down on a worksapce. + * The action to move the cursor down on a workspace. * @type {!Blockly.Action} */ Blockly.navigation.ACTION_MOVE_WS_CURSOR_DOWN = new Blockly.Action( diff --git a/core/mutator.js b/core/mutator.js index 00e996a84..313e3f101 100644 --- a/core/mutator.js +++ b/core/mutator.js @@ -294,7 +294,7 @@ Blockly.Mutator.prototype.setVisible = function(visible) { for (var i = 0, child; (child = blocks[i]); i++) { child.render(); } - // The root block should not be dragable or deletable. + // The root block should not be draggable or deletable. this.rootBlock_.setMovable(false); this.rootBlock_.setDeletable(false); if (flyout) { diff --git a/core/names.js b/core/names.js index 877bb8f2f..8772f1e41 100644 --- a/core/names.js +++ b/core/names.js @@ -82,7 +82,7 @@ Blockly.Names.prototype.setVariableMap = function(map) { Blockly.Names.prototype.getNameForUserVariable_ = function(id) { if (!this.variableMap_) { console.log('Deprecated call to Blockly.Names.prototype.getName without ' + - 'defining a variable map. To fix, add the folowing code in your ' + + 'defining a variable map. To fix, add the following code in your ' + 'generator\'s init() function:\n' + 'Blockly.YourGeneratorName.variableDB_.setVariableMap(' + 'workspace.getVariableMap());'); diff --git a/core/renderers/common/constants.js b/core/renderers/common/constants.js index 343bcfd31..6708c09f4 100644 --- a/core/renderers/common/constants.js +++ b/core/renderers/common/constants.js @@ -595,7 +595,7 @@ Blockly.blockRendering.ConstantProvider.prototype.setTheme = function( }; /** - * Sets dynamic properties that depent on other values or theme properties. + * Sets dynamic properties that depend on other values or theme properties. * @param {!Blockly.Theme} theme The current workspace theme. * @protected */ @@ -1211,7 +1211,7 @@ Blockly.blockRendering.ConstantProvider.prototype.getCSS_ = function(selector) { 'stroke: #fc3;', '}', - // Replacable highlight. + // Replaceable highlight. selector + ' .blocklyReplaceable .blocklyPath {', 'fill-opacity: .5;', '}', diff --git a/core/renderers/measurables/types.js b/core/renderers/measurables/types.js index 9e94ebf08..02e5b9a9a 100644 --- a/core/renderers/measurables/types.js +++ b/core/renderers/measurables/types.js @@ -79,7 +79,7 @@ Blockly.blockRendering.Types.nextTypeValue_ = 1 << 24; /** * Get the enum flag value of an existing type or register a new type. * @param {!string} type The name of the type. - * @return {!number} The enum flag value assosiated with that type. + * @return {!number} The enum flag value associated with that type. * @package */ Blockly.blockRendering.Types.getType = function(type) { diff --git a/core/renderers/zelos/constants.js b/core/renderers/zelos/constants.js index f37c37b87..cac9a0545 100644 --- a/core/renderers/zelos/constants.js +++ b/core/renderers/zelos/constants.js @@ -478,7 +478,7 @@ Blockly.zelos.ConstantProvider.prototype.makeHexagonal = function() { var maxWidth = this.MAX_DYNAMIC_CONNECTION_SHAPE_WIDTH; // The main path for the hexagonal connection shape is made out of two lines. - // The lines are defined with relative positons and require the block height. + // The lines are defined with relative positions and require the block height. // The 'up' and 'down' versions of the paths are the same, but the Y sign // flips. The 'left' and 'right' versions of the path are also the same, but // the X sign flips. @@ -650,7 +650,7 @@ Blockly.zelos.ConstantProvider.prototype.shapeFor = function( case Blockly.INPUT_VALUE: case Blockly.OUTPUT_VALUE: var outputShape = connection.getSourceBlock().getOutputShape(); - // If the block has an ouput shape set, use that instead. + // If the block has an output shape set, use that instead. if (outputShape != null) { switch (outputShape) { case this.SHAPES.HEXAGONAL: return this.HEXAGONAL; diff --git a/core/renderers/zelos/info.js b/core/renderers/zelos/info.js index 0996cf505..ac822772b 100644 --- a/core/renderers/zelos/info.js +++ b/core/renderers/zelos/info.js @@ -107,7 +107,7 @@ Blockly.zelos.RenderInfo.prototype.getRenderer = function() { * @override */ Blockly.zelos.RenderInfo.prototype.measure = function() { - // Modifing parent measure method to add `adjustXPosition_`. + // Modifying parent measure method to add `adjustXPosition_`. this.createRows_(); this.addElemSpacing_(); this.addRowSpacing_(); @@ -386,7 +386,7 @@ Blockly.zelos.RenderInfo.prototype.finalizeOutputConnection_ = function() { this.outputConnection.shape.connectionOffsetX(connectionWidth); // Add the right connection measurable. - // Don't add it if we have a value-to-statament or a value-to-stack block. + // Don't add it if we have a value-to-statement or a value-to-stack block. var rightConnectionWidth = 0; if (!this.hasStatementInput && !this.bottomRow.hasNextConnection) { rightConnectionWidth = connectionWidth; diff --git a/core/renderers/zelos/path_object.js b/core/renderers/zelos/path_object.js index 3bca20b0f..360f329af 100644 --- a/core/renderers/zelos/path_object.js +++ b/core/renderers/zelos/path_object.js @@ -57,7 +57,7 @@ Blockly.zelos.PathObject = function(root, style, constants) { /** * A set used to determine which outlines were used during a draw pass. The * set is initialized with a reference to all the outlines in - * `this.outlines_`. Everytime we use an outline during the draw pass, the + * `this.outlines_`. Every time we use an outline during the draw pass, the * reference is removed from this set. * @type {Object.} * @private diff --git a/core/theme/tritanopia.js b/core/theme/tritanopia.js index 1087af788..544e10600 100644 --- a/core/theme/tritanopia.js +++ b/core/theme/tritanopia.js @@ -6,7 +6,7 @@ /** * @fileoverview Tritanopia theme. - * A color palette for people that have tritanopia(the inability to perceive + * A color palette for people that have tritanopia (the inability to perceive * blue light). */ 'use strict'; diff --git a/core/utils.js b/core/utils.js index e03337b3a..cfd047ca1 100644 --- a/core/utils.js +++ b/core/utils.js @@ -579,7 +579,7 @@ Blockly.utils.getBlockTypeCounts = function(block, opt_stripFollowing) { * Converts screen coordinates to workspace coordinates. * @param {Blockly.WorkspaceSvg} ws The workspace to find the coordinates on. * @param {Blockly.utils.Coordinate} screenCoordinates The screen coordinates to - * be converted to workspace coordintaes + * be converted to workspace coordinates * @return {Blockly.utils.Coordinate} The workspace coordinates. * @package */ diff --git a/core/utils/svg_paths.js b/core/utils/svg_paths.js index 8ef77ca07..d2066599a 100644 --- a/core/utils/svg_paths.js +++ b/core/utils/svg_paths.js @@ -33,7 +33,7 @@ Blockly.utils.svgPaths.point = function(x, y) { }; /** - * Draw a curbic or quadratic curve. See + * Draw a cubic or quadratic curve. See * developer.mozilla.org/en-US/docs/Web/SVG/Attribute/d#Cubic_B%C3%A9zier_Curve * These coordinates are unitless and hence in the user coordinate system. * @param {string} command The command to use. diff --git a/core/workspace_svg.js b/core/workspace_svg.js index 5896fb4ad..060ec942c 100644 --- a/core/workspace_svg.js +++ b/core/workspace_svg.js @@ -2310,7 +2310,7 @@ Blockly.WorkspaceSvg.getContentDimensionsBounded_ = function(ws, svgSize) { var halfWidth = viewWidth / 2; var halfHeight = viewHeight / 2; - // Add a border around the content that is at least half a screenful wide. + // Add a border around the content that is at least half a screen wide. // Ensure border is wide enough that blocks can scroll over entire screen. var left = Math.min(content.left - halfWidth, content.right - viewWidth); var right = Math.max(content.right + halfWidth, content.left + viewWidth); diff --git a/demos/blockfactory/app_controller.js b/demos/blockfactory/app_controller.js index 49e0ec0a3..911d3ae95 100644 --- a/demos/blockfactory/app_controller.js +++ b/demos/blockfactory/app_controller.js @@ -162,7 +162,7 @@ AppController.prototype.formatBlockLibraryForImport_ = function(xmlText) { // since the addition to editorWorkspaceXml below removes it from inputXml. var inputChildren = Array.from(inputXml.children); - // Create empty map. The line below creates a truly empy object. It doesn't + // Create empty map. The line below creates a truly empty object. It doesn't // have built-in attributes/functions such as length or toString. var blockXmlTextMap = Object.create(null); diff --git a/demos/blockfactory/block_definition_extractor.js b/demos/blockfactory/block_definition_extractor.js index f684c75df..10d9d0f7b 100644 --- a/demos/blockfactory/block_definition_extractor.js +++ b/demos/blockfactory/block_definition_extractor.js @@ -556,7 +556,7 @@ BlockDefinitionExtractor.buildFieldColour_ = }; /** - * Creates a element representing a FieldVaraible definition. + * Creates a element representing a FieldVariable definition. * * @param {string} fieldName The identifying name of the field. * @param {string} varName The variables @@ -579,7 +579,7 @@ BlockDefinitionExtractor.buildFieldVariable_ = function(fieldName, varName) { * @param {string} src The URL of the field image. * @param {number} width The pixel width of the source image * @param {number} height The pixel height of the source image. - * @param {string} alt Alterante text to describe image. + * @param {string} alt Alternate text to describe image. * @private */ BlockDefinitionExtractor.buildFieldImage_ = @@ -693,7 +693,7 @@ BlockDefinitionExtractor.typeList_ = function() { * Creates a element representing the given custom connection * constraint type name. * - * @param {string} type The connection constratin type name. + * @param {string} type The connection constraint type name. * @return {Element} The element representing a custom input type * constraint. * @private diff --git a/demos/blockfactory/block_exporter_view.js b/demos/blockfactory/block_exporter_view.js index 6fae78f35..f505438a7 100644 --- a/demos/blockfactory/block_exporter_view.js +++ b/demos/blockfactory/block_exporter_view.js @@ -51,7 +51,7 @@ BlockExporterView.prototype.select = function(blockType) { /** * Deselects a block in the selector. - * @param {!Blockly.Block} block Type of block to add to selector workspce. + * @param {!Blockly.Block} block Type of block to add to selector workspace. */ BlockExporterView.prototype.deselect = function(blockType) { this.blockOptions[blockType].setSelected(false); diff --git a/demos/blockfactory/blocks.js b/demos/blockfactory/blocks.js index c29032b9b..c7253cc67 100644 --- a/demos/blockfactory/blocks.js +++ b/demos/blockfactory/blocks.js @@ -64,7 +64,7 @@ Blockly.Blocks['factory_base'] = { }, spawnOutputShadow_: function(option) { // Helper method for deciding which type of outputs this block needs - // to attach shaddow blocks to. + // to attach shadow blocks to. switch (option) { case 'LEFT': this.connectOutputShadow_('OUTPUTTYPE'); diff --git a/demos/blockfactory/factory_utils.js b/demos/blockfactory/factory_utils.js index 40ed6b998..8c1941d10 100644 --- a/demos/blockfactory/factory_utils.js +++ b/demos/blockfactory/factory_utils.js @@ -163,7 +163,7 @@ FactoryUtils.getGeneratorStub = function(block, generatorLanguage) { * Update the language code as JSON. * @param {string} blockType Name of block. * @param {!Blockly.Block} rootBlock Factory_base block. - * @return {string} Generanted language code. + * @return {string} Generated language code. * @private */ FactoryUtils.formatJson_ = function(blockType, rootBlock) { @@ -830,7 +830,7 @@ FactoryUtils.parseJsonBlockDefinitions = function(blockDefsString) { else if (currentChar == '}') { unbalancedBracketCount--; if (unbalancedBracketCount == 0 && i > 0) { - // The brackets are balanced. We've got a complete block defintion. + // The brackets are balanced. We've got a complete block definition. var blockDef = blockDefsString.substring(defStart, i + 1); blockDefArray.push(blockDef); defStart = i + 1; diff --git a/demos/blockfactory_old/blocks.js b/demos/blockfactory_old/blocks.js index 2f66b519b..050e53147 100644 --- a/demos/blockfactory_old/blocks.js +++ b/demos/blockfactory_old/blocks.js @@ -58,7 +58,7 @@ Blockly.Blocks['factory_base'] = { }, spawnOutputShadow_: function(option) { // Helper method for deciding which type of outputs this block needs - // to attach shaddow blocks to. + // to attach shadow blocks to. switch (option) { case 'LEFT': this.connectOutputShadow_('OUTPUTTYPE'); diff --git a/demos/blockfactory_old/factory.js b/demos/blockfactory_old/factory.js index 723650c79..967d2a440 100644 --- a/demos/blockfactory_old/factory.js +++ b/demos/blockfactory_old/factory.js @@ -81,7 +81,7 @@ function updateLanguage() { * Update the language code as JSON. * @param {string} blockType Name of block. * @param {!Blockly.Block} rootBlock Factory_base block. - * @return {string} Generanted language code. + * @return {string} Generated language code. * @private */ function formatJson_(blockType, rootBlock) { @@ -183,7 +183,7 @@ function formatJson_(blockType, rootBlock) { * Update the language code as JavaScript. * @param {string} blockType Name of block. * @param {!Blockly.Block} rootBlock Factory_base block. - * @return {string} Generanted language code. + * @return {string} Generated language code. * @private */ function formatJavaScript_(blockType, rootBlock) { @@ -487,7 +487,7 @@ function getFieldsJson_(block) { /** * Escape a string. * @param {string} string String to escape. - * @return {string} Escaped string surrouned by quotes. + * @return {string} Escaped string surrounded by quotes. */ function escapeString(string) { return JSON.stringify(string); diff --git a/demos/interpreter/async-execution.html b/demos/interpreter/async-execution.html index 52024275e..70f2492d2 100644 --- a/demos/interpreter/async-execution.html +++ b/demos/interpreter/async-execution.html @@ -24,7 +24,7 @@

Blockly > Demos > Asynchronous Execution with JS Interpreter

-

This is a demo of executing code asychronously (e.g., waiting for delays or user input) using the JavaScript interpreter.

+

This is a demo of executing code asynchronously (e.g., waiting for delays or user input) using the JavaScript interpreter.

More info on running code with JS Interpreter

diff --git a/demos/keyboard_nav/line_cursor.js b/demos/keyboard_nav/line_cursor.js index 85de8300e..d9cb80689 100644 --- a/demos/keyboard_nav/line_cursor.js +++ b/demos/keyboard_nav/line_cursor.js @@ -99,7 +99,7 @@ Blockly.LineCursor.prototype.prev = function() { }; /** - * For a basic cursor we only have the ability to go next and previou, so + * For a basic cursor we only have the ability to go next and previous, so * out will allow the user to get to the previous node in the pre order traversal. * @return {Blockly.ASTNode} The previous node, or null if the current node is * not set or there is no previous value. diff --git a/demos/mobile/README.md b/demos/mobile/README.md index bab09606b..168690e55 100644 --- a/demos/mobile/README.md +++ b/demos/mobile/README.md @@ -15,7 +15,7 @@ see changes in both the Android and iOS native apps. Before running the mobile HTML demo, you need to create some symbolic links in your local file system. Run the `mobile/html/ln_resources.sh` file from -the `mobile/html/` directory. This mimicks the relative locations of the +the `mobile/html/` directory. This mimics the relative locations of the Blockly files seen when loading the page in a native app's embedded WebView. After doing this, opening `mobile/html/index.html` should open normally, diff --git a/demos/plane/soy/soyutils.js b/demos/plane/soy/soyutils.js index 861c81f9f..949777cb9 100644 --- a/demos/plane/soy/soyutils.js +++ b/demos/plane/soy/soyutils.js @@ -1469,7 +1469,7 @@ soydata.VERY_UNSAFE.ordainSanitizedJs = // finally printed. /** * Takes a leap of faith that the provided content can be safely embedded in - * a Javascript string without re-esacping. + * a Javascript string without re-escaping. * * @param {*} content Content that can be safely inserted as part of a * single- or double-quoted string without terminating the string. @@ -2479,7 +2479,7 @@ soy.$$changeNewlineToBr = function(value) { /** * Inserts word breaks ('wbr' tags) into a HTML string at a given interval. The * counter is reset if a space is encountered. Word breaks aren't inserted into - * HTML tags or entities. Entites count towards the character count; HTML tags + * HTML tags or entities. Entities count towards the character count; HTML tags * do not. * * @param {*} value The HTML string to insert word breaks into. Can be other diff --git a/demos/storage/index.html b/demos/storage/index.html index 759dc2b83..41462e295 100644 --- a/demos/storage/index.html +++ b/demos/storage/index.html @@ -86,7 +86,7 @@ {media: '../../media/', toolbox: document.getElementById('toolbox')}); - // An href with #key trigers an AJAX call to retrieve saved blocks. + // An href with #key triggers an AJAX call to retrieve saved blocks. if ('BlocklyStorage' in window && window.location.hash.length > 1) { BlocklyStorage.retrieveXml(window.location.hash.substring(1)); } diff --git a/scripts/gulpfiles/license_tasks.js b/scripts/gulpfiles/license_tasks.js index 9d4fd785d..3e6b93efb 100644 --- a/scripts/gulpfiles/license_tasks.js +++ b/scripts/gulpfiles/license_tasks.js @@ -5,7 +5,7 @@ */ /** - * @fileoverview Gulp tasks to check the licenses of Blockly depenedencies. + * @fileoverview Gulp tasks to check the licenses of Blockly dependencies. */ const jsgl = require('js-green-licenses'); diff --git a/scripts/gulpfiles/package_tasks.js b/scripts/gulpfiles/package_tasks.js index 7ba3b4146..c711231af 100644 --- a/scripts/gulpfiles/package_tasks.js +++ b/scripts/gulpfiles/package_tasks.js @@ -70,7 +70,7 @@ function packageBlockly() { /** * This task wraps blocks_compressed.js into a CommonJS module for Node.js. - * This is an equivelant task to package-blockly but for Node.js. + * This is an equivalent task to package-blockly but for Node.js. * @example import 'blockly/blockly-node'; */ function packageBlocklyNode() { diff --git a/tests/blocks/test_blocks.js b/tests/blocks/test_blocks.js index c14ee2544..47b44317d 100644 --- a/tests/blocks/test_blocks.js +++ b/tests/blocks/test_blocks.js @@ -1335,7 +1335,7 @@ Blockly.Blocks['test_images_clickhandler'] = { .appendField("Image click handler") .appendField(new Blockly.FieldImage( "https://blockly-demo.appspot.com/static/tests/media/a.png", 32, 32, - "image with click handlder", this.onClick_), "IMAGE"); + "image with click handler", this.onClick_), "IMAGE"); this.setStyle('text_blocks'); }, onClick_: function() { @@ -1489,7 +1489,7 @@ Blockly.Blocks['test_validators_checkbox_not_match_null'] = { this.setCommentText('The validator for this block only works on the' + ' end-most checkbox. If the new value does not match the value of the' + ' start-most checkbox, it will return null (invalid), which means the' + - ' field value should not change. Therfore they should always match.'); + ' field value should not change. Therefore they should always match.'); }, validate: function(newValue) { @@ -1635,7 +1635,7 @@ Blockly.Blocks['test_validators_number_mult10_force'] = { .appendField("force mult of 10") .appendField(new Blockly.FieldNumber(123, null, null, null, this.validate), "INPUT"); this.setColour(230); - this.setCommentText('Theinput value will be rounded to the nearest' + + this.setCommentText('The input value will be rounded to the nearest' + ' multiple of 10. The field will display the input while the field is' + ' being edited, but the value should be the validated (rounded) value.' + ' Note: If you want to do rounding this is not the proper way, use the' +