yjryu / UI_Layout star
류윤주 류윤주 01-15
240115 류윤주 form 모달 추가
@6ccdf33d20f7acd7626c5633fdc27113a0236dd3
client/resources/css/common.css
--- client/resources/css/common.css
+++ client/resources/css/common.css
@@ -133,6 +133,10 @@
     background-color: #aaa;
 }
 
+.close-btn{
+    color: #d6def6;
+}
+
 .blue-btn,
 .blue-border-btn:hover {
     background-color: #213f99;
client/resources/css/layout.css
--- client/resources/css/layout.css
+++ client/resources/css/layout.css
@@ -125,7 +125,7 @@
 }
 
 .top-menu>ul>li {
-    min-width: 161px;
+    min-width: 152px;
     text-align: center;
     position: relative;
 }
@@ -215,6 +215,6 @@
     }
 
     100% {
-        height: 240px;
+        height: 260px;
     }
 }
(파일 끝에 줄바꿈 문자 없음)
client/resources/css/reset.css
--- client/resources/css/reset.css
+++ client/resources/css/reset.css
@@ -126,6 +126,6 @@
 
 @media screen and (min-width:1356px) and (max-width: 1536px) {
 	html{
-        font-size: 9px;
+        font-size: 8.5px;
     }
 }
(파일 끝에 줄바꿈 문자 없음)
client/resources/css/style.css
--- client/resources/css/style.css
+++ client/resources/css/style.css
@@ -82,15 +82,23 @@
     color: #213f99;
 }
 
+.list-table.orange thead tr {
+    background-color: #f29600;
+    color: #fff;
+}
+
 .list-table tbody tr:nth-child(even) {
     background-color: #f4f6ff;
+}
+
+.list-table.orange tbody tr:nth-child(even) {
+    background-color: #fff2de;
 }
 
 .form-table th {
     color: #213f99;
     text-align: center;
 }
-
 
 
 .option-table th {
@@ -191,4 +199,114 @@
 .count-zone span{
     font-weight: 900;
     color: #213f99;
+}
+
+
+/* 모달 */
+.modal-wrapper {
+    background-color: rgba(0, 0, 0, 0.5);
+    position: fixed;
+    width: 100%;
+    height: 100%;
+    top: 0;
+    left: 0;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    z-index: 200;
+  }
+  
+  .modal-container {
+    background: #fff;
+    min-width: 500px;
+    width: 35%;
+    border-radius: 5px;
+    display: grid;
+    grid-template-rows: 0.1fr 1fr 0.1fr;
+    padding: 20px;
+    box-sizing: border-box;
+    max-height: 90%;
+    min-height: 500px;
+  }
+  
+  .modal-title {
+    width: 100%;
+    border-bottom: 1px solid #d4cccc;
+    padding: 10px 0;
+  }
+  
+  .modal-subtitle {
+    font-size: 1.4rem;
+    font-weight: 600;
+    margin-bottom: 15px;
+  }
+  
+  .modal-content-monthly {
+    width: 100%;
+    padding: 30px 0;
+    overflow-y: auto;
+  }
+
+
+
+  .modal-content-monthly::-webkit-scrollbar {
+    width: 10px;
+  }
+  .modal-content-monthly::-webkit-scrollbar-thumb {
+    background-color: #6b6b6b;
+    border-radius: 10px;
+    background-clip: padding-box;
+    border: 2px solid transparent;
+  }
+  .modal-content-monthly::-webkit-scrollbar-track {
+    background-color: #eee;
+    border-radius: 10px;
+    box-shadow: inset 0px 0px 5px white;
+  }
+  
+  .modal-end {
+    width: 100%;
+    padding: 15px 0;
+    border-top: 1px solid #eee;
+  }
+
+
+  /* 탭 */
+  .tab-nav {
+    border-top: 1px solid #eee;
+    border-bottom: 1px solid #eee;
+    padding: 10px 0;
+  }
+  .tab-nav li a{
+    display: block;
+    font-size: 1.3rem;
+    text-align: center;
+    border-right: 1px solid #eee;
+  }
+
+  .tab-nav li a.activeTab{
+    color: #213f99;
+    font-weight: 600;
+  }
+
+  .tab-nav li:last-child a{
+    border-right: 0;
+  }
+
+
+/* 라벨 css(상세 조회랑 다름) */
+.chekck-type{
+    display: none;
+}
+
+.chekcktype-label{
+    border-radius: 5px;
+    padding: 5px 10px;
+    background-color: #d6def6;
+    color: #213f99;
+}
+
+.chekck-type:checked + label{
+    background-color: #213f99;
+    color: #fff;
 }
(파일 끝에 줄바꿈 문자 없음)
client/views/layout/TopMenu.vue
--- client/views/layout/TopMenu.vue
+++ client/views/layout/TopMenu.vue
@@ -78,21 +78,22 @@
 
                     ],
                 },
