wx-open-launch-weapp 使用rem和flex布局如何实现?
发布于 5 年前 作者 lei76 5555 次浏览 来自 问答

wx-open-launch-weapp  中使用rem不起作用

<wx-open-launch-weapp
  id="launch-btn"
  username=""
>
  <script type="text/wxtag-template">
    <div style="display: flex;flex-direction: column;align-items: center;justify-content: center;width: 100%;height: 100%">
      <img src="data:image/jpeg;base64,"
           style="width: 100px;height: 1.387rem;margin-bottom: 0.187rem"/>
      <div style="font-size: 14px;font-family: PingFangSC, PingFangSC-Regular;font-weight: 400;
text-align: center;color: #ffd7ac;line-height: 16px;">健康码</div>
    </div>
  </script>
</wx-open-launch-weapp>
1 回复

个人已解决问题,

原理是采用外部布局,内部position实现点击跳转事件,将wx-open-launch-weapp覆盖在外部上方

回到顶部