svg-path-commander 2.0.8 → 2.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (97) hide show
  1. package/.eslintrc.cjs +0 -0
  2. package/.lgtm.yml +0 -0
  3. package/.prettierrc.json +0 -0
  4. package/LICENSE +0 -0
  5. package/README.md +4 -4
  6. package/cypress/e2e/svg-path-commander.spec.ts +0 -0
  7. package/cypress/fixtures/shapeObjects.js +0 -0
  8. package/cypress/fixtures/shapes.js +0 -0
  9. package/cypress/fixtures/simpleShapes.js +0 -0
  10. package/cypress/plugins/esbuild-istanbul.ts +0 -0
  11. package/cypress/plugins/tsCompile.ts +0 -0
  12. package/cypress/support/commands.ts +0 -0
  13. package/cypress/support/e2e.ts +0 -0
  14. package/cypress/test.html +0 -0
  15. package/cypress.config.ts +0 -0
  16. package/dist/svg-path-commander.cjs +0 -0
  17. package/dist/svg-path-commander.cjs.map +1 -1
  18. package/dist/svg-path-commander.d.ts +0 -0
  19. package/dist/svg-path-commander.js +0 -0
  20. package/dist/svg-path-commander.js.map +1 -1
  21. package/dist/svg-path-commander.mjs +0 -0
  22. package/dist/svg-path-commander.mjs.map +1 -1
  23. package/dts.config.ts +0 -0
  24. package/package.json +34 -29
  25. package/src/convert/pathToAbsolute.ts +0 -0
  26. package/src/convert/pathToCurve.ts +0 -0
  27. package/src/convert/pathToRelative.ts +0 -0
  28. package/src/convert/pathToString.ts +0 -0
  29. package/src/index.ts +0 -0
  30. package/src/interface.ts +0 -0
  31. package/src/math/distanceSquareRoot.ts +0 -0
  32. package/src/math/midPoint.ts +0 -0
  33. package/src/math/polygonArea.ts +0 -0
  34. package/src/math/polygonLength.ts +0 -0
  35. package/src/math/rotateVector.ts +0 -0
  36. package/src/options/options.ts +0 -0
  37. package/src/parser/error.ts +0 -0
  38. package/src/parser/finalizeSegment.ts +0 -0
  39. package/src/parser/invalidPathValue.ts +0 -0
  40. package/src/parser/isArcCommand.ts +0 -0
  41. package/src/parser/isDigit.ts +0 -0
  42. package/src/parser/isDigitStart.ts +0 -0
  43. package/src/parser/isPathCommand.ts +0 -0
  44. package/src/parser/isSpace.ts +0 -0
  45. package/src/parser/paramsCount.ts +0 -0
  46. package/src/parser/paramsParser.ts +0 -0
  47. package/src/parser/parsePathString.ts +0 -0
  48. package/src/parser/pathParser.ts +0 -0
  49. package/src/parser/scanFlag.ts +0 -0
  50. package/src/parser/scanParam.ts +0 -0
  51. package/src/parser/scanSegment.ts +0 -0
  52. package/src/parser/skipSpaces.ts +0 -0
  53. package/src/process/arcToCubic.ts +0 -0
  54. package/src/process/fixArc.ts +0 -0
  55. package/src/process/getSVGMatrix.ts +0 -0
  56. package/src/process/lineToCubic.ts +0 -0
  57. package/src/process/normalizePath.ts +0 -0
  58. package/src/process/normalizeSegment.ts +0 -0
  59. package/src/process/optimizePath.ts +0 -0
  60. package/src/process/projection2d.ts +0 -0
  61. package/src/process/quadToCubic.ts +0 -0
  62. package/src/process/reverseCurve.ts +0 -0
  63. package/src/process/reversePath.ts +0 -0
  64. package/src/process/roundPath.ts +0 -0
  65. package/src/process/segmentToCubic.ts +0 -0
  66. package/src/process/shortenSegment.ts +0 -0
  67. package/src/process/splitCubic.ts +0 -0
  68. package/src/process/splitPath.ts +0 -0
  69. package/src/process/transformPath.ts +0 -0
  70. package/src/types.ts +0 -0
  71. package/src/util/getClosestPoint.ts +0 -0
  72. package/src/util/getDrawDirection.ts +0 -0
  73. package/src/util/getPathArea.ts +0 -0
  74. package/src/util/getPathBBox.ts +0 -0
  75. package/src/util/getPointAtLength.ts +0 -0
  76. package/src/util/getPropertiesAtLength.ts +0 -0
  77. package/src/util/getPropertiesAtPoint.ts +0 -0
  78. package/src/util/getSegmentAtLength.ts +0 -0
  79. package/src/util/getSegmentOfPoint.ts +0 -0
  80. package/src/util/getTotalLength.ts +0 -0
  81. package/src/util/isAbsoluteArray.ts +0 -0
  82. package/src/util/isCurveArray.ts +0 -0
  83. package/src/util/isNormalizedArray.ts +0 -0
  84. package/src/util/isPathArray.ts +0 -0
  85. package/src/util/isPointInStroke.ts +0 -0
  86. package/src/util/isRelativeArray.ts +0 -0
  87. package/src/util/isValidPath.ts +0 -0
  88. package/src/util/pathLengthFactory.ts +0 -0
  89. package/src/util/segmentArcFactory.ts +0 -0
  90. package/src/util/segmentCubicFactory.ts +0 -0
  91. package/src/util/segmentLineFactory.ts +0 -0
  92. package/src/util/segmentQuadFactory.ts +0 -0
  93. package/src/util/shapeParams.ts +0 -0
  94. package/src/util/shapeToPath.ts +0 -0
  95. package/src/util/shapeToPathArray.ts +0 -0
  96. package/tsconfig.json +2 -1
  97. package/vite.config.ts +0 -0
