From 48bf0f1e96b2f8b3de304f47a925794cd58a6690 Mon Sep 17 00:00:00 2001 From: Active <56242467+doubleactii@users.noreply.github.com> Date: Mon, 2 Dec 2024 21:23:25 -0600 Subject: [PATCH] bump: version 1.2.0 --- docs/ast/source/icon-point.mjs.json | 20 ++++++++++---------- docs/file/es/icon-point.mjs.html | 6 +++--- docs/index.json | 4 ++-- docs/source.html | 2 +- package.json | 2 +- 5 files changed, 17 insertions(+), 17 deletions(-) diff --git a/docs/ast/source/icon-point.mjs.json b/docs/ast/source/icon-point.mjs.json index 7c87484..d537b42 100644 --- a/docs/ast/source/icon-point.mjs.json +++ b/docs/ast/source/icon-point.mjs.json @@ -518,10 +518,10 @@ } }, "extra": { - "rawValue": "1.1.0", - "raw": "\"1.1.0\"" + "rawValue": "1.2.0", + "raw": "\"1.2.0\"" }, - "value": "1.1.0" + "value": "1.2.0" }, "leadingComments": [ { @@ -9627,10 +9627,10 @@ } }, "extra": { - "rawValue": "1.1.0", - "raw": "\"1.1.0\"" + "rawValue": "1.2.0", + "raw": "\"1.2.0\"" }, - "value": "1.1.0" + "value": "1.2.0" }, "leadingComments": [ { @@ -18145,7 +18145,7 @@ "leadingComments": [ { "type": "CommentBlock", - "value": "!\n * icon-point@1.1.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:11:33 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", + "value": "!\n * icon-point@1.2.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:22:56 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", "start": 0, "end": 213, "loc": { @@ -18224,7 +18224,7 @@ "comments": [ { "type": "CommentBlock", - "value": "!\n * icon-point@1.1.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:11:33 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", + "value": "!\n * icon-point@1.2.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:22:56 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", "start": 0, "end": 213, "loc": { @@ -18674,7 +18674,7 @@ "tokens": [ { "type": "CommentBlock", - "value": "!\n * icon-point@1.1.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:11:33 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", + "value": "!\n * icon-point@1.2.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:22:56 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n ", "start": 0, "end": 213, "loc": { @@ -19601,7 +19601,7 @@ "binop": null, "updateContext": null }, - "value": "1.1.0", + "value": "1.2.0", "start": 1263, "end": 1270, "loc": { diff --git a/docs/file/es/icon-point.mjs.html b/docs/file/es/icon-point.mjs.html index 83c6e44..bcab3f9 100644 --- a/docs/file/es/icon-point.mjs.html +++ b/docs/file/es/icon-point.mjs.html @@ -36,8 +36,8 @@

es/icon-point.mjs

/*!
- * icon-point@1.1.0 https://github.com/EvitcaStudio/IconPoint
- * Compiled Tue, 03 Dec 2024 03:11:33 UTC
+ * icon-point@1.2.0 https://github.com/EvitcaStudio/IconPoint
+ * Compiled Tue, 03 Dec 2024 03:22:56 UTC
  *
  * icon-point is licensed under the MIT License.
  * http://www.opensource.org/licenses/mit-license
@@ -67,7 +67,7 @@
     /**
      * The version of the module.
      */
-    static version = "1.1.0";
+    static version = "1.2.0";
     /** The logger module this module uses to log errors / logs
      * @private
      * @type {Logger}
diff --git a/docs/index.json b/docs/index.json
index b2913e1..f71d23d 100644
--- a/docs/index.json
+++ b/docs/index.json
@@ -567,7 +567,7 @@
     "__docId__": 48,
     "kind": "file",
     "name": "es/icon-point.mjs",
-    "content": "/*!\n * icon-point@1.1.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:11:33 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * The IconPoint class\n * A point that exists inside/outside a virtual rectangle. The point's position inside/outside of the rectangle is maintained when the rectangle is rotated.\n * @example Example usage of this class\n * // Create a rectangle at the position of (0,0)\n * const rectangle = { x: 0, y: 0 };\n * // Make the dimensions of the rectangle 100x50\n * const bounds = { width: 100, height: 50 };\n * // Create a point at the top left corner of the rectangle\n * const point = { x: 1, y: 1 };\n * // Create an icon point that will track the point on this rectangle when it moves/rotates\n * const tlPoint = new IconPoint(rectangle, bounds, point);\n */\nclass IconPoint {\n    /**\n     * Static offset to use when none is passed.\n     */\n    static defaultOffset = { x: 0, y: 0 };\n    /**\n     * Static anchor to use when none is passed. Default value of 0.5 signifies the anchor stars in the middle.\n     */\n    static defaultAnchor = { x: 0.5, y: 0.5 };\n    /**\n     * The version of the module.\n     */\n    static version = \"1.1.0\";\n    /** The logger module this module uses to log errors / logs\n     * @private\n     * @type {Logger}\n     */\n    static logger = new i({\n        type: 'Icon-Point-Module',\n        ansi: '#ff6600'\n    });\n    /**\n     * An object storing the position of the point that was set. This is the point on the rectangle.\n     * It can be changed at runtime.\n     *   ________\n     *  |       |\n     *  |   x   |\n     *  |       |\n     *  |_______|\n     * @private\n     * @type {Point}\n     * @prop {number} x - The raw x pixel position of this point\n     * @prop {number} y - The raw y pixel position of this point\n     */\n    iconPoint = { x: 0, y: 0 };\n    /**\n     * @private\n     * @type {Point}\n     * @prop {number} x - The raw x pixel position of this point\n     * @prop {number} y - The raw y pixel position of this point\n     */\n    originalPoint = { x: 0, y: 0 };\n    /**\n     * An object storing the position of the rectangle.\n     * @private\n     * @type {Point}\n     * @prop {number} x - The x position of the rectangle.\n     * @prop {number} y - The y position of the rectangle.\n     */\n    positionalPoint;\n    /**\n     * An object storing the point's position with rotation taken into account.\n     * @private\n     * @type {Point}\n     * @prop {number} x - The x position of the point after rotation is applied.\n     * @prop {number} y - The y position of the point after rotation is applied.\n     */\n    point = { x: 0, y: 0 };\n    /**\n     * An object storing the rectangle's size.\n     * @private\n     * @type {Bounds}\n     * @prop {number} width - The width of the rectangle.\n     * @prop {number} height - The height of the rectangle.\n     */\n    bounds = { width: 32, height: 32 };\n    /**\n     * @param {Point} pPoint - The rectangle this icon point exists inside/outside of.\n     * @prop {number} pPoint.x - The x coordinate of the rectangle.\n     * @prop {number} pPoint.y - The y coordinate of the rectangle.\n     * @param {Bounds} pBounds - The size of the rectangle.\n     * @prop {number} pBounds.width - The width of the rectangle.\n     * @prop {number} pBounds.height - The height of the rectangle.\n     * @param {PositionalPoint} pIconPoint - The point that exists inside/outside the rectangle. This is in relative positioning to the rectangle.\n     * @prop {number} pIconPoint.x - The x coordinate of the point inside/outside the rectangle.\n     * @prop {number} pIconPoint.y - The y coordinate of the point inside/outside the rectangle.\n     * @prop {boolean} [pIconPoint.isNormalized=false] - Whether or not this point is normalized in a 0-1 range.\n     *\n     * ## Normalized\n        If you want to specify the point `(50, 50)` in a rectangle that is `100x100` using normalized values you would use `0.5`\n        The calculation will be `0.5 * 100` in both axis, which resolves to `(50, 50)`. This is just an easier way to assign the values.\n     */\n    constructor(pPoint, pBounds, pIconPoint) {\n        const { width, height } = pBounds;\n        this.bounds.width = width;\n        this.bounds.height = height;\n        this.positionalPoint = pPoint;\n        this.originalPoint = { ...pIconPoint };\n        this.setPoint(pIconPoint);\n    }\n    /**\n     * Gets the new point's position inside a rectangle after taking pAngle into account.\n     * @param {number} [pAngle=0] - Rotation of the rectangle this point exists inside/outside of in radians.\n     * @param {Offset} [pOffset={ x: 0, y: 0 }] - The offset of the rectangle.\n     * @prop {number} pOffset.x - The x offset of the rectangle.\n     * @prop {number} pOffset.y - The y offset of the rectangle.\n     * @param {Anchor} [pAnchor={ x: 0.5, y: 0.5}] - The anchor origin of the rectangle.\n     * @prop {number} pAnchor.x - The x anchor of the rectangle.\n     * @prop {number} pAnchor.y - The y anchor of the rectangle.\n     * @example Example usage of this method\n     * // Create a rectangle at the position of (0,0)\n     * const rectangle = { x: 0, y: 0 };\n     * // Make the dimensions of the rectangle 100x50\n     * const bounds = { width: 100, height: 50 };\n     * // Create a point at the top left corner of the rectangle\n     * const point = { x: 1, y: 1 };\n     * // Create an icon point that will track the point on this rectangle when it moves/rotates\n     * const tlPoint = new IconPoint(rectangle, bounds, point);\n     *\n     * // Verify the point is where it should be\n     * console.log(tlPoint.getPoint()) // { x: 0, y: 0 } This shows that the point is at the position (0,0) which is the top left position of the rectangle\n     *\n     * // Changing the position of the rectangle\n     * rectangle.x += 100;\n     * // Verify the point is where it should be after the rectangle changes positions\n     * console.log(tlPoint.getPoint()) // { x: 100, y: 0 } This shows that the point has moved to the updated position of the rectangle\n     *\n     * // Applying some offsets to the rectangle\n     * const rectangleOffsets = { x: 25, y: 25 };\n     * // Verify the point is where it should be after offsets have been applied to the rectangle\n     * console.log(tlPoint.getPoint(undefined, rectangleOffsets)) // { x: 125, y: 25 } This shows that the point has moved to the updated position based on the offsets of the rectangle\n     *\n     * // Applying some rotation to the rectangle\n     * const angle = Math.PI;\n     * // Verify the point is where it should be after rotating the rectangle by `angle`\n     * console.log(tlPoint.getPoint(angle)) // {x: 200, y: 50.00000000000001} This shows that the point has moved to the updated position after the rectangle had been rotated by `angle`.\n     *\n     * @returns {object} The point inside/outside of the rectangle after rotating.\n     */\n    getPoint(pAngle = 0, pOffset = IconPoint.defaultOffset, pAnchor = IconPoint.defaultAnchor) {\n        // cx, cy - center of square coordinates \n        // x, y - coordinates of a corner point of the square\n        // angle is the angle of rotation\n        const cx = (this.positionalPoint.x + pOffset.x) + this.bounds.width * pAnchor.x;\n        const cy = (this.positionalPoint.y + pOffset.y) + this.bounds.height * pAnchor.y;\n        // We take away 1 from the position of the rectangle because we don't want to point to start inside the boundaries of the rectangle\n        // Otherwise we would have to use 0 to (rectangle.xy-1) for the points coordinates\n        const pointX = (this.positionalPoint.x + pOffset.x - 1) + this.iconPoint.x;\n        const pointY = (this.positionalPoint.y + pOffset.y - 1) + this.iconPoint.y;\n        // translate point to origin\n        const tempX = pointX - cx;\n        const tempY = pointY - cy;\n        // now apply rotation\n        const rotatedX = tempX * Math.cos(pAngle) - tempY * -Math.sin(pAngle);\n        const rotatedY = tempX * -Math.sin(pAngle) + tempY * Math.cos(pAngle);\n        // translate back\n        const x = rotatedX + cx;\n        const y = rotatedY + cy;\n        this.point.x = x;\n        this.point.y = y;\n        return this.point;\n    }\n    /**\n     * Sets the static point and defines the raw pixels value\n     * @private\n     * @param {PositionalPoint} pPoint - The point that exists inside/outside the rectangle.\n     * @prop {number} pPoint.x - The x coordinate of the point inside/outside the rectangle.\n     * @prop {number} pPoint.y - The y coordinate of the point inside/outside the rectangle.\n     * @prop {boolean} [pPoint.isNormalized] - If the point's value is normalized.\n     */\n    setPoint(pPoint) {\n        const { x, y, isNormalized } = pPoint;\n        this.iconPoint.x = isNormalized ? x * this.bounds.width : x;\n        this.iconPoint.y = isNormalized ? y * this.bounds.height : y;\n    }\n    /**\n     * Resets the point to the original point.\n     */\n    resetPoint() {\n        this.setPoint(this.originalPoint);\n    }\n    /**\n     * Updates the bounds of the rectangle this icon point exists inside/outside of.\n     * @param {Bounds} pBounds - The bounds to update the rectangle with.\n     * @prop {number} pBounds.width - The width of the new rectangle.\n     * @prop {number} pBounds.height - The height of the new rectangle.\n     */\n    updateBounds(pBounds) {\n        const { width, height } = pBounds;\n        this.bounds.width = width;\n        this.bounds.height = height;\n    }\n    /**\n     * Transforms the x point.\n     * @param {number} pTransformX - The x transform to transform the x point to.\n     */\n    transformX(pTransformX) {\n        const boundsX = Math.abs(pTransformX * this.bounds.width);\n        this.iconPoint.x = boundsX - this.originalPoint.x;\n    }\n    /**\n     * Transforms the y point.\n     * @param {number} pTransformY - The y transform to transform the y point to.\n     */\n    transformY(pTransformY) {\n        const boundsY = Math.abs(pTransformY * this.bounds.height);\n        this.iconPoint.y = boundsY - this.originalPoint.y;\n    }\n    /**\n     * Transforms the point.\n     * @param {Transform} pTransform - The transform to transform the point to.\n     */\n    transform(pTransform) {\n        this.transformX(pTransform.x);\n        this.transformY(pTransform.y);\n    }\n}\n\nexport { IconPoint };\n//# sourceMappingURL=icon-point.mjs.map\n",
+    "content": "/*!\n * icon-point@1.2.0 https://github.com/EvitcaStudio/IconPoint\n * Compiled Tue, 03 Dec 2024 03:22:56 UTC\n *\n * icon-point is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * The IconPoint class\n * A point that exists inside/outside a virtual rectangle. The point's position inside/outside of the rectangle is maintained when the rectangle is rotated.\n * @example Example usage of this class\n * // Create a rectangle at the position of (0,0)\n * const rectangle = { x: 0, y: 0 };\n * // Make the dimensions of the rectangle 100x50\n * const bounds = { width: 100, height: 50 };\n * // Create a point at the top left corner of the rectangle\n * const point = { x: 1, y: 1 };\n * // Create an icon point that will track the point on this rectangle when it moves/rotates\n * const tlPoint = new IconPoint(rectangle, bounds, point);\n */\nclass IconPoint {\n    /**\n     * Static offset to use when none is passed.\n     */\n    static defaultOffset = { x: 0, y: 0 };\n    /**\n     * Static anchor to use when none is passed. Default value of 0.5 signifies the anchor stars in the middle.\n     */\n    static defaultAnchor = { x: 0.5, y: 0.5 };\n    /**\n     * The version of the module.\n     */\n    static version = \"1.2.0\";\n    /** The logger module this module uses to log errors / logs\n     * @private\n     * @type {Logger}\n     */\n    static logger = new i({\n        type: 'Icon-Point-Module',\n        ansi: '#ff6600'\n    });\n    /**\n     * An object storing the position of the point that was set. This is the point on the rectangle.\n     * It can be changed at runtime.\n     *   ________\n     *  |       |\n     *  |   x   |\n     *  |       |\n     *  |_______|\n     * @private\n     * @type {Point}\n     * @prop {number} x - The raw x pixel position of this point\n     * @prop {number} y - The raw y pixel position of this point\n     */\n    iconPoint = { x: 0, y: 0 };\n    /**\n     * @private\n     * @type {Point}\n     * @prop {number} x - The raw x pixel position of this point\n     * @prop {number} y - The raw y pixel position of this point\n     */\n    originalPoint = { x: 0, y: 0 };\n    /**\n     * An object storing the position of the rectangle.\n     * @private\n     * @type {Point}\n     * @prop {number} x - The x position of the rectangle.\n     * @prop {number} y - The y position of the rectangle.\n     */\n    positionalPoint;\n    /**\n     * An object storing the point's position with rotation taken into account.\n     * @private\n     * @type {Point}\n     * @prop {number} x - The x position of the point after rotation is applied.\n     * @prop {number} y - The y position of the point after rotation is applied.\n     */\n    point = { x: 0, y: 0 };\n    /**\n     * An object storing the rectangle's size.\n     * @private\n     * @type {Bounds}\n     * @prop {number} width - The width of the rectangle.\n     * @prop {number} height - The height of the rectangle.\n     */\n    bounds = { width: 32, height: 32 };\n    /**\n     * @param {Point} pPoint - The rectangle this icon point exists inside/outside of.\n     * @prop {number} pPoint.x - The x coordinate of the rectangle.\n     * @prop {number} pPoint.y - The y coordinate of the rectangle.\n     * @param {Bounds} pBounds - The size of the rectangle.\n     * @prop {number} pBounds.width - The width of the rectangle.\n     * @prop {number} pBounds.height - The height of the rectangle.\n     * @param {PositionalPoint} pIconPoint - The point that exists inside/outside the rectangle. This is in relative positioning to the rectangle.\n     * @prop {number} pIconPoint.x - The x coordinate of the point inside/outside the rectangle.\n     * @prop {number} pIconPoint.y - The y coordinate of the point inside/outside the rectangle.\n     * @prop {boolean} [pIconPoint.isNormalized=false] - Whether or not this point is normalized in a 0-1 range.\n     *\n     * ## Normalized\n        If you want to specify the point `(50, 50)` in a rectangle that is `100x100` using normalized values you would use `0.5`\n        The calculation will be `0.5 * 100` in both axis, which resolves to `(50, 50)`. This is just an easier way to assign the values.\n     */\n    constructor(pPoint, pBounds, pIconPoint) {\n        const { width, height } = pBounds;\n        this.bounds.width = width;\n        this.bounds.height = height;\n        this.positionalPoint = pPoint;\n        this.originalPoint = { ...pIconPoint };\n        this.setPoint(pIconPoint);\n    }\n    /**\n     * Gets the new point's position inside a rectangle after taking pAngle into account.\n     * @param {number} [pAngle=0] - Rotation of the rectangle this point exists inside/outside of in radians.\n     * @param {Offset} [pOffset={ x: 0, y: 0 }] - The offset of the rectangle.\n     * @prop {number} pOffset.x - The x offset of the rectangle.\n     * @prop {number} pOffset.y - The y offset of the rectangle.\n     * @param {Anchor} [pAnchor={ x: 0.5, y: 0.5}] - The anchor origin of the rectangle.\n     * @prop {number} pAnchor.x - The x anchor of the rectangle.\n     * @prop {number} pAnchor.y - The y anchor of the rectangle.\n     * @example Example usage of this method\n     * // Create a rectangle at the position of (0,0)\n     * const rectangle = { x: 0, y: 0 };\n     * // Make the dimensions of the rectangle 100x50\n     * const bounds = { width: 100, height: 50 };\n     * // Create a point at the top left corner of the rectangle\n     * const point = { x: 1, y: 1 };\n     * // Create an icon point that will track the point on this rectangle when it moves/rotates\n     * const tlPoint = new IconPoint(rectangle, bounds, point);\n     *\n     * // Verify the point is where it should be\n     * console.log(tlPoint.getPoint()) // { x: 0, y: 0 } This shows that the point is at the position (0,0) which is the top left position of the rectangle\n     *\n     * // Changing the position of the rectangle\n     * rectangle.x += 100;\n     * // Verify the point is where it should be after the rectangle changes positions\n     * console.log(tlPoint.getPoint()) // { x: 100, y: 0 } This shows that the point has moved to the updated position of the rectangle\n     *\n     * // Applying some offsets to the rectangle\n     * const rectangleOffsets = { x: 25, y: 25 };\n     * // Verify the point is where it should be after offsets have been applied to the rectangle\n     * console.log(tlPoint.getPoint(undefined, rectangleOffsets)) // { x: 125, y: 25 } This shows that the point has moved to the updated position based on the offsets of the rectangle\n     *\n     * // Applying some rotation to the rectangle\n     * const angle = Math.PI;\n     * // Verify the point is where it should be after rotating the rectangle by `angle`\n     * console.log(tlPoint.getPoint(angle)) // {x: 200, y: 50.00000000000001} This shows that the point has moved to the updated position after the rectangle had been rotated by `angle`.\n     *\n     * @returns {object} The point inside/outside of the rectangle after rotating.\n     */\n    getPoint(pAngle = 0, pOffset = IconPoint.defaultOffset, pAnchor = IconPoint.defaultAnchor) {\n        // cx, cy - center of square coordinates \n        // x, y - coordinates of a corner point of the square\n        // angle is the angle of rotation\n        const cx = (this.positionalPoint.x + pOffset.x) + this.bounds.width * pAnchor.x;\n        const cy = (this.positionalPoint.y + pOffset.y) + this.bounds.height * pAnchor.y;\n        // We take away 1 from the position of the rectangle because we don't want to point to start inside the boundaries of the rectangle\n        // Otherwise we would have to use 0 to (rectangle.xy-1) for the points coordinates\n        const pointX = (this.positionalPoint.x + pOffset.x - 1) + this.iconPoint.x;\n        const pointY = (this.positionalPoint.y + pOffset.y - 1) + this.iconPoint.y;\n        // translate point to origin\n        const tempX = pointX - cx;\n        const tempY = pointY - cy;\n        // now apply rotation\n        const rotatedX = tempX * Math.cos(pAngle) - tempY * -Math.sin(pAngle);\n        const rotatedY = tempX * -Math.sin(pAngle) + tempY * Math.cos(pAngle);\n        // translate back\n        const x = rotatedX + cx;\n        const y = rotatedY + cy;\n        this.point.x = x;\n        this.point.y = y;\n        return this.point;\n    }\n    /**\n     * Sets the static point and defines the raw pixels value\n     * @private\n     * @param {PositionalPoint} pPoint - The point that exists inside/outside the rectangle.\n     * @prop {number} pPoint.x - The x coordinate of the point inside/outside the rectangle.\n     * @prop {number} pPoint.y - The y coordinate of the point inside/outside the rectangle.\n     * @prop {boolean} [pPoint.isNormalized] - If the point's value is normalized.\n     */\n    setPoint(pPoint) {\n        const { x, y, isNormalized } = pPoint;\n        this.iconPoint.x = isNormalized ? x * this.bounds.width : x;\n        this.iconPoint.y = isNormalized ? y * this.bounds.height : y;\n    }\n    /**\n     * Resets the point to the original point.\n     */\n    resetPoint() {\n        this.setPoint(this.originalPoint);\n    }\n    /**\n     * Updates the bounds of the rectangle this icon point exists inside/outside of.\n     * @param {Bounds} pBounds - The bounds to update the rectangle with.\n     * @prop {number} pBounds.width - The width of the new rectangle.\n     * @prop {number} pBounds.height - The height of the new rectangle.\n     */\n    updateBounds(pBounds) {\n        const { width, height } = pBounds;\n        this.bounds.width = width;\n        this.bounds.height = height;\n    }\n    /**\n     * Transforms the x point.\n     * @param {number} pTransformX - The x transform to transform the x point to.\n     */\n    transformX(pTransformX) {\n        const boundsX = Math.abs(pTransformX * this.bounds.width);\n        this.iconPoint.x = boundsX - this.originalPoint.x;\n    }\n    /**\n     * Transforms the y point.\n     * @param {number} pTransformY - The y transform to transform the y point to.\n     */\n    transformY(pTransformY) {\n        const boundsY = Math.abs(pTransformY * this.bounds.height);\n        this.iconPoint.y = boundsY - this.originalPoint.y;\n    }\n    /**\n     * Transforms the point.\n     * @param {Transform} pTransform - The transform to transform the point to.\n     */\n    transform(pTransform) {\n        this.transformX(pTransform.x);\n        this.transformY(pTransform.y);\n    }\n}\n\nexport { IconPoint };\n//# sourceMappingURL=icon-point.mjs.map\n",
     "static": true,
     "longname": "/Users/doubleactii/Documents/Github/IconPoint/dist/es/icon-point.mjs",
     "access": "public",
@@ -1142,7 +1142,7 @@
   },
   {
     "kind": "packageJSON",
-    "content": "{\n  \"name\": \"icon-point\",\n  \"version\": \"1.1.0\",\n  \"author\": \"https://github.com/doubleactii\",\n  \"repository\": {\n    \"type\": \"git\",\n    \"url\": \"https://github.com/EvitcaStudio/IconPoint\"\n  },\n  \"module\": \"src/icon-point.ts\",\n  \"devDependencies\": {\n    \"@rollup/plugin-babel\": \"^6.0.4\",\n    \"@rollup/plugin-terser\": \"^0.4.4\",\n    \"@types/bun\": \"latest\",\n    \"bun\": \"^1.1.38\",\n    \"esdoc\": \"^1.1.0\",\n    \"esdoc-ecmascript-proposal-plugin\": \"^1.0.0\",\n    \"esdoc-standard-plugin\": \"^1.0.0\",\n    \"rollup-plugin-cleandir\": \"^3.0.0\",\n    \"rollup-plugin-replace\": \"^2.2.0\"\n  },\n  \"peerDependencies\": {\n    \"typescript\": \"^5.6.3\"\n  },\n  \"description\": \"A class that manages a point that exists inside/outside a virtual rectangle. The point's position inside/outside of the rectangle is maintained when the rectangle is rotated.\",\n  \"keywords\": [\"point\", \"vylo\", \"vylocity\", \"evitcastudio\"],\n  \"license\": \"MIT\",\n  \"scripts\": {\n    \"build:rollup\": \"npx rollup -c\",\n    \"build:docs\": \"esdoc -c esdoc.json\",\n    \"build:dist\": \"npm run build:rollup && npm run build:docs\"\n  },\n  \"type\": \"module\",\n  \"dependencies\": {\n    \"@rollup/plugin-node-resolve\": \"^15.3.0\",\n    \"rollup\": \"^4.27.2\",\n    \"rollup-plugin-typescript2\": \"^0.36.0\"\n  }\n}",
+    "content": "{\n  \"name\": \"icon-point\",\n  \"version\": \"1.2.0\",\n  \"author\": \"https://github.com/doubleactii\",\n  \"repository\": {\n    \"type\": \"git\",\n    \"url\": \"https://github.com/EvitcaStudio/IconPoint\"\n  },\n  \"module\": \"src/icon-point.ts\",\n  \"devDependencies\": {\n    \"@rollup/plugin-babel\": \"^6.0.4\",\n    \"@rollup/plugin-terser\": \"^0.4.4\",\n    \"@types/bun\": \"latest\",\n    \"bun\": \"^1.1.38\",\n    \"esdoc\": \"^1.1.0\",\n    \"esdoc-ecmascript-proposal-plugin\": \"^1.0.0\",\n    \"esdoc-standard-plugin\": \"^1.0.0\",\n    \"rollup-plugin-cleandir\": \"^3.0.0\",\n    \"rollup-plugin-replace\": \"^2.2.0\"\n  },\n  \"peerDependencies\": {\n    \"typescript\": \"^5.6.3\"\n  },\n  \"description\": \"A class that manages a point that exists inside/outside a virtual rectangle. The point's position inside/outside of the rectangle is maintained when the rectangle is rotated.\",\n  \"keywords\": [\"point\", \"vylo\", \"vylocity\", \"evitcastudio\"],\n  \"license\": \"MIT\",\n  \"scripts\": {\n    \"build:rollup\": \"npx rollup -c\",\n    \"build:docs\": \"esdoc -c esdoc.json\",\n    \"build:dist\": \"npm run build:rollup && npm run build:docs\"\n  },\n  \"type\": \"module\",\n  \"dependencies\": {\n    \"@rollup/plugin-node-resolve\": \"^15.3.0\",\n    \"rollup\": \"^4.27.2\",\n    \"rollup-plugin-typescript2\": \"^0.36.0\"\n  }\n}",
     "longname": "/Users/doubleactii/Documents/Github/IconPoint/package.json",
     "name": "package.json",
     "static": true,
diff --git a/docs/source.html b/docs/source.html
index 1409583..ba0e4af 100644
--- a/docs/source.html
+++ b/docs/source.html
@@ -55,7 +55,7 @@
       -
       10424 byte
       230
-      2024-12-03 03:11:45 (UTC)
+      2024-12-03 03:23:09 (UTC)
     
 
 
diff --git a/package.json b/package.json
index 46aa937..91b4d91 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "icon-point",
-  "version": "1.1.0",
+  "version": "1.2.0",
   "author": "https://github.com/doubleactii",
   "repository": {
     "type": "git",