From 4df7bf439928f43c7453880d30d79036002e96c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B0=95=EC=84=9D=20=EC=B5=9C?= Date: Fri, 2 Sep 2022 18:32:55 +0900 Subject: [PATCH] =?UTF-8?q?=EC=A2=8C=20=EB=A9=94=EB=89=B4=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=B6=94=EA=B0=80.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/static/css/common.css | 10 ++++++++ src/main/resources/static/js/common.js | 20 +++++++++++++++- .../templates/fragments/leftMenu.html | 24 ++++++++++++++++++- .../resources/templates/login/dashboard.html | 2 +- 4 files changed, 53 insertions(+), 3 deletions(-) diff --git a/src/main/resources/static/css/common.css b/src/main/resources/static/css/common.css index 34073393..6a1ee1b9 100644 --- a/src/main/resources/static/css/common.css +++ b/src/main/resources/static/css/common.css @@ -19,4 +19,14 @@ .activeTr{ --bs-bg-opacity: 0.25; background-color: rgba(var(--bs-success-rgb),var(--bs-bg-opacity))!important; +} + +.menuDiv{ + width: 250px; + position: absolute; + top: 0; + left: 180px; + z-index: 100; + border-left: 1px solid; + border-right: 1px solid; } \ No newline at end of file diff --git a/src/main/resources/static/js/common.js b/src/main/resources/static/js/common.js index 07f1e7db..25c3d83b 100644 --- a/src/main/resources/static/js/common.js +++ b/src/main/resources/static/js/common.js @@ -27,4 +27,22 @@ $(document).on('change', '#rowCnt', function (){ function searchFormSubmit(pageIndex){ $("#pageIndex").val(pageIndex); $("#searchBtn").click(); -} \ No newline at end of file +} + + +$(document).on('mouseenter', '.firstMenuLink', function (event){ + $(".secondMenu").hide(); + const targetMenu = $(this).parent().find(".secondMenu"); + targetMenu.show() + targetMenu.find("ul").css("padding-top",(event.clientY-20)+"px") +}) +$(document).on('mouseenter', '.secondMenuLink', function (event){ + $(".thirdMenu").hide(); + const targetMenu = $(this).parent().find(".thirdMenu"); + targetMenu.show() + targetMenu.find("ul").css("padding-top",(event.clientY-20)+"px") +}) +$(document).on('mouseleave', '.menuDiv', function (){ + $(".secondMenu").hide(); + $(".thirdMenu").hide(); +}) \ No newline at end of file diff --git a/src/main/resources/templates/fragments/leftMenu.html b/src/main/resources/templates/fragments/leftMenu.html index 9223d9bd..2493bfea 100644 --- a/src/main/resources/templates/fragments/leftMenu.html +++ b/src/main/resources/templates/fragments/leftMenu.html @@ -11,7 +11,29 @@
  • - + +
  • diff --git a/src/main/resources/templates/login/dashboard.html b/src/main/resources/templates/login/dashboard.html index 6df56c1d..d6b42f46 100644 --- a/src/main/resources/templates/login/dashboard.html +++ b/src/main/resources/templates/login/dashboard.html @@ -3,7 +3,7 @@ xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{layout/layout}"> - +