fix(projects): 页面各部分背景颜色添加自然过渡

This commit is contained in:
Soybean 2021-11-18 21:57:20 +08:00
parent 6940f37697
commit 1c5fdca596
6 changed files with 34 additions and 7 deletions

View File

@ -8,6 +8,9 @@
border-1px border-[#e5e7eb]
dark:border-[#ffffff3d]
rounded-2px
transition-border-color
duration-300
ease-in-out
cursor-pointer
"
:class="[closable ? 'pr-6px' : 'pr-14px']"

View File

@ -12,11 +12,23 @@
</clipPath>
</defs>
<svg width="52%" height="100%">
<use xlink:href="#geometry-left" width="214" height="36" :fill="fill"></use>
<use
xlink:href="#geometry-left"
width="214"
height="36"
:fill="fill"
class="transition-fill duration-300 ease-in-out"
></use>
</svg>
<g transform="scale(-1, 1)">
<svg width="52%" height="100%" x="-100%" y="0">
<use xlink:href="#geometry-right" width="214" height="36" :fill="fill"></use>
<use
xlink:href="#geometry-right"
width="214"
height="36"
:fill="fill"
class="transition-fill duration-300 ease-in-out"
></use>
</svg>
</g>
</svg>

View File

@ -1,5 +1,17 @@
<template>
<a href="/" class="flex-center nowrap-hidden bg-light dark:bg-dark cursor-pointer">
<a
href="/"
class="
flex-center
nowrap-hidden
bg-light
dark:bg-dark
transition-background-color
duration-300
ease-in-out
cursor-pointer
"
>
<system-logo class="w-32px h-32px" :color="theme.themeColor" />
<h2 v-show="showTitle" class="text-primary pl-8px text-16px font-bold">{{ title }}</h2>
</a>

View File

@ -1,5 +1,5 @@
<template>
<div class="multi-tab flex-center w-full pl-16px bg-light dark:bg-dark">
<div class="multi-tab flex-center w-full pl-16px">
<div class="flex-1-hidden h-full">
<better-scroll :options="{ scrollX: true, scrollY: false, click: true }">
<multi-tab />

View File

@ -1,6 +1,6 @@
import type { CustomRoute } from '@/interface';
import { EnumRoutePath, EnumRouteTitle } from '@/enum';
import { BasicLayout } from '@/layouts';
import { BaseLayout } from '@/layouts';
import { ROUTE_NAME_MAP, setRouterCacheName } from '@/utils';
import { ROUTE_HOME } from '../routes';
import DashboardWorkbench from '@/views/dashboard/workbench/index.vue';
@ -10,7 +10,7 @@ setRouterCacheName(DashboardWorkbench, ROUTE_NAME_MAP.get('dashboard_workbench')
const DASHBOARD: CustomRoute = {
name: ROUTE_NAME_MAP.get('dashboard'),
path: EnumRoutePath.dashboard,
component: BasicLayout,
component: BaseLayout,
redirect: { name: ROUTE_NAME_MAP.get('dashboard_analysis') },
meta: {
title: EnumRouteTitle.dashboard,

View File

@ -55,7 +55,7 @@ export default defineConfig({
dark: '#18181c',
'deep-dark': '#101014'
},
transitionProperty: ['width', 'height', 'background', 'background-color']
transitionProperty: ['width', 'height', 'background', 'background-color', 'border-color', 'fill']
}
},
variants: {},