feat(share): 分享页调整
This commit is contained in:
parent
f0ba57a7a4
commit
1ea89b0c68
|
@ -72,8 +72,7 @@
|
||||||
import html2canvas from 'html2canvas'
|
import html2canvas from 'html2canvas'
|
||||||
import { getShareCode } from '@/config/share'
|
import { getShareCode } from '@/config/share'
|
||||||
import clTabbar from '@/components/cl-tabbar.vue'
|
import clTabbar from '@/components/cl-tabbar.vue'
|
||||||
import VConsole from 'vconsole'
|
|
||||||
const vConsole = new VConsole()
|
|
||||||
export default {
|
export default {
|
||||||
name: 'ShareQRCode',
|
name: 'ShareQRCode',
|
||||||
components: {
|
components: {
|
||||||
|
@ -245,7 +244,8 @@ export default {
|
||||||
useCORS: true,
|
useCORS: true,
|
||||||
allowTaint: true,
|
allowTaint: true,
|
||||||
backgroundColor: null,
|
backgroundColor: null,
|
||||||
scale: Math.max(3, window.devicePixelRatio * 2),
|
scale: 2,
|
||||||
|
dpi: 400,
|
||||||
logging: true, // 开启日志便于调试
|
logging: true, // 开启日志便于调试
|
||||||
width: element.offsetWidth,
|
width: element.offsetWidth,
|
||||||
height: element.offsetHeight,
|
height: element.offsetHeight,
|
||||||
|
@ -257,7 +257,7 @@ export default {
|
||||||
y: 0,
|
y: 0,
|
||||||
})
|
})
|
||||||
.then(canvas => {
|
.then(canvas => {
|
||||||
const dataUrl = canvas.toDataURL('image/png', 1.0)
|
const dataUrl = canvas.toDataURL('image/jpeg', 1)
|
||||||
|
|
||||||
// 根据环境处理结果
|
// 根据环境处理结果
|
||||||
if (this.isWechat) {
|
if (this.isWechat) {
|
||||||
|
|
Loading…
Reference in New Issue