瀏覽代碼

Added more UI elements

aroz 1 年之前
父節點
當前提交
6034dd0bb1
共有 1 個文件被更改,包括 64 次插入9 次删除
  1. 64 9
      web/SystemAO/disk/raid/index.html

+ 64 - 9
web/SystemAO/disk/raid/index.html

@@ -44,6 +44,16 @@
                 background-color: #0d79ea !important;
             }
 
+            .raidVol{
+                cursor: pointer;
+            }
+            .raidVol:hover{
+                background-color: rgb(240, 240, 240);
+            }
+            .raidVol.active{
+                background-color: rgb(240, 240, 240);
+            }
+
             .healthIcon{
                 position: absolute;
                 left: 35px;
@@ -56,11 +66,30 @@
                 margin-right: 0 !important;
             }
 
+            /* Danger zone css */
+            .dangerzone{
+                border: 1px solid #dedede;
+                border-radius: 0.6em;
+                overflow: hidden;
+                padding-bottom: 1em;
+            }
+            .dangerzone .header{
+                color:white;
+                padding: 1em;
+                background-color: #cc3d3a;
+                margin-bottom: 1em;
+                font-weight: bolder;
+            }
+
+            .dangerzone summary{
+                cursor: pointer;
+                user-select:  none;
+            }
+
         </style>
     </head>
     <body>
-        <div class="ui container">
-            <br>
+        <div class="ui container" style="margin-top: 1em;">
             <h1 class="ui header">
                 <span id="healthy"><i class="ui loading circle notch icon"></i> Loading</span>
                 <div class="sub header"><span id="totalVolume">0</span> RAID volumes Loaded</div>
@@ -106,14 +135,40 @@
     
                     </div>
                     <div class="ui divider"></div>
-                    <div style="width: 100%;" align="center">
-                        <button onclick="" class="circular basic ui button">
-                            <i class="orange unlink icon"></i> Unlink Array
-                        </button>
-                        <button onclick="" class="circular basic red ui button">
-                            <i class="red trash icon"></i> Remove & Wipe Array
-                        </button>
+                    <div class="dangerzone">
+                        <div class="header">
+                            <h4>Danger Zone</h4>
+                        </div>
+                        <table class="ui very basic compact celled table" style="padding-left: 1em; padding-right: 1em;">
+                            <tbody>
+                                <tr>
+                                <td>
+                                    <h4>Unlink RAID Volume</h4>
+                                    <p>Unmount and remove the RAID volume from runtime but keep the mdadm config file. <br>
+                                        The RAID volume will get remounted after system reboot. This is suitable for temporary manual maintenance.</p>
+                                </td>
+                                <td>
+                                    <button onclick="" class="circular basic ui button">
+                                        <i class="orange unlink icon"></i> Unlink Volume
+                                    </button>
+                                </td>
+                                </tr>
+                                <tr>
+                                <td>
+                                    <h4>Remove RAID Volume</h4>
+                                    <p>Remove the RAID volume from runtime AND the mdadm config file. This should only be done when you are trying to rebuild the RAID volume on a new machine. <br>
+                                        Data in the disks will not be wiped but a full backup is recommended before removing the RAID volume from this system.</p>
+                                </td>
+                                <td>
+                                    <button onclick="" class="circular basic red ui button">
+                                        <i class="red trash icon"></i> Remove Volume
+                                    </button>
+                                </td>
+                                </tr>
+                            </tbody>
+                        </table> 
                     </div>
+                    
                 </div>
             </div>
         <script>