<script setup lang="ts">
import { onMounted } from 'vue'

const CORP_ID = 'ww69e8e44636f47780'
const REDIRECT_URI = encodeURIComponent('https://qj.dhdx.fun/login')
const STATE = 'bind'

onMounted(() => {
  const url = `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${CORP_ID}&redirect_uri=${REDIRECT_URI}&response_type=code&scope=snsapi_base&state=${STATE}#wechat_redirect`
  window.location.href = url
})
</script>

<template>
  <div class="bind-wechat-page">
    <p>正在跳转企业微信授权...</p>
  </div>
</template>

<style scoped>
.bind-wechat-page {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  font-size: 16px;
  color: var(--ink);
  font-family: 'Noto Serif SC', STSong, serif;
}
</style>