-                // {
-                //     pathName: "템플릿",
-                //     subMenu: [
-                //         { path: "/searchbar.page", pathName: "서치바" },
-                //         { path: "/table.page", pathName: "테이블" },
-                //         { path: "/btnPosition.page", pathName: "버튼별 위치" },
-                //     ],
-                // },
-                // {
-                //     pathName: "레이아웃 템플릿",
-                //     subMenu: [
-                //         { path: "/vertical.page", pathName: "수직 레이아웃" },
-                //         { path: "/horizontal.page", pathName: "수평 레이아웃" },
-                //     ],
-                // },
+                {
+                    pathName: "템플릿",
+                    subMenu: [
+                        { path: "/searchbar.page", pathName: "서치바" },
+                        { path: "/table.page", pathName: "테이블" },
+                        { path: "/btnPosition.page", pathName: "버튼별 위치" },
+                        { path: "/formModal.page", pathName: "form modal" },
+                    ],
+                },
+                {
+                    pathName: "레이아웃 템플릿",
+                    subMenu: [
+                        { path: "/vertical.page", pathName: "수직 레이아웃" },
+                        { path: "/horizontal.page", pathName: "수평 레이아웃" },
+                    ],
+                },
             ],
             currentRoute: null,
             showSubmenu: false
client/views/pages/AppRouter.js
--- client/views/pages/AppRouter.js
+++ client/views/pages/AppRouter.js
@@ -13,6 +13,7 @@
 import BtnPosition from "../template/templateElement/BtnPosition.vue";
 import Horizontal from "../template/layoutTemplate/Horizontal.vue";
 import Vertical from "../template/layoutTemplate/Vertical.vue";
+import FormModal from "../template/templateElement/FormModal.vue"
 import Guide from "../template/guide/TemplateGuide.vue";
 
 const routes = [
@@ -31,6 +32,7 @@
   {path: "/btnPosition.page",name: "BtnPosition",component: BtnPosition,},
   {path: "/horizontal.page",name: "Horizontal",component: Horizontal,},
   {path: "/vertical.page",name: "Vertical",component: Vertical,},
+  {path: "/formModal.page",name: "FormModal",component: FormModal,},
   {path: "/guide.page",name: "Guide",component: Guide,},
 ];
 
 
