更新记录
1.0.1(2025-11-17)
优化
1.0.0(2025-11-01)
初始化
平台兼容性
uni-app(4.24)
| Vue2 | Vue3 | Chrome | Safari | app-vue | app-nvue | Android | iOS | 鸿蒙 |
|---|---|---|---|---|---|---|---|---|
| √ | √ | - | - | - | √ | 5.0 | - | √ |
| 微信小程序 | 支付宝小程序 | 抖音小程序 | 百度小程序 | 快手小程序 | 京东小程序 | 鸿蒙元服务 | QQ小程序 | 飞书小程序 | 快应用-华为 | 快应用-联盟 |
|---|---|---|---|---|---|---|---|---|---|---|
| - | - | - | - | - | - | - | - | - | - | - |
uni-app x(3.6.14)
| Chrome | Safari | Android | iOS | 鸿蒙 | 微信小程序 |
|---|---|---|---|---|---|
| - | - | 5.0 | - | √ | - |
xtf-viewscreenshot
插件测试使用方法
-
选择试用,绑定要试用的项目appid,
-
选择后下载到对应的本地项目,
-
按照文档 -》把插件引入项目(即
import { screenShot,ScreenData, reuqestScreen,stopscreenShotSystem,capScreenShotSystem } from '@/uni_modules/xtf-viewscreenshot';
;
需要先引入),
4. 发布-》云打包-》选择制作基座-》打包等基座制作完成
5. 运行 -》 运行到手机或模拟器-》运行到Androidapp基座-》选择使用自定义基座运行-》选择手机-》运行
6. 若之前手机安装过基座需要先卸载之前的基座
###
安卓鸿蒙应用内截图 截图当前应用
uniappx
~~~
import { screenShot,ScreenData, reuqestScreen,stopscreenShotSystem,capScreenShotSystem } from '@/uni_modules/xtf-viewscreenshot';
// 安卓鸿蒙
screenShot(function(b:string){
console.log(b)
});
// 请求应用截图权限(仅安卓)
reuqestScreen({
callback:function(b:string){
},
perCallback:function(b:boolean){
}
})
capScreenShotSystem();// 截图 (仅安卓)
stopscreenShotSystem();//停止截图 (仅安卓)
~~~
uniapp
~~~
import { screenShot,ScreenData, reuqestScreen,stopscreenShotSystem,capScreenShotSystem } from '@/uni_modules/xtf-viewscreenshot';
// 安卓鸿蒙
screenShot(function(b){
console.log(b)
});
// 请求应用截图权限
reuqestScreen({
callback:function(b){
},
perCallback:function(b){
}
})
capScreenShotSystem();// 截图
stopscreenShotSystem();//停止截图
~~~
### 开发文档
[UTS 语法](https://uniapp.dcloud.net.cn/tutorial/syntax-uts.html)
[UTS API插件](https://uniapp.dcloud.net.cn/plugin/uts-plugin.html)
[UTS uni-app兼容模式组件](https://uniapp.dcloud.net.cn/plugin/uts-component.html)
[UTS 标准模式组件](https://doc.dcloud.net.cn/uni-app-x/plugin/uts-vue-component.html)
[Hello UTS](https://gitcode.net/dcloud/hello-uts)

收藏人数:
购买源码授权版(
试用
使用 HBuilderX 导入示例项目
赞赏(0)
下载 8337
赞赏 70
下载 12360873
赞赏 1828
赞赏
京公网安备:11010802035340号