| | |
| | | qrCodeLoginPath: '/auth/qrcode-login', |
| | | registerPath: '/auth/register', |
| | | showCodeLogin: true, |
| | | showDocLink: true, |
| | | showForgetPassword: true, |
| | | showQrcodeLogin: true, |
| | | showRegister: true, |
| | |
| | | }); |
| | | |
| | | const emit = defineEmits<{ |
| | | submit: [Recordable<any>]; |
| | | submit: [Recordable<unknown>]; |
| | | thirdLogin: [type: number]; |
| | | }>(); |
| | | |
| | |
| | | </script> |
| | | |
| | | <template> |
| | | <div @keydown.enter.prevent="handleSubmit"> |
| | | <div class="authentication-login" @keydown.enter.prevent="handleSubmit"> |
| | | <slot name="title"> |
| | | <Title> |
| | | <slot name="title"> |
| | | {{ title || `${$t('authentication.welcomeBack')} 👋🏻` }} |
| | | {{ title || $t('authentication.welcomeBack') }} |
| | | </slot> |
| | | <template #desc> |
| | | <span class="text-muted-foreground"> |
| | |
| | | |
| | | <div |
| | | v-if="showRememberMe || showForgetPassword" |
| | | class="mb-6 flex justify-between" |
| | | class="mb-6 flex items-center justify-between" |
| | | > |
| | | <div class="flex-center"> |
| | | <VbenCheckbox |
| | |
| | | |
| | | <span |
| | | v-if="showForgetPassword" |
| | | class="vben-link text-sm font-normal" |
| | | class="vben-link cursor-pointer rounded-sm text-sm font-normal outline-none focus-visible:ring-2 focus-visible:ring-emerald-500/50" |
| | | role="link" |
| | | tabindex="0" |
| | | @click="handleGo(forgetPasswordPath)" |
| | | @keydown.enter.prevent="handleGo(forgetPasswordPath)" |
| | | > |
| | | {{ $t('authentication.forgetPassword') }} |
| | | </span> |
| | |
| | | }" |
| | | :loading="loading" |
| | | aria-label="login" |
| | | class="w-full" |
| | | class="h-12 w-full rounded-xl bg-emerald-600 text-base font-semibold tracking-[0.18em] text-white shadow-[0_10px_24px_rgba(5,150,105,0.22)] transition-[background-color,box-shadow] duration-200 hover:bg-emerald-700 hover:shadow-[0_12px_28px_rgba(5,150,105,0.3)] focus-visible:ring-2 focus-visible:ring-emerald-500/50 disabled:cursor-not-allowed disabled:opacity-70" |
| | | @click="handleSubmit" |
| | | > |
| | | {{ submitButtonText || $t('common.login') }} |
| | |
| | | </slot> |
| | | |
| | | <!-- 萌新必读 --> |
| | | <DocLink /> |
| | | <DocLink v-if="showDocLink" /> |
| | | </div> |
| | | </template> |