create-jsview 2.2.128 → 2.2.373
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/package.json +2 -2
- package/template-vue-vite/package-lock-json +6 -6
- package/template-vue-vite/package.json +2 -2
- package/template-vue-vite/src/appConfig/app.config.mjs +2 -2
- package/template-vue-vite/src/appConfig/jsview.config.mjs +2 -2
- package/template-vue-vite/src/featureEnables.tsx +29 -0
- package/template-vue-vite/src/main.tsx +7 -1
- package/template-vue-vite/src/permissionResult.tsx +7 -2
- package/template-vue-vite/.DS_Store +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-jsview",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.373",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"bin": {
|
|
6
6
|
"create-jsview": "index.mjs",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"prompts": "^2.4.2"
|
|
30
30
|
},
|
|
31
31
|
"template": {
|
|
32
|
-
"vue": "2.2.
|
|
32
|
+
"vue": "2.2.373",
|
|
33
33
|
"react": "2.0.1196-next-vue.0"
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
"version": "0.0.0",
|
|
10
10
|
"hasInstallScript": true,
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@shijiu/jsview": "2.2.
|
|
13
|
-
"@shijiu/jsview-vue": "2.2.
|
|
12
|
+
"@shijiu/jsview": "2.2.373",
|
|
13
|
+
"@shijiu/jsview-vue": "2.2.373",
|
|
14
14
|
"gifuct-js": "^2.1.2",
|
|
15
15
|
"postcss-js": "^4.0.0",
|
|
16
16
|
"qr.js": "^0.0.0",
|
|
@@ -399,7 +399,7 @@
|
|
|
399
399
|
}
|
|
400
400
|
},
|
|
401
401
|
"node_modules/@shijiu/jsview": {
|
|
402
|
-
"version": "2.2.
|
|
402
|
+
"version": "2.2.373",
|
|
403
403
|
"license": "MIT",
|
|
404
404
|
"dependencies": {
|
|
405
405
|
"gifuct-js": "2.1.2",
|
|
@@ -417,7 +417,7 @@
|
|
|
417
417
|
"integrity": ""
|
|
418
418
|
},
|
|
419
419
|
"node_modules/@shijiu/jsview-vue": {
|
|
420
|
-
"version": "2.2.
|
|
420
|
+
"version": "2.2.373",
|
|
421
421
|
"license": "MIT",
|
|
422
422
|
"dependencies": {
|
|
423
423
|
"qr.js": "0.0.0"
|
|
@@ -1161,7 +1161,7 @@
|
|
|
1161
1161
|
"optional": true
|
|
1162
1162
|
},
|
|
1163
1163
|
"@shijiu/jsview": {
|
|
1164
|
-
"version": "2.2.
|
|
1164
|
+
"version": "2.2.373",
|
|
1165
1165
|
"requires": {
|
|
1166
1166
|
"gifuct-js": "2.1.2",
|
|
1167
1167
|
"postcss-js": "4.0.0"
|
|
@@ -1170,7 +1170,7 @@
|
|
|
1170
1170
|
"integrity": ""
|
|
1171
1171
|
},
|
|
1172
1172
|
"@shijiu/jsview-vue": {
|
|
1173
|
-
"version": "2.2.
|
|
1173
|
+
"version": "2.2.373",
|
|
1174
1174
|
"requires": {
|
|
1175
1175
|
"qr.js": "0.0.0"
|
|
1176
1176
|
},
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
"tool": "node node_modules/@shijiu/jsview/tools/jsview-run-tool.mjs --framework=vue"
|
|
13
13
|
},
|
|
14
14
|
"dependencies": {
|
|
15
|
-
"@shijiu/jsview": "2.2.
|
|
16
|
-
"@shijiu/jsview-vue": "2.2.
|
|
15
|
+
"@shijiu/jsview": "2.2.373",
|
|
16
|
+
"@shijiu/jsview-vue": "2.2.373",
|
|
17
17
|
"vue": "3.2.45",
|
|
18
18
|
"vue-router": "4.1.6"
|
|
19
19
|
},
|
|
@@ -9,8 +9,8 @@ export default {
|
|
|
9
9
|
AppVersion: "1.00",
|
|
10
10
|
|
|
11
11
|
// 上线前请更换, 此为小程序之家APK上线后的图标规范
|
|
12
|
-
AppIcon: "https://oss.image.qcast.cn/JsViewVideo/ImageTestSample/
|
|
12
|
+
AppIcon: "https://oss.image.qcast.cn/JsViewVideo/ImageTestSample/JsvMiniAppIcon256x256.png",
|
|
13
13
|
|
|
14
14
|
// 上线前请更换, 此为小程序之家APK上线后的图标规范
|
|
15
|
-
AppRectIcon: "https://oss.image.qcast.cn/JsViewVideo/ImageTestSample/
|
|
15
|
+
AppRectIcon: "https://oss.image.qcast.cn/JsViewVideo/ImageTestSample/JsvMiniAppIcon300x160.png",
|
|
16
16
|
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { JsvActiveFeature, JsvFeatureNames } from 'jsview'
|
|
2
|
+
|
|
3
|
+
export function EnableJsvFeatures() {
|
|
4
|
+
// 激活所有本渠道已经授权的feature, 注意由于渠道差异,不同渠道的内核的feature并不一致
|
|
5
|
+
// 具体哪些可以激活请咨询JsView商务
|
|
6
|
+
//
|
|
7
|
+
// 场景说明:
|
|
8
|
+
//
|
|
9
|
+
// 场景1: 未激活组件,而实际使用
|
|
10
|
+
// 组件使用时会自动调用 JsvUseFeature 来确认是否激活,
|
|
11
|
+
// 未激活时会有console.error提示,
|
|
12
|
+
// 并且内核中此功能也不会工作(从而也规避了内核调用未搭载组件而崩溃的问题)
|
|
13
|
+
//
|
|
14
|
+
// 场景2: 强制激活未授权的组件
|
|
15
|
+
// 如果激活未授权的组件,屏幕会有未授权的组件列表水印出现
|
|
16
|
+
// 并且所在渠道的内核不带此功能的场景下,会引起崩溃一系列问题
|
|
17
|
+
|
|
18
|
+
// 'TouchReceiver': 触控功能
|
|
19
|
+
JsvActiveFeature(JsvFeatureNames.TouchReceiver);
|
|
20
|
+
|
|
21
|
+
// 'FreeMoveDiv': 万向动画
|
|
22
|
+
JsvActiveFeature(JsvFeatureNames.FreeMoveDiv);
|
|
23
|
+
|
|
24
|
+
// 'CustomFragShader': 自定义3D变化效果
|
|
25
|
+
JsvActiveFeature(JsvFeatureNames.CustomFragShader);
|
|
26
|
+
|
|
27
|
+
// 'Capture2Texture': div显示截取功能
|
|
28
|
+
JsvActiveFeature(JsvFeatureNames.Capture2Texture);
|
|
29
|
+
}
|
|
@@ -2,6 +2,10 @@ import { createApp } from 'vue'
|
|
|
2
2
|
import { jsvCreateFocusManager } from 'jsview'
|
|
3
3
|
import App from './App.vue'
|
|
4
4
|
import { listenerToPermissionResult } from './permissionResult'
|
|
5
|
+
import { EnableJsvFeatures } from './featureEnables'
|
|
6
|
+
|
|
7
|
+
// 组件激活
|
|
8
|
+
EnableJsvFeatures();
|
|
5
9
|
|
|
6
10
|
// js授权状态的监听, app的编译版本上线前请联系商务对产品进行在线授权
|
|
7
11
|
listenerToPermissionResult();
|
|
@@ -10,7 +14,9 @@ const app = createApp(App)
|
|
|
10
14
|
|
|
11
15
|
|
|
12
16
|
// 注册JsView定制的焦点控制插件
|
|
13
|
-
app.use(jsvCreateFocusManager(
|
|
17
|
+
app.use(jsvCreateFocusManager({
|
|
18
|
+
autoSearchFocus: true
|
|
19
|
+
}), '#app')
|
|
14
20
|
|
|
15
21
|
app.mount('#app')
|
|
16
22
|
|
|
@@ -10,8 +10,8 @@ export function listenerToPermissionResult() {
|
|
|
10
10
|
// 4. 本地有授权文件,但授权文件不合法或者过期
|
|
11
11
|
// errorCount(int): 在线授权api访问失败(网络不通)的累计次数, api访问到并拿到结果后清0
|
|
12
12
|
// checkType(int): 授权的校验方式, 1: 调试模式, 2: 本地文件校验的方式, 3: 在线校验方式
|
|
13
|
-
// customDescribe: 授权的描述, 许可范围等描述
|
|
14
|
-
// errorCode: 授权失败的错误码
|
|
13
|
+
// customDescribe(string): 授权的描述, 许可范围等描述
|
|
14
|
+
// errorCode(int): 授权失败的错误码
|
|
15
15
|
// -1: apk签名不匹配(仅离线校验时)
|
|
16
16
|
// -2: js的app name未登记
|
|
17
17
|
// -3: js的app签名和app name登记信息不匹配
|
|
@@ -43,4 +43,9 @@ export function listenerToPermissionResult() {
|
|
|
43
43
|
|
|
44
44
|
console.log("onAuthResult info=" + JSON.stringify(info));
|
|
45
45
|
});
|
|
46
|
+
|
|
47
|
+
(window as any).JsView?.addEventListener("onAuthFoundDebugJs", (info: any) => {
|
|
48
|
+
// 当发现async import非build类型的js时
|
|
49
|
+
console.info("onAuth: Found debug js file loaded");
|
|
50
|
+
});
|
|
46
51
|
}
|
|
Binary file
|