- 博客(3)
- 收藏
- 关注
原创 canvas 旋转一个元素
//配合图片理解//需要参数let c_left = 100 // xlet c_top = 100 // ylet d_with = 100 // 元素宽let d_height = 100 // 元素高let a = 45 // 元素旋转角度ctx.save() // 先保存画布//一定要以中心点计算 (这里一开始是按照左上位置 旋转不同角度 老是偏移)let left = c_left + d_with/2 //中心点位置let top .
2022-02-25 18:11:27
441
原创 uniapp app.vue加载完成后运行首页
1.main.jsVue.prototype.$onLaunched = new Promise(resolve => { Vue.prototype.$isResolve = resolve;})2.app.vue的onLaunchthis.$isResolve()3.首页onLoadasync onLoad(options) { await this.$onLaunched;},
2021-07-06 17:42:56
2712
原创 uniapp 金额输入框
testMoney(e){ let that = this; let price = e.detail.value if (price.indexOf(".") == 0) { //'首位小数点情况' price = price.replace(/[^$#$]/g, "0."); pr...
2021-06-24 13:51:46
2121
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人