UnisKB/ui/src/components/login-container/index.vue

51 lines
1.1 KiB
Vue
Raw Normal View History

2023-10-12 08:36:16 +00:00
<template>
<div class="login-form-container">
<div class="login-title">
2023-12-12 03:32:45 +00:00
<div class="title flex-center mb-8">
<div class="logo mr-4"></div>
2023-11-02 10:25:09 +00:00
<div class="app-logo-font">{{ title || defaultTitle }}</div>
2023-10-12 08:36:16 +00:00
</div>
2023-12-12 03:32:45 +00:00
<div class="sub-title text-center" v-if="subTitle">
<el-text type="info">{{ subTitle }}</el-text>
</div>
2023-10-12 08:36:16 +00:00
</div>
2023-12-12 03:32:45 +00:00
<el-card class="login-card">
<slot></slot>
</el-card>
2023-10-12 08:36:16 +00:00
</div>
</template>
<script setup lang="ts">
const defaultTitle = import.meta.env.VITE_APP_TITLE
defineOptions({ name: 'LoginContainer' })
defineProps({
title: String,
subTitle: String
})
</script>
<style lang="scss" scope>
.login-form-container {
2023-12-12 03:32:45 +00:00
width: 480px;
2023-10-12 08:36:16 +00:00
.login-title {
2023-12-12 03:32:45 +00:00
margin-bottom: 32px;
2023-10-12 08:36:16 +00:00
.title {
2023-12-12 03:32:45 +00:00
font-size: 32px;
2023-10-12 08:36:16 +00:00
.logo {
2023-12-18 06:42:13 +00:00
background-image: url('@/assets/logo.png');
2023-10-12 08:36:16 +00:00
background-size: 100% 100%;
2023-12-12 03:32:45 +00:00
width: 45px;
height: 45px;
2023-10-12 08:36:16 +00:00
}
}
.sub-title {
2023-12-12 03:32:45 +00:00
font-size: 16px;
2023-10-12 08:36:16 +00:00
}
}
2023-12-12 03:32:45 +00:00
.login-card {
border-radius: 8px;
padding: 18px;
}
2023-10-12 08:36:16 +00:00
}
</style>