chore:二维码正常
This commit is contained in:
@@ -357,7 +357,7 @@ export default {
|
|||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* 二维码容器样式: head/corner 按码尺寸定宽; rows/bottom 走通栏白卡(参考图),
|
* 二维码容器样式: head/corner 按码尺寸定宽; rows/bottom 走通栏白卡(参考图),
|
||||||
* 宽度交给卡内容区。微调位移(transform, WXSS 支持)仍作用于容器。
|
* 宽度交给卡内容区。微调位移改由 qrImgStyle 只作用于二维码图 —— 独立白卡容器保持不动。
|
||||||
* 外观衬底(白卡/主题色/渐变)在 qrImgStyle 上只包二维码图 ——
|
* 外观衬底(白卡/主题色/渐变)在 qrImgStyle 上只包二维码图 ——
|
||||||
* 「扫码查看完整名片」提示(2026-10-23 用户要求)在衬底外, 无蓝底
|
* 「扫码查看完整名片」提示(2026-10-23 用户要求)在衬底外, 无蓝底
|
||||||
*/
|
*/
|
||||||
@@ -372,11 +372,9 @@ export default {
|
|||||||
style.marginLeft = this.blockEdgeMargin;
|
style.marginLeft = this.blockEdgeMargin;
|
||||||
style.marginRight = this.blockEdgeMargin;
|
style.marginRight = this.blockEdgeMargin;
|
||||||
}
|
}
|
||||||
const transform = qrTransform(this.c.qrOffsetX, this.c.qrOffsetY);
|
|
||||||
if (transform) style.transform = transform;
|
|
||||||
return this.$util.objToStyle(style);
|
return this.$util.objToStyle(style);
|
||||||
},
|
},
|
||||||
/** 二维码图样式: 尺寸 + 外观衬底(plain 原图 / card 白卡 / theme 主题色 / gradient 渐变) */
|
/** 二维码图样式: 尺寸 + 外观衬底(plain 原图 / card 白卡 / theme 主题色 / gradient 渐变) + 微调位移(只动图, 白卡容器不动) */
|
||||||
qrImgStyle() {
|
qrImgStyle() {
|
||||||
const size = resolveQrSize(this.qrPos, this.c.qrSize);
|
const size = resolveQrSize(this.qrPos, this.c.qrSize);
|
||||||
const style = {
|
const style = {
|
||||||
@@ -400,6 +398,9 @@ export default {
|
|||||||
style.borderRadius = '16rpx';
|
style.borderRadius = '16rpx';
|
||||||
style.padding = '6rpx';
|
style.padding = '6rpx';
|
||||||
}
|
}
|
||||||
|
// 微调位移(水平/垂直)只作用于二维码图本身, 外层独立白卡(.mini-qr-center)保持不动
|
||||||
|
const transform = qrTransform(this.c.qrOffsetX, this.c.qrOffsetY);
|
||||||
|
if (transform) style.transform = transform;
|
||||||
return this.$util.objToStyle(style);
|
return this.$util.objToStyle(style);
|
||||||
},
|
},
|
||||||
showDetailBtn() {
|
showDetailBtn() {
|
||||||
@@ -916,19 +917,13 @@ export default {
|
|||||||
// 面板「独立样式」为隐式开关(与操作区/资料区同款): 独立成块=配了底色/圆角/内边距, 跟随卡片=三者清空
|
// 面板「独立样式」为隐式开关(与操作区/资料区同款): 独立成块=配了底色/圆角/内边距, 跟随卡片=三者清空
|
||||||
return !!(String(c.qrBlockBg || '').trim() || num(c.qrBlockRadius, 0) || num(c.qrBlockPad, 0));
|
return !!(String(c.qrBlockBg || '').trim() || num(c.qrBlockRadius, 0) || num(c.qrBlockPad, 0));
|
||||||
},
|
},
|
||||||
/** 二维码(rows/bottom 流内档)最终样式: 独立成块(白卡) 或 跟随卡片(连一体) + 位移微调合并 */
|
/** 二维码(rows/bottom 流内档)最终样式: 独立成块(白卡) 或 跟随卡片(连一体); 位移微调在 qrImgStyle 只动图 */
|
||||||
qrBlockFinalStyle() {
|
qrBlockFinalStyle() {
|
||||||
const transform = qrTransform(this.c.qrOffsetX, this.c.qrOffsetY);
|
|
||||||
if (this.qrIndependent) {
|
if (this.qrIndependent) {
|
||||||
const parts = [this.qrBlockStyle, this.qrBlockCustomStyle];
|
return [this.qrBlockStyle, this.qrBlockCustomStyle].filter(Boolean).join(' ').trim();
|
||||||
if (transform) parts.push('transform:' + transform + ';');
|
|
||||||
return parts.filter(Boolean).join(' ').trim();
|
|
||||||
}
|
}
|
||||||
// 跟随卡片: 去掉 .mini-qr-center 静态白卡(白底/描边/阴影/圆角/内边距), 与上方同底连为一体(保留位移微调, 居中靠 CSS)
|
// 跟随卡片: 去掉 .mini-qr-center 静态白卡(白底/描边/阴影/圆角/内边距), 与上方同底连为一体(微调位移改由 qrImgStyle 只动二维码图)
|
||||||
const flat = 'background: transparent; border: 0; box-shadow: none; border-radius: 0; padding: 0;';
|
return 'background: transparent; border: 0; box-shadow: none; border-radius: 0; padding: 0;';
|
||||||
const parts = [flat];
|
|
||||||
if (transform) parts.push('transform:' + transform + ';');
|
|
||||||
return parts.filter(Boolean).join(' ').trim();
|
|
||||||
},
|
},
|
||||||
/** plain 头最终样式:头部容器配置与 corner 二维码让位合并为单字符串。 */
|
/** plain 头最终样式:头部容器配置与 corner 二维码让位合并为单字符串。 */
|
||||||
plainHeadFinalStyle() {
|
plainHeadFinalStyle() {
|
||||||
|
|||||||
Reference in New Issue
Block a user