mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Sku): small image mode and text ellipsis (#6604)
This commit is contained in:
parent
796eb46bac
commit
62cd251327
@ -47,9 +47,8 @@ export default createComponent({
|
|||||||
|
|
||||||
genImage(classPrefix) {
|
genImage(classPrefix) {
|
||||||
const { imgUrl } = this;
|
const { imgUrl } = this;
|
||||||
|
if (imgUrl) {
|
||||||
if (imgUrl && this.largePicturePreview) {
|
if (this.largePicturePreview && this.lazyLoad) {
|
||||||
if (this.lazyLoad) {
|
|
||||||
return (
|
return (
|
||||||
<img class={`${classPrefix}-img`} src={imgUrl} vLazy={imgUrl} />
|
<img class={`${classPrefix}-img`} src={imgUrl} vLazy={imgUrl} />
|
||||||
);
|
);
|
||||||
@ -83,7 +82,13 @@ export default createComponent({
|
|||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
{this.genImage(classPrefix)}
|
{this.genImage(classPrefix)}
|
||||||
<span class={`${classPrefix}-name`}>{this.skuValue.name}</span>
|
<div class={`${classPrefix}-name`}>
|
||||||
|
<span
|
||||||
|
class={this.largePicturePreview ? 'van-multi-ellipsis--l2' : ''}
|
||||||
|
>
|
||||||
|
{this.skuValue.name}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
</span>
|
</span>
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user