client/views/template/templateElement/FormModal.vue (added)
+++ client/views/template/templateElement/FormModal.vue
@@ -0,0 +1,167 @@
+<template>
+    <div v-show="isModalOpen" class="modal-wrapper">
+        <div class="modal-container">
+            <div class="modal-title">
+                <div class="flex justify-between align-center">
+                    <h2>모달 제목</h2>
+                    <button class="close-btn">X</button>
+                </div>
+            </div>
+            <div class="modal-content-monthly" v-show="modalType == 'tab-modal'">
+                <ul class="tab-nav flex justify-between">
+                    <li @click="showTab('tab1')" class="flex50"><a href="#tab01"
+                            :class="{ activeTab: activeTab === 'tab1' }">탭정보1</a></li>
+                    <li @click="showTab('tab2')" class="flex50"><a href="#tab02"
+                            :class="{ activeTab: activeTab === 'tab2' }">탭정보2</a></li>
+                </ul>
+                <ul class="tab-content">
+                    <li id="tab01" v-show="activeTab === 'tab1'">
+                        <table class="form-table">
+                            <colgroup>
+                                <col style="width: 15%;" />
+                                <col style="width: 85%;" />
+                            </colgroup>
+                            <tbody>
+                                <tr>
+                                    <th>파일명</th>
+                                    <td></td>
+                                </tr>
+                                <tr>
+                                    <th>API URL</th>
+                                    <td></td>
+                                </tr>
+                                <tr>
+                                    <th>결과타입</th>
+                                    <td>
+                                        <input type="radio" name="result-type" id="json" class="chekck-type" checked>
+                                        <label for="json" class="chekcktype-label">
+                                            json
+                                        </label>
+                                        <input type="radio" name="result-type" id="xml" class="chekck-type">
+                                        <label for="xml" class="chekcktype-label">
+                                            xml
+                                        </label>
+                                    </td>
+                                </tr>
+                            </tbody>
+                        </table>
+                        <table class="list-table">
+                            <thead>
+                                <tr>
+                                    <th>No</th>
+                                    <th>key</th>
+                                    <th>value</th>
+                                    <th>예외</th>
+                                    <th>날짜</th>
+                                    <th>삭제</th>
+                                </tr>
+                            </thead>
+                            <tbody>
+                                <tr>
+                                    <td>1</td>
+                                    <td>04:00:00</td>
+                                    <td>접속성공</td>
+                                    <td>접속성공</td>
+                                    <td>접속성공</td>
+                                    <td>접속성공</td>
+                                </tr>
+                            </tbody>
+                        </table>
+                    </li>
+                    <li id="tab01" v-show="activeTab === 'tab1'"></li>
+                </ul>
+            </div>
+            <div class="modal-content-monthly" v-show="modalType == 'form-modal'">
+                <table class="form-table">
+                    <colgroup>
+                        <col style="width: 15%;" />
+                        <col style="width: 85%;" />
+                    </colgroup>
+                    <tbody>
+                        <tr>
+                            <th>제목</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>DBMS</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>호스트</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>PORT</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>DB명</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>접속ID</th>
+                            <td></td>
+                        </tr>
+                        <tr>
+                            <th>접속PW</th>
+                            <td></td>
+                        </tr>
+                    </tbody>
+                </table>
+                <div class="flex justify-end">
+                    <button class="blue-btn small-btn">접속 테스트</button>
+                </div>
+                <table class="list-table orange">
+                    <thead>
+                        <tr>
+                            <th>No</th>
+                            <th>접속시간</th>
+                            <th>접속결과</th>
+                        </tr>
+                    </thead>
+                    <tbody>
+                        <tr>
+                            <td>1</td>
+                            <td>04:00:00</td>
+                            <td>접속성공</td>
+                        </tr>
+                    </tbody>
+                </table>
+            </div>
+            <div class="modal-end flex justify-end">
+                <button v-show="modalType === 'form-modal'" class="orange-btn small-btn">접속</button>
+                <button v-show="modalType === 'tab-modal'" class="blue-btn small-btn">확인</button>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+
+export default {
+    data() {
+        return {
+            isModalOpen: true,
+            activeTab: 'tab1',
+            modalType: 'tab-modal'
+        }
+    },
+    methods: {
+        // 탭 변경
+        showTab: function (tabName) {
+            this.activeTab = tabName;
+        },
+    },
+    watch: {
+
+    },
+    computed: {
+
+    },
+    components: {
+    },
+    mounted() {
+        console.log('main mounted');
+    }
+}
+</script>(파일 끝에 줄바꿈 문자 없음)
Add a comment
List