【新增】设置、邮箱组件页面提交
This commit is contained in:
140
src/components/Email/components/home.vue
Normal file
140
src/components/Email/components/home.vue
Normal file
@@ -0,0 +1,140 @@
|
||||
<template>
|
||||
<div class="home-page">
|
||||
<div class="title"> 您好,demo。 </div>
|
||||
<div class="unread">
|
||||
<img src="../img/logo.png" alt="" />
|
||||
<p>邮件: 0 封未读邮件</p>
|
||||
</div>
|
||||
<div class="line">
|
||||
<span style="margin-right: 10px">收件箱(0)</span>
|
||||
<span style="margin-right: 10px">群邮件(0)</span>
|
||||
<span style="margin-right: 10px">订阅中心(0)</span>
|
||||
<span style="margin-right: 10px">阅读空间(0)</span>
|
||||
</div>
|
||||
<div class="block">
|
||||
<div class="head">
|
||||
<p>邮箱推荐</p>
|
||||
</div>
|
||||
<div class="banner">
|
||||
<div class="banner-image"></div>
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="item">
|
||||
<div>
|
||||
<div class="icon"></div>
|
||||
iPhone版
|
||||
</div>
|
||||
<div><div class="icon"></div>明信片 - 贺卡</div>
|
||||
<div><div class="icon"></div>iPad版</div>
|
||||
<div><div class="icon"></div>记事本 - 日历</div>
|
||||
<div><div class="icon"></div>Android版</div>
|
||||
<div><div class="icon"></div>文件中转站</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="line" style="padding-left: 9px; margin-top: 20px; font-size: 12px;">
|
||||
<span style="margin: 0 10px; margin-left: 0;">企业邮箱</span>|
|
||||
<span style="margin: 0 10px">开放平台</span>|
|
||||
<span style="margin: 0 10px">体验室</span>|
|
||||
<span style="margin: 0 10px">邮箱助手</span>|
|
||||
<span style="margin: 0 10px">自助查询</span>|
|
||||
<span style="margin: 0 10px">团队博客</span>|
|
||||
<span style="margin: 0 10px">加入我们</span>
|
||||
</div>
|
||||
<p class="foot">标准版 - <span style="color: #6767e8;">基本版</span> | CopyRight 1998 -2017</p>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.home-page {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
padding: 20px 10px;
|
||||
.title {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.unread {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-top: 10px;
|
||||
padding-left: 10px;
|
||||
> img {
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
> p {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
.line {
|
||||
font-size: 14px;
|
||||
padding-left: 27px;
|
||||
margin-top: 10px;
|
||||
}
|
||||
.block {
|
||||
margin-top: 20px;
|
||||
width: 100%;
|
||||
border: 2px solid #cac6c6;
|
||||
.head {
|
||||
border-bottom: 2px solid #cac6c6;
|
||||
background: #e0e0e0;
|
||||
> p {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
padding-left: 15px;
|
||||
line-height: 36px;
|
||||
}
|
||||
}
|
||||
.banner {
|
||||
height: 100px;
|
||||
padding: 3px;
|
||||
border-bottom: 2px solid #cac6c6;
|
||||
.banner-image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: pink;
|
||||
}
|
||||
}
|
||||
.list {
|
||||
padding: 30px;
|
||||
.item {
|
||||
width: 70%;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
> div {
|
||||
width: 50%;
|
||||
margin-top: 10px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.icon {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
margin-right: 7px;
|
||||
background-image: url('../img/logo.png');
|
||||
background-size: 100% 100%;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
}
|
||||
> div:nth-child(1),
|
||||
> div:nth-child(2) {
|
||||
margin-top: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.foot {
|
||||
margin-top: 10px;
|
||||
font-size: 10px;
|
||||
color: #c2c1c1;
|
||||
padding-left: 9px;
|
||||
}
|
||||
}
|
||||
</style>
|
148
src/components/Email/components/sent.vue
Normal file
148
src/components/Email/components/sent.vue
Normal file
@@ -0,0 +1,148 @@
|
||||
<template>
|
||||
<div class="sent-page">
|
||||
<div class="title">
|
||||
<p>已发送(共0封)</p>
|
||||
</div>
|
||||
<div class="main">
|
||||
<div class="btn-line">
|
||||
<div class="flex">
|
||||
<el-button type="info">删除</el-button>
|
||||
<el-button type="info">彻底删除</el-button>
|
||||
<el-button type="info">全部标记为已读</el-button>
|
||||
<el-button type="info">标记为……</el-button>
|
||||
<el-button type="info">移动到……</el-button>
|
||||
</div>
|
||||
<div>1/1页</div>
|
||||
</div>
|
||||
<div class="email-table">
|
||||
<el-table
|
||||
ref="multipleTableRef"
|
||||
:data="tableData"
|
||||
:empty-text="'查询发信投递状态'"
|
||||
style="width: 100%; height: 100%"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column width="120">
|
||||
<template #header>
|
||||
<div class="icon-group">
|
||||
<div class="email"></div>
|
||||
<div class="link"></div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="收件人" width="200" />
|
||||
<el-table-column label="主题" show-overflow-tooltip />
|
||||
<el-table-column label="时间" width="150" />
|
||||
</el-table>
|
||||
</div>
|
||||
<div>
|
||||
<div class="choose">
|
||||
<p><span>选择:</span>全部 - 无 - 已读 - 未读</p>
|
||||
</div>
|
||||
<div class="btn-line">
|
||||
<div class="flex">
|
||||
<el-button type="info">删除</el-button>
|
||||
<el-button type="info">彻底删除</el-button>
|
||||
<el-button type="info">全部标记为已读</el-button>
|
||||
<el-button type="info">标记为……</el-button>
|
||||
<el-button type="info">移动到……</el-button>
|
||||
</div>
|
||||
<div>1/1页</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref } from 'vue'
|
||||
import { ElTable } from 'element-plus'
|
||||
|
||||
const multipleTableRef = ref<InstanceType<typeof ElTable>>()
|
||||
const tableData = ref([] as any)
|
||||
const multipleSelection = ref<any[]>([])
|
||||
const handleSelectionChange = (val: any[]) => {
|
||||
multipleSelection.value = val
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.sent-page {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
padding: 10px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.title {
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
}
|
||||
.main {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
margin-top: 10px;
|
||||
.btn-line {
|
||||
width: 100%;
|
||||
background: #e0e0e0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 10px;
|
||||
font-size: 12px;
|
||||
.flex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.el-button {
|
||||
height: 24px;
|
||||
padding: 7px 10px;
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
.email-table {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
.el-table {
|
||||
.el-table__header-wrapper {
|
||||
.icon-group {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.email {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background: url('../img/email_o.png') no-repeat center;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
.link {
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
background: url('../img/href-F.png') no-repeat center;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
}
|
||||
.icon-group:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.choose {
|
||||
width: 100%;
|
||||
background: #eee;
|
||||
padding: 10px;
|
||||
> p {
|
||||
font-size: 12px;
|
||||
color: rgb(56, 56, 189);
|
||||
> span {
|
||||
color: #666;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
BIN
src/components/Email/img/QQ-email_white.png
Normal file
BIN
src/components/Email/img/QQ-email_white.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.1 KiB |
BIN
src/components/Email/img/email_o.png
Normal file
BIN
src/components/Email/img/email_o.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.6 KiB |
BIN
src/components/Email/img/href-F.png
Normal file
BIN
src/components/Email/img/href-F.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 6.4 KiB |
BIN
src/components/Email/img/logo.png
Normal file
BIN
src/components/Email/img/logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.6 KiB |
247
src/components/Email/index.vue
Normal file
247
src/components/Email/index.vue
Normal file
@@ -0,0 +1,247 @@
|
||||
<template>
|
||||
<div class="email-page">
|
||||
<div class="header">
|
||||
<div class="left">
|
||||
<div class="logo">
|
||||
<img src="./img/QQ-email_white.png" alt="" />
|
||||
</div>
|
||||
<div class="text">
|
||||
<p style="font-size: 12px">demo(123456@qq.com)</p>
|
||||
<div style="font-size: 12px; margin-top: 5px">
|
||||
<span style="cursor: pointer;">邮箱首页</span> | <span style="cursor: pointer;">设置-换肤</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="text">
|
||||
<div style="font-size: 12px">
|
||||
<span style="cursor: pointer;">反馈建议</span> | <span style="cursor: pointer;">帮助中心</span> | <span style="cursor: pointer;" @click="exitEmail">退出</span>
|
||||
</div>
|
||||
</div>
|
||||
<el-input v-model="searchVal" placeholder="邮件全文搜索……" :prefix-icon="Search" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="main">
|
||||
<div class="sidebar">
|
||||
<div class="top">
|
||||
<div
|
||||
v-for="big in bigList"
|
||||
:key="big.name"
|
||||
class="big-li"
|
||||
@click="sidebarHandle(big.name)"
|
||||
>
|
||||
<div
|
||||
class="icon"
|
||||
:style="{
|
||||
width: '16px',
|
||||
height: '16px',
|
||||
backgroundImage: `url(${big.icon})`,
|
||||
marginRight: '6px'
|
||||
}"
|
||||
></div>
|
||||
<div class="text">{{ big.name }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bottom">
|
||||
<div v-for="small in smallList" :key="small.name" class="small-li">
|
||||
<div class="left" @click="sidebarHandle(small.name)">
|
||||
<div
|
||||
class="text"
|
||||
:style="{ fontWeight: small.name === selectSidebar ? '600' : 'normal' }"
|
||||
>{{ small.name }}</div
|
||||
>
|
||||
<div
|
||||
v-if="small.icon"
|
||||
class="icon"
|
||||
:style="{
|
||||
width: '12px',
|
||||
height: '12px',
|
||||
backgroundImage: `url(${small.icon})`,
|
||||
marginLeft: '6px'
|
||||
}"
|
||||
></div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<p style="font-size: 10px; cursor: pointer">{{ small.button }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="operation">
|
||||
<Sent v-if="selectSidebar === '已发送'" />
|
||||
<Home v-else />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref } from 'vue'
|
||||
import { Search } from '@element-plus/icons-vue'
|
||||
import Sent from './components/sent.vue'
|
||||
import Home from './components/home.vue'
|
||||
import { ElMessageBox } from 'element-plus'
|
||||
|
||||
const searchVal = ref('')
|
||||
|
||||
const bigList = [
|
||||
{
|
||||
name: '写信',
|
||||
icon: new URL('./img/logo.png', import.meta.url).href
|
||||
},
|
||||
{
|
||||
name: '收信',
|
||||
icon: new URL('./img/logo.png', import.meta.url).href
|
||||
},
|
||||
{
|
||||
name: '通讯录',
|
||||
icon: new URL('./img/logo.png', import.meta.url).href
|
||||
}
|
||||
]
|
||||
const smallList = [
|
||||
{
|
||||
name: '收件箱'
|
||||
},
|
||||
{
|
||||
name: '星标邮件',
|
||||
icon: new URL('./img/logo.png', import.meta.url).href
|
||||
},
|
||||
{
|
||||
name: '群邮件'
|
||||
},
|
||||
{
|
||||
name: '草稿箱'
|
||||
},
|
||||
{
|
||||
name: '已发送'
|
||||
},
|
||||
{
|
||||
name: '已删除'
|
||||
},
|
||||
{
|
||||
name: '垃圾箱',
|
||||
button: '[清空]'
|
||||
},
|
||||
{
|
||||
name: 'QQ邮箱订阅'
|
||||
}
|
||||
]
|
||||
|
||||
const selectSidebar = ref('')
|
||||
const sidebarHandle = (name: string) => {
|
||||
selectSidebar.value = name
|
||||
}
|
||||
|
||||
const exitEmail = () => {
|
||||
ElMessageBox.confirm('确认要退出QQ邮箱吗?', '询问', {
|
||||
confirmButtonText: '是(Y)',
|
||||
cancelButtonText: '否(N)',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {})
|
||||
.catch(() => {})
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.email-page {
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
overflow: hidden;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.header {
|
||||
width: 100%;
|
||||
height: 70px;
|
||||
background: #5f5f5f;
|
||||
color: #e0e0e0;
|
||||
padding: 0px 10px 0px 20px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
height: 100%;
|
||||
padding: 15px 0;
|
||||
.logo {
|
||||
height: 100%;
|
||||
margin-right: 20px;
|
||||
> img {
|
||||
width: 100px;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.right {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-end;
|
||||
justify-content: space-between;
|
||||
height: 100%;
|
||||
padding: 10px 0 5px;
|
||||
.el-input {
|
||||
height: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.main {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
background: #f5f7f6;
|
||||
display: flex;
|
||||
.sidebar {
|
||||
width: 15%;
|
||||
height: 100%;
|
||||
background: #cecece;
|
||||
.top {
|
||||
padding: 15px 20px;
|
||||
border-bottom: 1px solid #fff;
|
||||
.big-li {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 10px;
|
||||
cursor: pointer;
|
||||
.icon {
|
||||
background-size: 100% 100%;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
}
|
||||
.big-li:nth-last-child(1) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
.bottom {
|
||||
padding: 15px 20px;
|
||||
border-bottom: 1px solid #a19999;
|
||||
font-size: 12px;
|
||||
.small-li {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 5px;
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
cursor: pointer;
|
||||
.icon {
|
||||
background-size: 100% 100%;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
}
|
||||
}
|
||||
.small-li:nth-last-child(1) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
.operation {
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user