From 551f726fe6f182efb95ec56c3ebe2f6292d04f25 Mon Sep 17 00:00:00 2001 From: Martin Veillette Date: Fri, 17 Jun 2016 08:28:14 -0400 Subject: [PATCH] fix jsDoc and spelling in dot (see #49) --- js/Bounds2.js | 10 +++++----- js/Bounds3.js | 14 +++++++------- js/Matrix3.js | 2 +- js/Quaternion.js | 2 +- js/Transform3.js | 7 ++++--- js/Vector2.js | 5 +++-- js/Vector3.js | 4 +++- js/Vector4.js | 5 ++++- 8 files changed, 28 insertions(+), 21 deletions(-) diff --git a/js/Bounds2.js b/js/Bounds2.js index 1dbcc76..fcec90e 100644 --- a/js/Bounds2.js +++ b/js/Bounds2.js @@ -29,10 +29,10 @@ define( function( require ) { * @constructor * @public * - * @param {number} minX - The intial minimum X coordinate of the bounds. - * @param {number} minY - The intial minimum Y coordinate of the bounds. - * @param {number} maxX - The intial maximum X coordinate of the bounds. - * @param {number} maxY - The intial maximum Y coordinate of the bounds. + * @param {number} minX - The initial minimum X coordinate of the bounds. + * @param {number} minY - The initial minimum Y coordinate of the bounds. + * @param {number} maxX - The initial maximum X coordinate of the bounds. + * @param {number} maxY - The initial maximum Y coordinate of the bounds. */ function Bounds2( minX, minY, maxX, maxY ) { assert && assert( maxY !== undefined, 'Bounds2 requires 4 parameters' ); @@ -769,7 +769,7 @@ define( function( require ) { * @param {number} amount * @returns {Bounds2} */ - eroded: function( d ) { return this.dilated( -d ); }, + eroded: function( amount ) { return this.dilated( -amount ); }, /** * A bounding box that is contracted horizontally (on the left and right) by the specified amount. diff --git a/js/Bounds3.js b/js/Bounds3.js index 82fe869..b0d89b5 100644 --- a/js/Bounds3.js +++ b/js/Bounds3.js @@ -27,12 +27,12 @@ define( function( require ) { * @constructor * @public * - * @param {number} minX - The intial minimum X coordinate of the bounds. - * @param {number} minY - The intial minimum Y coordinate of the bounds. - * @param {number} minZ - The intial minimum Z coordinate of the bounds. - * @param {number} maxX - The intial maximum X coordinate of the bounds. - * @param {number} maxY - The intial maximum Y coordinate of the bounds. - * @param {number} maxZ - The intial maximum Z coordinate of the bounds. + * @param {number} minX - The initial minimum X coordinate of the bounds. + * @param {number} minY - The initial minimum Y coordinate of the bounds. + * @param {number} minZ - The initial minimum Z coordinate of the bounds. + * @param {number} maxX - The initial maximum X coordinate of the bounds. + * @param {number} maxY - The initial maximum Y coordinate of the bounds. + * @param {number} maxZ - The initial maximum Z coordinate of the bounds. */ function Bounds3( minX, minY, minZ, maxX, maxY, maxZ ) { assert && assert( maxY !== undefined, 'Bounds3 requires 4 parameters' ); @@ -753,7 +753,7 @@ define( function( require ) { * @param {number} amount * @returns {Bounds3} */ - eroded: function( d ) { return this.dilated( -d ); }, + eroded: function( amount ) { return this.dilated( -amount ); }, /** * A bounding box that is contracted horizontally (on the left and right) by the specified amount. diff --git a/js/Matrix3.js b/js/Matrix3.js index 596e9a3..e2b7fcd 100644 --- a/js/Matrix3.js +++ b/js/Matrix3.js @@ -49,7 +49,7 @@ define( function( require ) { Matrix3.Types = { // NOTE: if an inverted matrix of a type is not that type, change inverted()! // NOTE: if two matrices with identical types are multiplied, the result should have the same type. if not, changed timesMatrix()! - // NOTE: on adding a type, exaustively check all type usage + // NOTE: on adding a type, exhaustively check all type usage OTHER: 0, // default IDENTITY: 1, TRANSLATION_2D: 2, diff --git a/js/Quaternion.js b/js/Quaternion.js index 3c7f4c1..af87f49 100644 --- a/js/Quaternion.js +++ b/js/Quaternion.js @@ -3,7 +3,7 @@ /** * Quaternion, see http://en.wikipedia.org/wiki/Quaternion * - * TODO: convert from JME-style parameterization into classical mathematical description? + * TODO: convert from JME-style parametrization into classical mathematical description? * * @author Jonathan Olson */ diff --git a/js/Transform3.js b/js/Transform3.js index fd735a7..023489a 100644 --- a/js/Transform3.js +++ b/js/Transform3.js @@ -129,7 +129,8 @@ define( function( require ) { * Optimized prepended translation such that: this.matrix = translation( x, y ) * this.matrix. * @public * - * @param {Matrix3} matrix + * @param {number} x - x-coordinate + * @param {number} y - y-coordinate */ prependTranslation: function( x, y ) { // See scenery#119 for more details on the need. @@ -563,8 +564,8 @@ define( function( require ) { * @param {Bounds2} bounds * @returns {Bounds2} */ - inverseBounds2: function( bounds2 ) { - return bounds2.transformed( this.getInverse() ); + inverseBounds2: function( bounds ) { + return bounds.transformed( this.getInverse() ); }, /** diff --git a/js/Vector2.js b/js/Vector2.js index b9c9905..736b155 100644 --- a/js/Vector2.js +++ b/js/Vector2.js @@ -103,10 +103,11 @@ define( function( require ) { }, /** - * The squared Euclidean distance between this vector (treated as a point) and another point (x,y). + * The squared Euclidean distance between this vector (treated as a point) and another point with coordinates (x,y). * @public * - * @param {Vector2} point + * @param {number} x + * @param {number} y * @returns {number} */ distanceSquaredXY: function( x, y ) { diff --git a/js/Vector3.js b/js/Vector3.js index c14883d..888ae16 100644 --- a/js/Vector3.js +++ b/js/Vector3.js @@ -115,7 +115,9 @@ define( function( require ) { * The squared Euclidean distance between this vector (treated as a point) and another point (x,y,z). * @public * - * @param {Vector3} point + * @param {number} x + * @param {number} y + * @param {number} z * @returns {number} */ distanceSquaredXYZ: function( x, y, z ) { diff --git a/js/Vector4.js b/js/Vector4.js index 58ab6a3..da695a3 100644 --- a/js/Vector4.js +++ b/js/Vector4.js @@ -119,7 +119,10 @@ define( function( require ) { * The squared Euclidean distance between this vector (treated as a point) and another point (x,y,z,w). * @public * - * @param {Vector4} point + * @param {number} x + * @param {number} y + * @param {number} z + * @param {number} w * @returns {number} */ distanceSquaredXYZW: function( x, y, z, w ) {