@netless/app-slide 0.2.74 → 0.2.75-beta.0
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/main.cjs.js +2 -2
- package/dist/main.cjs.js.map +1 -1
- package/dist/main.es.js +3 -3
- package/dist/main.es.js.map +1 -1
- package/dist/main.iife.js +2 -2
- package/dist/main.iife.js.map +1 -1
- package/package.json +8 -8
- package/src/SlideController/helpers.ts +6 -3
- package/LICENSE +0 -21
package/package.json
CHANGED
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netless/app-slide",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.75-beta.0",
|
|
4
4
|
"main": "dist/main.cjs.js",
|
|
5
5
|
"module": "dist/main.es.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"types": "node scripts/build-types.mjs",
|
|
9
|
+
"build": "vite build && npm run types",
|
|
10
|
+
"build:dev": "vite build --mode development && npm run types",
|
|
11
|
+
"cleanup": "rimraf ./dist"
|
|
12
|
+
},
|
|
7
13
|
"files": [
|
|
8
14
|
"src",
|
|
9
15
|
"dist",
|
|
@@ -24,11 +30,5 @@
|
|
|
24
30
|
"jspdf": {
|
|
25
31
|
"optional": true
|
|
26
32
|
}
|
|
27
|
-
},
|
|
28
|
-
"scripts": {
|
|
29
|
-
"types": "node scripts/build-types.mjs",
|
|
30
|
-
"build": "vite build && npm run types",
|
|
31
|
-
"build:dev": "vite build --mode development && npm run types",
|
|
32
|
-
"cleanup": "rimraf ./dist"
|
|
33
33
|
}
|
|
34
|
-
}
|
|
34
|
+
}
|
|
@@ -31,8 +31,8 @@ export function syncSceneWithSlide(
|
|
|
31
31
|
if (!(page > 0) || !context.getIsWritable()) return;
|
|
32
32
|
|
|
33
33
|
const scenePath = [baseScenePath, page].join("/");
|
|
34
|
-
|
|
35
|
-
if (room.scenePathType(scenePath) !== ("page" as ScenePathType.Page)) {
|
|
34
|
+
// 只有打开ppt用户,并且场景路径不是页面(未被其它用户创建出页面),则需要同步场景
|
|
35
|
+
if (context.isAddApp && room.scenePathType(scenePath) !== ("page" as ScenePathType.Page)) {
|
|
36
36
|
room.removeScenes(baseScenePath);
|
|
37
37
|
const count = slide.slideCount;
|
|
38
38
|
const scenes: { name: string }[] = [];
|
|
@@ -47,7 +47,10 @@ export function syncSceneWithSlide(
|
|
|
47
47
|
currentScenePath = context.getView()?.focusScenePath || "";
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
if (
|
|
50
|
+
if (
|
|
51
|
+
currentScenePath !== scenePath &&
|
|
52
|
+
room.scenePathType(scenePath) === ("page" as ScenePathType.Page)
|
|
53
|
+
) {
|
|
51
54
|
context.setScenePath(scenePath);
|
|
52
55
|
}
|
|
53
56
|
}
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2020 netless
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|