@armniko/canvas
Advanced tools
| export type ImageSource = HTMLCanvasElement | HTMLImageElement; |
| export {}; |
@@ -29,2 +29,4 @@ import { ElementArtist } from './element-artist'; | ||
| this.ctx.lineJoin = 'round'; | ||
| this.ctx.fillStyle = '#ffffff'; | ||
| this.ctx.fill(); | ||
| if (width > 0) { | ||
@@ -31,0 +33,0 @@ this.ctx.strokeStyle = color; |
@@ -5,3 +5,3 @@ import { ElementType } from '../../enums/element-type'; | ||
| import { GeometricElement } from './geometric-element'; | ||
| import { ImageSource } from '../../types/image-source'; | ||
| import { ImageSource } from '../../types'; | ||
| export declare class ImageElement extends GeometricElement { | ||
@@ -8,0 +8,0 @@ private _image?; |
+6
-3
| { | ||
| "name": "@armniko/canvas", | ||
| "version": "1.1.0", | ||
| "version": "1.1.1", | ||
| "description": "Simplified and object-based drawing on HTML canvas!", | ||
| "author": "Armīns Nikolajevs <armins.nikolajevs@gmail.com>", | ||
| "license": "MIT", | ||
| "bugs": { | ||
| "email": "armins.nikolajevs@gmail.com" | ||
| }, | ||
| "keywords": [ | ||
@@ -19,6 +22,6 @@ "canvas", | ||
| "scripts": { | ||
| "build": "babel src -d dist --extensions .ts --delete-dir-on-start && tsc", | ||
| "build": "babel src -d dist --extensions .ts --delete-dir-on-start && tsc --project tsconfig.build.json", | ||
| "dev": "node test/server/main.js & babel src -d dist --extensions .ts --watch", | ||
| "lint": "eslint src --max-warnings=0", | ||
| "lint:fix": "eslint src --max-warnings=0 --fix", | ||
| "lint:fix": "npm run lint -- --fix", | ||
| "test": "jest --runInBand", | ||
@@ -25,0 +28,0 @@ "test:coverage": "JEST_COVERAGE=true npm run test -- --collect-coverage" |
+27
-0
@@ -54,1 +54,28 @@ <h1 align="center">Canvas</h1> | ||
| ``` | ||
| ## Changelog | ||
| <table> | ||
| <tr> | ||
| <td>v1.0.0</td> | ||
| <td> | ||
| - Initial version | ||
| </td> | ||
| </tr> | ||
| <tr> | ||
| <td>v1.1.0</td> | ||
| <td> | ||
| Features:<br> | ||
| - added line element<br> | ||
| - added gradient colors for usage as fill and border color for all elements<br> | ||
| </td> | ||
| </tr> | ||
| <tr> | ||
| <td>v1.1.1</td> | ||
| <td> | ||
| Bugfixes:<br> | ||
| - missing ImageSource type<br> | ||
| - no shadow for image element with border radius<br> | ||
| </td> | ||
| </tr> | ||
| </table> |
| export {}; |
| export {}; |
| export {}; |
| export {}; |
| export {}; |
| export {}; |
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
70632
0.87%81
50%89
-4.3%2036
-0.1%