From 09ea0d62f13761ed8388e1d6a939e0bf37c96db3 Mon Sep 17 00:00:00 2001 From: Kamiya <58339640+kamiya10@users.noreply.github.com> Date: Sat, 22 Jul 2023 07:32:24 +0800 Subject: [PATCH] feat: fancy menu item indicator (#604) * feat: fancy menu item indicator * fix: light theme color --- html/src/app.scss | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/html/src/app.scss b/html/src/app.scss index fb14b243..2d3b3825 100644 --- a/html/src/app.scss +++ b/html/src/app.scss @@ -245,14 +245,24 @@ hr.x-vertical-divider { color: #000; } -.el-menu-item.is-active::before { - position: absolute; - top: 4px; - left: 1px; - width: 2px; - height: 48px; +.el-menu-item::before { content: ''; + position: absolute; + left: -4px; + top: 50%; + height: 36px; + width: 3px; + translate: 0 -50%; + border-radius: 4px; background: #303133; + transition: + background-color 0.4s, + left 0.2s; +} + +.el-menu-item.is-active::before { + left: 2px; + transition: left 0.2s cubic-bezier(0.175, 0.885, 0.32, 2.552); } .el-menu-item.notify::after {