小程序菊花码无法生成白色
let res = await rp(opt) opt = { method: 'POST', url: 'https://api.weixin.qq.com/wxa/getwxacodeunlimit?access_token=' + res.access_token, body: { 'page': event.page, 'width': event.width, 'scene': event.scene, 'line_color': { "r": 255, "g": 255, "b": 255 }, 'is_hyaline': true, }, json: true, encoding: null } return await rp(opt) |
生成小程序二维码的时候,将线条rgb颜色设置为255,255,255,生成出来的为黑色。
实际测试后发现,只要rgb大于185 生成出的菊花码都是黑色。
因为自己设置了背景图,需要使用白色的菊花码。
