this.covers.push({
id: 0,
latitude: 30.4856235372964,
longitude: 104.03312524551393,
iconPath: '../../static/map/new.png',
callout: {
content: '6',
color: 'red',
bgColor: 'green',
display: 'ALWAYS',
},
label: {
content: '5',
color: '#ffffff',
fontSize: '10rpx',
bgColor: '#3D73DD',
anchorX: -14,
anchorY: -10
},
width: 20,
height: 20
});
- 发布:2021-04-19 14:13
- 更新:2021-04-19 14:13
- 阅读:366
产品分类: uniapp/App
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: 10
手机系统: iOS
手机系统版本号: IOS 14
手机厂商: 苹果
手机机型: 苹果X
页面类型: nvue
打包方式: 云端
项目创建方式: CLI
CLI版本号: 4.5.0
示例代码:
操作步骤:
this.covers.push({
id: 0,
latitude: 30.4856235372964,
longitude: 104.03312524551393,
iconPath: '../../static/map/new.png',
callout: {
content: '6',
color: 'red',
bgColor: 'green',
display: 'ALWAYS',
},
label: {
content: '5',
color: '#ffffff',
fontSize: '10rpx',
bgColor: '#3D73DD',
anchorX: -14,
anchorY: -10
},
width: 20,
height: 20
});
this.covers.push({
id: 0,
latitude: 30.4856235372964,
longitude: 104.03312524551393,
iconPath: '../../static/map/new.png',
callout: {
content: '6',
color: 'red',
bgColor: 'green',
display: 'ALWAYS',
},
label: {
content: '5',
color: '#ffffff',
fontSize: '10rpx',
bgColor: '#3D73DD',
anchorX: -14,
anchorY: -10
},
width: 20,
height: 20
});
预期结果:
label中配置x,y能正常移动label位置
label中配置x,y能正常移动label位置
实际结果:
x,y配置不生效
x,y配置不生效
bug描述:
map组件label的x和y不生效,改成anchorX, anchorY后,anchorY不生效,anchorX位置是斜着改变位置的
0 个回复