package/dts.config.ts CHANGED
File without changes
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "svg-path-commander",
3
3
  "author": "thednp",
4
4
  "license": "MIT",
5
- "version": "2.0.8",
5
+ "version": "2.0.9",
6
6
  "description": "Modern TypeScript tools for SVG",
7
7
  "source": "./src/index.ts",
8
8
  "main": "./dist/svg-path-commander.js",
@@ -14,20 +14,6 @@
14
14
  "import": "./dist/svg-path-commander.mjs"
15
15
  }
16
16
  },
17
- "scripts": {
18
- "pre-test": "npm run clean-coverage",
19
- "test": "npm run pre-test && cypress run",
20
- "cypress": "npm run pre-test && npx cypress open",
21
- "clean-coverage": "rimraf coverage .nyc_output",
22
- "coverage:report": "nyc report --reporter=lcov --reporter=json --reporter=text --reporter=json-summary",
23
- "format": "prettier --write \"src/**/*.ts\"",
24
- "fix:ts": "eslint src --config .eslintrc.cjs --fix",
25
- "lint:ts": "eslint src --config .eslintrc.cjs",
26
- "build": "npm run lint:ts && npm run build-vite && npm run build-ts",
27
- "build-vite": "vite build && npm run build-docs",
28
- "build-ts": "dts-bundle-generator --config ./dts.config.ts",
29
- "build-docs": "ncp dist/svg-path-commander.js docs/svg-path-commander.js && ncp dist/svg-path-commander.js.map docs/svg-path-commander.js.map"
30
- },
31
17
  "repository": {
32
18
  "type": "git",
33
19
  "url": "git+https://github.com/thednp/svg-path-commander.git"
@@ -53,26 +39,45 @@
53
39
  "homepage": "http://thednp.github.io/svg-path-commander",
54
40
  "devDependencies": {
55
41
  "@bahmutov/cypress-esbuild-preprocessor": "^2.2.0",
56
- "@cypress/code-coverage": "^3.10.8",
57
- "@types/istanbul-lib-instrument": "^1.7.4",
58
- "@typescript-eslint/eslint-plugin": "^5.60.1",
59
- "@typescript-eslint/parser": "^5.60.1",
60
- "cypress": "^12.16.0",
61
- "dts-bundle-generator": "^8.0.1",
62
- "eslint": "^8.44.0",
63
- "eslint-plugin-jsdoc": "^46.4.3",
42
+ "@cypress/code-coverage": "^3.12.12",
43
+ "@types/istanbul-lib-instrument": "^1.7.7",
44
+ "@typescript-eslint/eslint-plugin": "^5.62.0",
45
+ "@typescript-eslint/parser": "^5.62.0",
46
+ "cypress": "^12.17.4",
47
+ "dts-bundle-generator": "^8.1.2",
48
+ "eslint": "^8.54.0",
49
+ "eslint-plugin-jsdoc": "^46.9.0",
64
50
  "eslint-plugin-prefer-arrow": "^1.2.3",
65
51
  "eslint-plugin-prettier": "^4.2.1",
66
- "istanbul-lib-coverage": "^3.2.0",
52
+ "istanbul-lib-coverage": "^3.2.2",
67
53
  "istanbul-lib-instrument": "^5.2.1",
68
54
  "ncp": "^2.0.0",
69
55
  "nyc": "^15.1.0",
70
56
  "prettier": "^2.8.8",
71
- "rimraf": "^5.0.1",
72
- "typescript": "^5.1.6",
73
- "vite": "^4.3.9"
57
+ "rimraf": "^5.0.5",
58
+ "typescript": "^5.3.2",
59
+ "vite": "^4.5.0"
74
60
  },
75
61
  "dependencies": {
76
- "@thednp/dommatrix": "^2.0.5"
62
+ "@thednp/dommatrix": "^2.0.6"
63
+ },
64
+ "packageManager": "pnpm@8.6.12",
65
+ "engines": {
66
+ "node": ">=16",
67
+ "pnpm": ">=8.6.0"
68
+ },
69
+ "scripts": {
70
+ "pre-test": "pnpm clean-coverage",
71
+ "test": "pnpm pre-test && cypress run",
72
+ "cypress": "pnpm pre-test && npx cypress open",
73
+ "clean-coverage": "rimraf coverage .nyc_output",
74
+ "coverage:report": "nyc report --reporter=lcov --reporter=json --reporter=text --reporter=json-summary",
75
+ "format": "prettier --write \"src/**/*.ts\"",
76
+ "fix:ts": "eslint src --config .eslintrc.cjs --fix",
77
+ "lint:ts": "eslint src --config .eslintrc.cjs",
78
+ "build": "pnpm lint:ts && pnpm build-vite && pnpm build-ts",
79
+ "build-vite": "vite build && pnpm build-docs",
80
+ "build-ts": "dts-bundle-generator --config ./dts.config.ts",
81
+ "build-docs": "ncp dist/svg-path-commander.js docs/svg-path-commander.js && ncp dist/svg-path-commander.js.map docs/svg-path-commander.js.map"
77
82
  }
78
- }
83
+ }
File without changes
File without changes
File without changes
File without changes
package/src/index.ts CHANGED
File without changes
package/src/interface.ts CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/src/types.ts CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/tsconfig.json CHANGED
@@ -2,7 +2,8 @@
2
2
  // https://janessagarrow.com/blog/typescript-and-esbuild/
3
3
  "compilerOptions": {
4
4
  "lib": ["DOM", "ESNext", "DOM.Iterable"],
5
- "types": ["vite", "vite/client", "cypress", "@thednp/dommatrix"],
5
+ // "types": ["vite", "vite/client", "cypress", "@thednp/dommatrix"],
6
+ "types": ["@thednp/dommatrix"],
6
7
  "rootDir": "./",
7
8
  "baseUrl": "./",
8
9
  "module": "ESNext",
package/vite.config.ts CHANGED
File without changes