<template>
	<div class="error layout-padding">
		<div class="layout-padding-auto layout-padding-view">
			<div class="error-flex">
				<div class="left">
					<div class="left-item">
            <SvgIcon name="iconfont icon-icon-test" size="120px" class="color-primary"/>
						<div class="left-item-animation left-item-title">当前地址未找到~</div>
						<div class="left-item-animation left-item-msg">您可以先检查网址，然后重新填写或给我们反馈问题。</div>
						<div class="left-item-animation left-item-btn">
							<el-button type="primary" round @click="onGoHome">返回首页</el-button>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
</template>

<script setup lang="ts" name="404">
import { useRouter } from 'vue-router';
import { getImageUrl } from '@/utils/tools';

// 定义变量内容
const router = useRouter();
// 返回首页
const onGoHome = () => {
	router.push('/');
};
</script>

<style scoped lang="scss">
.error {
	height: 100%;

	.error-flex {
		margin: auto;
		display: flex;
		height: 350px;
		width:100%;
    justify-content: center;
    align-items: center;
		.left {
			.left-item {
				.left-item-animation {
					opacity: 0;
					animation-name: error-num;
					animation-duration: 0.5s;
					animation-fill-mode: forwards;
				}

				.left-item-num {
					color: var(--el-color-info);
					font-size: 55px;
				}

				.left-item-title {
					font-size: 20px;
					color: var(--el-text-color-primary);
					margin: 15px 0 5px 0;
					animation-delay: 0.1s;
				}

				.left-item-msg {
					color: var(--el-text-color-secondary);
					font-size: 12px;
					margin-bottom: 20px;
					animation-delay: 0.2s;
				}

				.left-item-btn {
					animation-delay: 0.2s;
				}
			}
		}
	}
}
</style>
