企业微信扫码登录后台管理系统,如何修改二维码样式
href字段为转码成base64格式的css文件 ,企业微信会把这个样式添加到iframe中
import { Base64 } from 'js-base64'
new WwLogin({
id: 'm-wx-qrcode',
appid: appId,
agentid: agentId,
redirect_uri: encodeURIComponent(redirectUri),
state: 'wechat_login',
href: `data:text/css;base64,${Base64.encode(
`.impowerBox .qrcode {width: 200px;}`
)}`,
})
参考链接:
https://blog.csdn.net/Kiruthika/article/details/123828143
https://developers.weixin.qq.com/doc/oplatform/Website_App/WeChat_Login/Wechat_Login.html