@versa_ai/vmml-editor 1.0.25 → 1.0.27
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/.turbo/turbo-build.log +9 -9
- package/dist/index.js +11 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/index.tsx +14 -3
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @versa_ai/vmml-editor@1.0.
|
|
2
|
+
> @versa_ai/vmml-editor@1.0.27 build D:\code\work\vmml-player\packages\editor
|
|
3
3
|
> tsup
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.tsx
|
|
@@ -9,7 +9,6 @@
|
|
|
9
9
|
[34mCLI[39m Target: node16
|
|
10
10
|
[34mCJS[39m Build start
|
|
11
11
|
[34mESM[39m Build start
|
|
12
|
-
[34mDTS[39m Build start
|
|
13
12
|
|
|
14
13
|
[43m[30m WARN [39m[49m [33m▲ [43;33m[[43;30mWARNING[43;33m][0m [1mUsing / for division outside of calc() is deprecated and will be removed in Dart Sass 2.0.0.
|
|
15
14
|
|
|
@@ -67,6 +66,7 @@ More info and automated migrator: https://sass-lang.com/d/slash-div[0m [1m[35
|
|
|
67
66
|
|
|
68
67
|
|
|
69
68
|
|
|
69
|
+
[34mDTS[39m Build start
|
|
70
70
|
|
|
71
71
|
[43m[30m WARN [39m[49m [33m▲ [43;33m[[43;30mWARNING[43;33m][0m [1mUsing / for division outside of calc() is deprecated and will be removed in Dart Sass 2.0.0.
|
|
72
72
|
|
|
@@ -124,12 +124,12 @@ More info and automated migrator: https://sass-lang.com/d/slash-div[0m [1m[35
|
|
|
124
124
|
|
|
125
125
|
|
|
126
126
|
|
|
127
|
-
[32mESM[39m [1mdist\index.mjs [22m[32m113.
|
|
128
|
-
[32mESM[39m [1mdist\index.mjs.map [22m[32m218.
|
|
129
|
-
[32mESM[39m ⚡️ Build success in
|
|
130
|
-
[32mCJS[39m [1mdist\index.js [22m[32m115.
|
|
131
|
-
[32mCJS[39m [1mdist\index.js.map [22m[
|
|
132
|
-
[32mCJS[39m ⚡️ Build success in
|
|
133
|
-
[32mDTS[39m ⚡️ Build success in
|
|
127
|
+
[32mESM[39m [1mdist\index.mjs [22m[32m113.88 KB[39m
|
|
128
|
+
[32mESM[39m [1mdist\index.mjs.map [22m[32m218.86 KB[39m
|
|
129
|
+
[32mESM[39m ⚡️ Build success in 700ms
|
|
130
|
+
[32mCJS[39m [1mdist\index.js [22m[32m115.52 KB[39m
|
|
131
|
+
[32mCJS[39m [1mdist\index.js.map [22m[32m219.15 KB[39m
|
|
132
|
+
[32mCJS[39m ⚡️ Build success in 700ms
|
|
133
|
+
[32mDTS[39m ⚡️ Build success in 1636ms
|
|
134
134
|
[32mDTS[39m [1mdist\index.d.ts [22m[32m158.00 B[39m
|
|
135
135
|
[32mDTS[39m [1mdist\index.d.mts [22m[32m158.00 B[39m
|
package/dist/index.js
CHANGED
|
@@ -2762,26 +2762,34 @@ var EditorFn = ({
|
|
|
2762
2762
|
setPreviewState(false);
|
|
2763
2763
|
}
|
|
2764
2764
|
}, [dragState]);
|
|
2765
|
-
const updateVmml = (v) => {
|
|
2765
|
+
const updateVmml = (v, checkFrame) => {
|
|
2766
2766
|
var _a2, _b, _c;
|
|
2767
2767
|
const { current: playerCurrent } = vmmlPlayerRef;
|
|
2768
2768
|
const { current: canvasCurrent } = canvasRef;
|
|
2769
2769
|
if (!playerCurrent) return;
|
|
2770
2770
|
(_b = (_a2 = canvasCurrent == null ? void 0 : canvasCurrent.getCanvasCtx()) == null ? void 0 : _a2.clear) == null ? void 0 : _b.call(_a2);
|
|
2771
|
+
needPlay.current = false;
|
|
2772
|
+
const currentFrame = checkFrame ?? pauseFrame;
|
|
2771
2773
|
const convertedVmml = vmmlUtils.convertVmmlTextScaleByForbidden(v);
|
|
2772
2774
|
setVmmlState(convertedVmml);
|
|
2773
2775
|
setDurationInFrames(vmmlUtils.getFrames(((_c = v == null ? void 0 : v.template) == null ? void 0 : _c.duration) || 1, fps));
|
|
2774
|
-
playerCurrent.setVmml(convertedVmml,
|
|
2776
|
+
playerCurrent.setVmml(convertedVmml, currentFrame);
|
|
2775
2777
|
setRefreshEdit(Date.now());
|
|
2776
2778
|
if (canvasCurrent) {
|
|
2777
|
-
canvasCurrent.checkObjectInPoint(
|
|
2779
|
+
canvasCurrent.checkObjectInPoint(currentFrame);
|
|
2778
2780
|
}
|
|
2779
2781
|
};
|
|
2782
|
+
const getCurrentFrame = () => {
|
|
2783
|
+
console.log(player, "getCurrentFrame>>>>>>>>>>>>");
|
|
2784
|
+
if (!player) return 0;
|
|
2785
|
+
return player.getPlayer().getCurrentFrame();
|
|
2786
|
+
};
|
|
2780
2787
|
react.useImperativeHandle(
|
|
2781
2788
|
ref,
|
|
2782
2789
|
() => ({
|
|
2783
2790
|
getActions,
|
|
2784
2791
|
getfcObject,
|
|
2792
|
+
getCurrentFrame,
|
|
2785
2793
|
getVmml,
|
|
2786
2794
|
getPlayer,
|
|
2787
2795
|
texteditClose,
|