@remotion/shapes 4.0.422 → 4.0.424
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.
- package/dist/components/circle.js +1 -1
- package/dist/components/ellipse.js +1 -1
- package/dist/components/heart.js +1 -1
- package/dist/components/pie.js +1 -1
- package/dist/components/polygon.js +1 -1
- package/dist/components/rect.js +1 -1
- package/dist/components/render-svg.d.ts +4 -1
- package/dist/components/render-svg.js +5 -2
- package/dist/components/star.js +1 -1
- package/dist/components/triangle.js +1 -1
- package/dist/index.js +16 -16
- package/package.json +6 -5
|
@@ -10,6 +10,6 @@ const render_svg_1 = require("./render-svg");
|
|
|
10
10
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/circle)
|
|
11
11
|
*/
|
|
12
12
|
const Circle = ({ radius, ...props }) => {
|
|
13
|
-
return
|
|
13
|
+
return jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_circle_1.makeCircle)({ radius }), ...props });
|
|
14
14
|
};
|
|
15
15
|
exports.Circle = Circle;
|
|
@@ -11,6 +11,6 @@ const render_svg_1 = require("./render-svg");
|
|
|
11
11
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/ellipse)
|
|
12
12
|
*/
|
|
13
13
|
const Ellipse = ({ rx, ry, ...props }) => {
|
|
14
|
-
return
|
|
14
|
+
return jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_ellipse_1.makeEllipse)({ rx, ry }), ...props });
|
|
15
15
|
};
|
|
16
16
|
exports.Ellipse = Ellipse;
|
package/dist/components/heart.js
CHANGED
|
@@ -10,7 +10,7 @@ const render_svg_1 = require("./render-svg");
|
|
|
10
10
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/heart)
|
|
11
11
|
*/
|
|
12
12
|
const Heart = ({ aspectRatio, height, bottomRoundnessAdjustment = 0, depthAdjustment = 0, ...props }) => {
|
|
13
|
-
return (
|
|
13
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_heart_1.makeHeart)({
|
|
14
14
|
aspectRatio,
|
|
15
15
|
height,
|
|
16
16
|
bottomRoundnessAdjustment,
|
package/dist/components/pie.js
CHANGED
|
@@ -14,6 +14,6 @@ const render_svg_1 = require("./render-svg");
|
|
|
14
14
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/pie)
|
|
15
15
|
*/
|
|
16
16
|
const Pie = ({ radius, progress, closePath, counterClockwise, rotation, ...props }) => {
|
|
17
|
-
return (
|
|
17
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_pie_1.makePie)({ radius, progress, closePath, counterClockwise, rotation }), ...props }));
|
|
18
18
|
};
|
|
19
19
|
exports.Pie = Pie;
|
|
@@ -5,7 +5,7 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
5
5
|
const make_polygon_1 = require("../utils/make-polygon");
|
|
6
6
|
const render_svg_1 = require("./render-svg");
|
|
7
7
|
const Polygon = ({ points, radius, cornerRadius, edgeRoundness, ...props }) => {
|
|
8
|
-
return (
|
|
8
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_polygon_1.makePolygon)({
|
|
9
9
|
points,
|
|
10
10
|
cornerRadius,
|
|
11
11
|
edgeRoundness,
|
package/dist/components/rect.js
CHANGED
|
@@ -13,6 +13,6 @@ const render_svg_1 = require("./render-svg");
|
|
|
13
13
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/rect)
|
|
14
14
|
*/
|
|
15
15
|
const Rect = ({ width, edgeRoundness, height, cornerRadius, ...props }) => {
|
|
16
|
-
return (
|
|
16
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_rect_1.makeRect)({ height, width, edgeRoundness, cornerRadius }), ...props }));
|
|
17
17
|
};
|
|
18
18
|
exports.Rect = Rect;
|
|
@@ -10,4 +10,7 @@ export declare const RenderSvg: ({ width, height, path, style, pathStyle, transf
|
|
|
10
10
|
readonly path: string;
|
|
11
11
|
readonly instructions: Instruction[];
|
|
12
12
|
readonly transformOrigin: string;
|
|
13
|
-
} &
|
|
13
|
+
} & Omit<React.SVGProps<SVGPathElement>, "d" | "height" | "width"> & {
|
|
14
|
+
readonly debug?: boolean | undefined;
|
|
15
|
+
readonly pathStyle?: React.CSSProperties | undefined;
|
|
16
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -52,7 +52,8 @@ const RenderSvg = ({ width, height, path, style, pathStyle, transformOrigin, deb
|
|
|
52
52
|
};
|
|
53
53
|
}, [pathStyle]);
|
|
54
54
|
const reactSupportsTransformOrigin = (0, does_react_support_canary_1.doesReactSupportTransformOriginProperty)(react_dom_1.version);
|
|
55
|
-
return (
|
|
55
|
+
return (jsx_runtime_1.jsxs("svg", { width: width, height: height, viewBox: `0 0 ${width} ${height}`, xmlns: "http://www.w3.org/2000/svg", style: actualStyle, children: [
|
|
56
|
+
jsx_runtime_1.jsx("path", { ...(reactSupportsTransformOrigin
|
|
56
57
|
? {
|
|
57
58
|
transformOrigin,
|
|
58
59
|
}
|
|
@@ -82,7 +83,9 @@ const RenderSvg = ({ width, height, path, style, pathStyle, transformOrigin, deb
|
|
|
82
83
|
const prevY = prevInstruction.y;
|
|
83
84
|
return (
|
|
84
85
|
// eslint-disable-next-line react/no-array-index-key
|
|
85
|
-
|
|
86
|
+
jsx_runtime_1.jsxs(react_1.default.Fragment, { children: [
|
|
87
|
+
jsx_runtime_1.jsx("path", { d: `M ${prevX} ${prevY} ${i.cp1x} ${i.cp1y}`, strokeWidth: 2, stroke: "rgba(0, 0, 0, 0.4)" }), jsx_runtime_1.jsx("path", { d: `M ${i.x} ${i.y} ${i.cp2x} ${i.cp2y}`, strokeWidth: 2, stroke: "rgba(0, 0, 0, 0.4)" }), jsx_runtime_1.jsx("circle", { cx: i.cp1x, cy: i.cp1y, r: 3, fill: "white", strokeWidth: 2, stroke: "black" }), jsx_runtime_1.jsx("circle", { cx: i.cp2x, cy: i.cp2y, r: 3, strokeWidth: 2, fill: "white", stroke: "black" })
|
|
88
|
+
] }, index));
|
|
86
89
|
}
|
|
87
90
|
return null;
|
|
88
91
|
})
|
package/dist/components/star.js
CHANGED
|
@@ -14,7 +14,7 @@ const render_svg_1 = require("./render-svg");
|
|
|
14
14
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/star)
|
|
15
15
|
*/
|
|
16
16
|
const Star = ({ innerRadius, outerRadius, points, cornerRadius, edgeRoundness, ...props }) => {
|
|
17
|
-
return (
|
|
17
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_star_1.makeStar)({
|
|
18
18
|
innerRadius,
|
|
19
19
|
outerRadius,
|
|
20
20
|
points,
|
|
@@ -13,6 +13,6 @@ const render_svg_1 = require("./render-svg");
|
|
|
13
13
|
* @see [Documentation](https://www.remotion.dev/docs/shapes/triangle)
|
|
14
14
|
*/
|
|
15
15
|
const Triangle = ({ length, direction, edgeRoundness, cornerRadius, ...props }) => {
|
|
16
|
-
return (
|
|
16
|
+
return (jsx_runtime_1.jsx(render_svg_1.RenderSvg, { ...(0, make_triangle_1.makeTriangle)({ length, direction, edgeRoundness, cornerRadius }), ...props }));
|
|
17
17
|
};
|
|
18
18
|
exports.Triangle = Triangle;
|
package/dist/index.js
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.makeTriangle = exports.makeStar = exports.makeRect = exports.makePolygon = exports.makePie = exports.makeHeart = exports.makeEllipse = exports.makeCircle = exports.Triangle = exports.Star = exports.Rect = exports.Polygon = exports.Pie = exports.Heart = exports.Ellipse = exports.Circle = void 0;
|
|
4
|
-
|
|
4
|
+
const circle_1 = require("./components/circle");
|
|
5
5
|
Object.defineProperty(exports, "Circle", { enumerable: true, get: function () { return circle_1.Circle; } });
|
|
6
|
-
|
|
6
|
+
const ellipse_1 = require("./components/ellipse");
|
|
7
7
|
Object.defineProperty(exports, "Ellipse", { enumerable: true, get: function () { return ellipse_1.Ellipse; } });
|
|
8
|
-
|
|
8
|
+
const heart_1 = require("./components/heart");
|
|
9
9
|
Object.defineProperty(exports, "Heart", { enumerable: true, get: function () { return heart_1.Heart; } });
|
|
10
|
-
|
|
10
|
+
const pie_1 = require("./components/pie");
|
|
11
11
|
Object.defineProperty(exports, "Pie", { enumerable: true, get: function () { return pie_1.Pie; } });
|
|
12
|
-
|
|
12
|
+
const polygon_1 = require("./components/polygon");
|
|
13
13
|
Object.defineProperty(exports, "Polygon", { enumerable: true, get: function () { return polygon_1.Polygon; } });
|
|
14
|
-
|
|
14
|
+
const rect_1 = require("./components/rect");
|
|
15
15
|
Object.defineProperty(exports, "Rect", { enumerable: true, get: function () { return rect_1.Rect; } });
|
|
16
|
-
|
|
16
|
+
const star_1 = require("./components/star");
|
|
17
17
|
Object.defineProperty(exports, "Star", { enumerable: true, get: function () { return star_1.Star; } });
|
|
18
|
-
|
|
18
|
+
const triangle_1 = require("./components/triangle");
|
|
19
19
|
Object.defineProperty(exports, "Triangle", { enumerable: true, get: function () { return triangle_1.Triangle; } });
|
|
20
|
-
|
|
20
|
+
const make_circle_1 = require("./utils/make-circle");
|
|
21
21
|
Object.defineProperty(exports, "makeCircle", { enumerable: true, get: function () { return make_circle_1.makeCircle; } });
|
|
22
|
-
|
|
22
|
+
const make_ellipse_1 = require("./utils/make-ellipse");
|
|
23
23
|
Object.defineProperty(exports, "makeEllipse", { enumerable: true, get: function () { return make_ellipse_1.makeEllipse; } });
|
|
24
|
-
|
|
24
|
+
const make_heart_1 = require("./utils/make-heart");
|
|
25
25
|
Object.defineProperty(exports, "makeHeart", { enumerable: true, get: function () { return make_heart_1.makeHeart; } });
|
|
26
|
-
|
|
26
|
+
const make_pie_1 = require("./utils/make-pie");
|
|
27
27
|
Object.defineProperty(exports, "makePie", { enumerable: true, get: function () { return make_pie_1.makePie; } });
|
|
28
|
-
|
|
28
|
+
const make_polygon_1 = require("./utils/make-polygon");
|
|
29
29
|
Object.defineProperty(exports, "makePolygon", { enumerable: true, get: function () { return make_polygon_1.makePolygon; } });
|
|
30
|
-
|
|
30
|
+
const make_rect_1 = require("./utils/make-rect");
|
|
31
31
|
Object.defineProperty(exports, "makeRect", { enumerable: true, get: function () { return make_rect_1.makeRect; } });
|
|
32
|
-
|
|
32
|
+
const make_star_1 = require("./utils/make-star");
|
|
33
33
|
Object.defineProperty(exports, "makeStar", { enumerable: true, get: function () { return make_star_1.makeStar; } });
|
|
34
|
-
|
|
34
|
+
const make_triangle_1 = require("./utils/make-triangle");
|
|
35
35
|
Object.defineProperty(exports, "makeTriangle", { enumerable: true, get: function () { return make_triangle_1.makeTriangle; } });
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"url": "https://github.com/remotion-dev/remotion/tree/main/packages/shapes"
|
|
4
4
|
},
|
|
5
5
|
"name": "@remotion/shapes",
|
|
6
|
-
"version": "4.0.
|
|
6
|
+
"version": "4.0.424",
|
|
7
7
|
"description": "Generate SVG shapes",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"sideEffects": false,
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"formatting": "prettier --experimental-cli src --check",
|
|
12
12
|
"lint": "eslint src",
|
|
13
13
|
"test": "bun test src",
|
|
14
|
-
"make": "
|
|
14
|
+
"make": "tsgo -d && bun --env-file=../.env.bundle bundle.ts"
|
|
15
15
|
},
|
|
16
16
|
"types": "dist/index.d.ts",
|
|
17
17
|
"module": "dist/esm/index.mjs",
|
|
@@ -34,8 +34,9 @@
|
|
|
34
34
|
"react": "19.2.3",
|
|
35
35
|
"react-dom": "19.2.3",
|
|
36
36
|
"@happy-dom/global-registrator": "14.5.1",
|
|
37
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
38
|
-
"eslint": "9.19.0"
|
|
37
|
+
"@remotion/eslint-config-internal": "4.0.424",
|
|
38
|
+
"eslint": "9.19.0",
|
|
39
|
+
"@typescript/native-preview": "7.0.0-dev.20260217.1"
|
|
39
40
|
},
|
|
40
41
|
"keywords": [
|
|
41
42
|
"svg",
|
|
@@ -50,7 +51,7 @@
|
|
|
50
51
|
"react-dom": ">=16.8.0"
|
|
51
52
|
},
|
|
52
53
|
"dependencies": {
|
|
53
|
-
"@remotion/paths": "4.0.
|
|
54
|
+
"@remotion/paths": "4.0.424"
|
|
54
55
|
},
|
|
55
56
|
"homepage": "https://www.remotion.dev/docs/shapes"
|
|
56
57
|
}
|