@nasser-sw/fabric 7.0.1-beta3 → 7.0.1-beta4

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 (105) hide show
  1. package/0 +0 -0
  2. package/dist/index.js +323 -155
  3. package/dist/index.js.map +1 -1
  4. package/dist/index.min.js +1 -1
  5. package/dist/index.min.js.map +1 -1
  6. package/dist/index.min.mjs +1 -1
  7. package/dist/index.min.mjs.map +1 -1
  8. package/dist/index.mjs +323 -155
  9. package/dist/index.mjs.map +1 -1
  10. package/dist/index.node.cjs +323 -155
  11. package/dist/index.node.cjs.map +1 -1
  12. package/dist/index.node.mjs +323 -155
  13. package/dist/index.node.mjs.map +1 -1
  14. package/dist/package.json.min.mjs +1 -1
  15. package/dist/package.json.mjs +1 -1
  16. package/dist/src/shapes/Line.d.ts +31 -86
  17. package/dist/src/shapes/Line.d.ts.map +1 -1
  18. package/dist/src/shapes/Line.min.mjs +1 -1
  19. package/dist/src/shapes/Line.min.mjs.map +1 -1
  20. package/dist/src/shapes/Line.mjs +323 -154
  21. package/dist/src/shapes/Line.mjs.map +1 -1
  22. package/dist-extensions/src/shapes/CustomLine.d.ts +10 -0
  23. package/dist-extensions/src/shapes/CustomLine.d.ts.map +1 -0
  24. package/dist-extensions/src/shapes/Line.d.ts +31 -86
  25. package/dist-extensions/src/shapes/Line.d.ts.map +1 -1
  26. package/fabric-test-editor.html +157 -8
  27. package/fabric-test2.html +513 -0
  28. package/fabric.ts +182 -182
  29. package/package.json +1 -1
  30. package/src/shapes/Line.ts +372 -158
  31. package/debug/konva/CHANGELOG.md +0 -1474
  32. package/debug/konva/LICENSE +0 -22
  33. package/debug/konva/README.md +0 -205
  34. package/debug/konva/gulpfile.mjs +0 -110
  35. package/debug/konva/package.json +0 -139
  36. package/debug/konva/release.sh +0 -65
  37. package/debug/konva/resources/doc-includes/ContainerParams.txt +0 -6
  38. package/debug/konva/resources/doc-includes/NodeParams.txt +0 -20
  39. package/debug/konva/resources/doc-includes/ShapeParams.txt +0 -53
  40. package/debug/konva/resources/jsdoc.conf.json +0 -28
  41. package/debug/konva/rollup.config.mjs +0 -32
  42. package/debug/konva/src/Animation.ts +0 -237
  43. package/debug/konva/src/BezierFunctions.ts +0 -826
  44. package/debug/konva/src/Canvas.ts +0 -193
  45. package/debug/konva/src/Container.ts +0 -649
  46. package/debug/konva/src/Context.ts +0 -1017
  47. package/debug/konva/src/Core.ts +0 -5
  48. package/debug/konva/src/DragAndDrop.ts +0 -173
  49. package/debug/konva/src/Factory.ts +0 -246
  50. package/debug/konva/src/FastLayer.ts +0 -29
  51. package/debug/konva/src/Global.ts +0 -210
  52. package/debug/konva/src/Group.ts +0 -31
  53. package/debug/konva/src/Layer.ts +0 -546
  54. package/debug/konva/src/Node.ts +0 -3477
  55. package/debug/konva/src/PointerEvents.ts +0 -67
  56. package/debug/konva/src/Shape.ts +0 -2081
  57. package/debug/konva/src/Stage.ts +0 -1000
  58. package/debug/konva/src/Tween.ts +0 -811
  59. package/debug/konva/src/Util.ts +0 -1123
  60. package/debug/konva/src/Validators.ts +0 -210
  61. package/debug/konva/src/_CoreInternals.ts +0 -85
  62. package/debug/konva/src/_FullInternals.ts +0 -171
  63. package/debug/konva/src/canvas-backend.ts +0 -36
  64. package/debug/konva/src/filters/Blur.ts +0 -388
  65. package/debug/konva/src/filters/Brighten.ts +0 -48
  66. package/debug/konva/src/filters/Brightness.ts +0 -30
  67. package/debug/konva/src/filters/Contrast.ts +0 -75
  68. package/debug/konva/src/filters/Emboss.ts +0 -207
  69. package/debug/konva/src/filters/Enhance.ts +0 -154
  70. package/debug/konva/src/filters/Grayscale.ts +0 -25
  71. package/debug/konva/src/filters/HSL.ts +0 -108
  72. package/debug/konva/src/filters/HSV.ts +0 -106
  73. package/debug/konva/src/filters/Invert.ts +0 -23
  74. package/debug/konva/src/filters/Kaleidoscope.ts +0 -274
  75. package/debug/konva/src/filters/Mask.ts +0 -220
  76. package/debug/konva/src/filters/Noise.ts +0 -44
  77. package/debug/konva/src/filters/Pixelate.ts +0 -107
  78. package/debug/konva/src/filters/Posterize.ts +0 -46
  79. package/debug/konva/src/filters/RGB.ts +0 -82
  80. package/debug/konva/src/filters/RGBA.ts +0 -103
  81. package/debug/konva/src/filters/Sepia.ts +0 -27
  82. package/debug/konva/src/filters/Solarize.ts +0 -29
  83. package/debug/konva/src/filters/Threshold.ts +0 -44
  84. package/debug/konva/src/index.ts +0 -3
  85. package/debug/konva/src/shapes/Arc.ts +0 -176
  86. package/debug/konva/src/shapes/Arrow.ts +0 -231
  87. package/debug/konva/src/shapes/Circle.ts +0 -76
  88. package/debug/konva/src/shapes/Ellipse.ts +0 -121
  89. package/debug/konva/src/shapes/Image.ts +0 -319
  90. package/debug/konva/src/shapes/Label.ts +0 -386
  91. package/debug/konva/src/shapes/Line.ts +0 -364
  92. package/debug/konva/src/shapes/Path.ts +0 -1013
  93. package/debug/konva/src/shapes/Rect.ts +0 -79
  94. package/debug/konva/src/shapes/RegularPolygon.ts +0 -167
  95. package/debug/konva/src/shapes/Ring.ts +0 -94
  96. package/debug/konva/src/shapes/Sprite.ts +0 -370
  97. package/debug/konva/src/shapes/Star.ts +0 -125
  98. package/debug/konva/src/shapes/Text.ts +0 -1065
  99. package/debug/konva/src/shapes/TextPath.ts +0 -583
  100. package/debug/konva/src/shapes/Transformer.ts +0 -1889
  101. package/debug/konva/src/shapes/Wedge.ts +0 -129
  102. package/debug/konva/src/skia-backend.ts +0 -35
  103. package/debug/konva/src/types.ts +0 -84
  104. package/debug/konva/tsconfig.json +0 -31
  105. package/debug/konva/tsconfig.test.json +0 -7
package/fabric.ts CHANGED
@@ -1,182 +1,182 @@
1
- export { getEnv, getFabricDocument, getFabricWindow, setEnv } from './src/env';
2
- export { cache } from './src/cache';
3
- export { VERSION as version, iMatrix } from './src/constants';
4
- export { config } from './src/config';
5
- export { classRegistry } from './src/ClassRegistry';
6
- export { runningAnimations } from './src/util/animation/AnimationRegistry';
7
-
8
- export type * from './src/typedefs';
9
-
10
- export type * from './src/EventTypeDefs';
11
- export type { ITextEvents } from './src/shapes/IText/ITextBehavior';
12
-
13
- export { Observable } from './src/Observable';
14
-
15
- export type {
16
- TCanvasSizeOptions,
17
- TSVGExportOptions,
18
- } from './src/canvas/StaticCanvas';
19
- export type { StaticCanvasOptions } from './src/canvas/StaticCanvasOptions';
20
- export { StaticCanvas } from './src/canvas/StaticCanvas';
21
- export { Canvas } from './src/canvas/Canvas';
22
- export type { CanvasOptions } from './src/canvas/CanvasOptions';
23
- export { CanvasDOMManager } from './src/canvas/DOMManagers/CanvasDOMManager';
24
- export { StaticCanvasDOMManager } from './src/canvas/DOMManagers/StaticCanvasDOMManager';
25
-
26
- export type { XY } from './src/Point';
27
- export { Point } from './src/Point';
28
- export type { IntersectionType } from './src/Intersection';
29
- export { Intersection } from './src/Intersection';
30
- export { Color } from './src/color/Color';
31
- export type * from './src/color/typedefs';
32
-
33
- export * from './src/gradient';
34
- export * from './src/Pattern';
35
- export { Shadow } from './src/Shadow';
36
- export type { SerializedShadowOptions } from './src/Shadow';
37
-
38
- export { BaseBrush } from './src/brushes/BaseBrush';
39
- export type * from './src/brushes/typedefs';
40
-
41
- export { PencilBrush } from './src/brushes/PencilBrush';
42
- export { CircleBrush } from './src/brushes/CircleBrush';
43
- export { SprayBrush } from './src/brushes/SprayBrush';
44
- export { PatternBrush } from './src/brushes/PatternBrush';
45
-
46
- // many path types
47
- export type * from './src/util/path/typedefs';
48
-
49
- export {
50
- FabricObject,
51
-
52
- /**
53
- * @deprecated Due to a naming conflict with the
54
- * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object JS API},
55
- * `fabric.Object` has been renamed to `FabricObject`
56
- *
57
- * @example
58
- * import { Object } from 'fabric'; // deprecated
59
- * import { FabricObject } from 'fabric'; // migration path
60
- *
61
- */
62
- FabricObject as Object,
63
- } from './src/shapes/Object/FabricObject';
64
- /**
65
- * Exported so we can tweak default values
66
- */
67
- export {
68
- FabricObject as BaseFabricObject,
69
- type DrawContext,
70
- } from './src/shapes/Object/Object';
71
- /**
72
- * Exported so we can tweak default values
73
- */
74
- export { InteractiveFabricObject } from './src/shapes/Object/InteractiveObject';
75
-
76
- export type {
77
- TFabricObjectProps,
78
- FabricObjectProps,
79
- SerializedObjectProps,
80
- } from './src/shapes/Object/types';
81
- export type { SerializedLineProps } from './src/shapes/Line';
82
- export { Line } from './src/shapes/Line';
83
- export type { CircleProps, SerializedCircleProps } from './src/shapes/Circle';
84
- export { Circle } from './src/shapes/Circle';
85
- export { Triangle } from './src/shapes/Triangle';
86
- export type {
87
- EllipseProps,
88
- SerializedEllipseProps,
89
- } from './src/shapes/Ellipse';
90
- export { Ellipse } from './src/shapes/Ellipse';
91
- export type { RectProps, SerializedRectProps } from './src/shapes/Rect';
92
- export { Rect } from './src/shapes/Rect';
93
- export type { PathProps, SerializedPathProps } from './src/shapes/Path';
94
- export { Path } from './src/shapes/Path';
95
- export type { SerializedPolylineProps } from './src/shapes/Polyline';
96
- export { Polyline } from './src/shapes/Polyline';
97
- export { Polygon } from './src/shapes/Polygon';
98
- export type {
99
- GraphemeBBox,
100
- SerializedTextProps,
101
- TPathAlign,
102
- TPathSide,
103
- TextProps,
104
- } from './src/shapes/Text/Text';
105
- export {
106
- FabricText,
107
- /**
108
- * @deprecated Due to a naming conflict with the
109
- * {@link https://developer.mozilla.org/en-US/docs/Web/API/Text/Text Web API},
110
- * `fabric.Text` has been renamed to `FabricText`
111
- *
112
- * @example
113
- * import { Text } from 'fabric'; // deprecated
114
- * import { FabricText } from 'fabric'; // migration path
115
- *
116
- */
117
- FabricText as Text,
118
- } from './src/shapes/Text/Text';
119
- export type {
120
- ITextProps,
121
- SerializedITextProps,
122
- CursorRenderingData,
123
- CursorBoundaries,
124
- } from './src/shapes/IText/IText';
125
- export { IText } from './src/shapes/IText/IText';
126
- export type {
127
- GraphemeData,
128
- SerializedTextboxProps,
129
- TextboxProps,
130
- } from './src/shapes/Textbox';
131
- export { Textbox } from './src/shapes/Textbox';
132
- export type {
133
- CompleteTextStyleDeclaration,
134
- TextStyleDeclaration,
135
- TextStyle,
136
- } from './src/shapes/Text/StyledText';
137
- export type {
138
- GroupEvents,
139
- GroupProps,
140
- GroupOwnProps,
141
- SerializedGroupProps,
142
- } from './src/shapes/Group';
143
- export { Group } from './src/shapes/Group';
144
- export * from './src/LayoutManager';
145
- export type { SerializedLayoutManager } from './src/LayoutManager';
146
- export type {
147
- ActiveSelectionOptions,
148
- MultiSelectionStacking,
149
- } from './src/shapes/ActiveSelection';
150
- export { ActiveSelection } from './src/shapes/ActiveSelection';
151
- export {
152
- FabricImage,
153
-
154
- /**
155
- * @deprecated Due to a naming conflict with the
156
- * {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/Image Web API},
157
- * `fabric.Image` has been renamed to `FabricImage`
158
- *
159
- * @example
160
- * import { Image } from 'fabric'; // deprecated
161
- * import { FabricImage } from 'fabric'; // migration path
162
- *
163
- */
164
- FabricImage as Image,
165
- } from './src/shapes/Image';
166
- export type {
167
- ImageSource,
168
- SerializedImageProps,
169
- ImageProps,
170
- } from './src/shapes/Image';
171
- export { createCollectionMixin } from './src/Collection';
172
-
173
- export * as util from './src/util';
174
-
175
- export { loadSVGFromString } from './src/parser/loadSVGFromString';
176
- export { loadSVGFromURL } from './src/parser/loadSVGFromURL';
177
- export { parseSVGDocument } from './src/parser/parseSVGDocument';
178
-
179
- export { Control } from './src/controls/Control';
180
- export * as controlsUtils from './src/controls';
181
-
182
- export * from './src/filters';
1
+ export { getEnv, getFabricDocument, getFabricWindow, setEnv } from './src/env';
2
+ export { cache } from './src/cache';
3
+ export { VERSION as version, iMatrix } from './src/constants';
4
+ export { config } from './src/config';
5
+ export { classRegistry } from './src/ClassRegistry';
6
+ export { runningAnimations } from './src/util/animation/AnimationRegistry';
7
+
8
+ export type * from './src/typedefs';
9
+
10
+ export type * from './src/EventTypeDefs';
11
+ export type { ITextEvents } from './src/shapes/IText/ITextBehavior';
12
+
13
+ export { Observable } from './src/Observable';
14
+
15
+ export type {
16
+ TCanvasSizeOptions,
17
+ TSVGExportOptions,
18
+ } from './src/canvas/StaticCanvas';
19
+ export type { StaticCanvasOptions } from './src/canvas/StaticCanvasOptions';
20
+ export { StaticCanvas } from './src/canvas/StaticCanvas';
21
+ export { Canvas } from './src/canvas/Canvas';
22
+ export type { CanvasOptions } from './src/canvas/CanvasOptions';
23
+ export { CanvasDOMManager } from './src/canvas/DOMManagers/CanvasDOMManager';
24
+ export { StaticCanvasDOMManager } from './src/canvas/DOMManagers/StaticCanvasDOMManager';
25
+
26
+ export type { XY } from './src/Point';
27
+ export { Point } from './src/Point';
28
+ export type { IntersectionType } from './src/Intersection';
29
+ export { Intersection } from './src/Intersection';
30
+ export { Color } from './src/color/Color';
31
+ export type * from './src/color/typedefs';
32
+
33
+ export * from './src/gradient';
34
+ export * from './src/Pattern';
35
+ export { Shadow } from './src/Shadow';
36
+ export type { SerializedShadowOptions } from './src/Shadow';
37
+
38
+ export { BaseBrush } from './src/brushes/BaseBrush';
39
+ export type * from './src/brushes/typedefs';
40
+
41
+ export { PencilBrush } from './src/brushes/PencilBrush';
42
+ export { CircleBrush } from './src/brushes/CircleBrush';
43
+ export { SprayBrush } from './src/brushes/SprayBrush';
44
+ export { PatternBrush } from './src/brushes/PatternBrush';
45
+
46
+ // many path types
47
+ export type * from './src/util/path/typedefs';
48
+
49
+ export {
50
+ FabricObject,
51
+
52
+ /**
53
+ * @deprecated Due to a naming conflict with the
54
+ * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object JS API},
55
+ * `fabric.Object` has been renamed to `FabricObject`
56
+ *
57
+ * @example
58
+ * import { Object } from 'fabric'; // deprecated
59
+ * import { FabricObject } from 'fabric'; // migration path
60
+ *
61
+ */
62
+ FabricObject as Object,
63
+ } from './src/shapes/Object/FabricObject';
64
+ /**
65
+ * Exported so we can tweak default values
66
+ */
67
+ export {
68
+ FabricObject as BaseFabricObject,
69
+ type DrawContext,
70
+ } from './src/shapes/Object/Object';
71
+ /**
72
+ * Exported so we can tweak default values
73
+ */
74
+ export { InteractiveFabricObject } from './src/shapes/Object/InteractiveObject';
75
+
76
+ export type {
77
+ TFabricObjectProps,
78
+ FabricObjectProps,
79
+ SerializedObjectProps,
80
+ } from './src/shapes/Object/types';
81
+ export type { SerializedLineProps } from './src/shapes/Line';
82
+ export { Line } from './src/shapes/Line';
83
+ export type { CircleProps, SerializedCircleProps } from './src/shapes/Circle';
84
+ export { Circle } from './src/shapes/Circle';
85
+ export { Triangle } from './src/shapes/Triangle';
86
+ export type {
87
+ EllipseProps,
88
+ SerializedEllipseProps,
89
+ } from './src/shapes/Ellipse';
90
+ export { Ellipse } from './src/shapes/Ellipse';
91
+ export type { RectProps, SerializedRectProps } from './src/shapes/Rect';
92
+ export { Rect } from './src/shapes/Rect';
93
+ export type { PathProps, SerializedPathProps } from './src/shapes/Path';
94
+ export { Path } from './src/shapes/Path';
95
+ export type { SerializedPolylineProps } from './src/shapes/Polyline';
96
+ export { Polyline } from './src/shapes/Polyline';
97
+ export { Polygon } from './src/shapes/Polygon';
98
+ export type {
99
+ GraphemeBBox,
100
+ SerializedTextProps,
101
+ TPathAlign,
102
+ TPathSide,
103
+ TextProps,
104
+ } from './src/shapes/Text/Text';
105
+ export {
106
+ FabricText,
107
+ /**
108
+ * @deprecated Due to a naming conflict with the
109
+ * {@link https://developer.mozilla.org/en-US/docs/Web/API/Text/Text Web API},
110
+ * `fabric.Text` has been renamed to `FabricText`
111
+ *
112
+ * @example
113
+ * import { Text } from 'fabric'; // deprecated
114
+ * import { FabricText } from 'fabric'; // migration path
115
+ *
116
+ */
117
+ FabricText as Text,
118
+ } from './src/shapes/Text/Text';
119
+ export type {
120
+ ITextProps,
121
+ SerializedITextProps,
122
+ CursorRenderingData,
123
+ CursorBoundaries,
124
+ } from './src/shapes/IText/IText';
125
+ export { IText } from './src/shapes/IText/IText';
126
+ export type {
127
+ GraphemeData,
128
+ SerializedTextboxProps,
129
+ TextboxProps,
130
+ } from './src/shapes/Textbox';
131
+ export { Textbox } from './src/shapes/Textbox';
132
+ export type {
133
+ CompleteTextStyleDeclaration,
134
+ TextStyleDeclaration,
135
+ TextStyle,
136
+ } from './src/shapes/Text/StyledText';
137
+ export type {
138
+ GroupEvents,
139
+ GroupProps,
140
+ GroupOwnProps,
141
+ SerializedGroupProps,
142
+ } from './src/shapes/Group';
143
+ export { Group } from './src/shapes/Group';
144
+ export * from './src/LayoutManager';
145
+ export type { SerializedLayoutManager } from './src/LayoutManager';
146
+ export type {
147
+ ActiveSelectionOptions,
148
+ MultiSelectionStacking,
149
+ } from './src/shapes/ActiveSelection';
150
+ export { ActiveSelection } from './src/shapes/ActiveSelection';
151
+ export {
152
+ FabricImage,
153
+
154
+ /**
155
+ * @deprecated Due to a naming conflict with the
156
+ * {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/Image Web API},
157
+ * `fabric.Image` has been renamed to `FabricImage`
158
+ *
159
+ * @example
160
+ * import { Image } from 'fabric'; // deprecated
161
+ * import { FabricImage } from 'fabric'; // migration path
162
+ *
163
+ */
164
+ FabricImage as Image,
165
+ } from './src/shapes/Image';
166
+ export type {
167
+ ImageSource,
168
+ SerializedImageProps,
169
+ ImageProps,
170
+ } from './src/shapes/Image';
171
+ export { createCollectionMixin } from './src/Collection';
172
+
173
+ export * as util from './src/util';
174
+
175
+ export { loadSVGFromString } from './src/parser/loadSVGFromString';
176
+ export { loadSVGFromURL } from './src/parser/loadSVGFromURL';
177
+ export { parseSVGDocument } from './src/parser/parseSVGDocument';
178
+
179
+ export { Control } from './src/controls/Control';
180
+ export * as controlsUtils from './src/controls';
181
+
182
+ export * from './src/filters';
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@nasser-sw/fabric",
3
3
  "description": "Object model for HTML5 canvas, and SVG-to-canvas parser. Backed by jsdom and node-canvas.",
4
4
  "homepage": "http://fabricjs.com/",
5
- "version": "7.0.1-beta3",
5
+ "version": "7.0.1-beta4",
6
6
  "author": "Juriy Zaytsev <kangax@gmail.com>",
7
7
  "contributors": [
8
8
  {