]> git.proxmox.com Git - pve-manager.git/commitdiff
ui: nav: move bg-color override to CSS class
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 23 May 2021 16:04:13 +0000 (18:04 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 23 May 2021 16:04:16 +0000 (18:04 +0200)
colors overrides really must not happen inline...

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
www/css/ext6-pve.css
www/manager6/panel/ConfigPanel.js

index 80b726f95ad4d1e0123d16c6d700294c8d5536de..acf39c8cf0ece1cf7be4723e2114c65e34b38835 100644 (file)
@@ -619,6 +619,10 @@ table.osds td:first-of-type {
     background-image: none;
 }
 
+.pve-toolbar-bg {
+    background-color: #f5f5f5;
+}
+
 .x-fa {
     diplay: inline-block;
     font: normal normal normal 14px/1 FontAwesome;
index 788615aa973bab7efcde64bcedb4aa5f2c52adc4..2ab1ae4b3f4361ecef0353292479bc96d5734db1 100644 (file)
@@ -54,10 +54,10 @@ Ext.define('PVE.panel.Config', {
        overflowHandler: 'scroller',
        dock: 'left',
        style: {
-           backgroundColor: '#f5f5f5',
            padding: 0,
            margin: 0,
        },
+       cls: 'pve-toolbar-bg',
        items: {
            xtype: 'treelist',
            itemId: 'menu',
@@ -78,16 +78,12 @@ Ext.define('PVE.panel.Config', {
                    var olditem = treelist.getSelection();
                    var newitem = info.node;
 
-                   // when clicking on the expand arrow,
-                   // we don't select items, but still want
-                   // the original behaviour
+                   // when clicking on the expand arrow, we don't select items, but still want the original behaviour
                    if (info.select === false) {
                        return;
                    }
 
-                   // if you click on a different item which is open,
-                   // leave it open
-                   // else toggle the clicked item
+                   // click on a different, open item then leave it open, else toggle the clicked item
                    if (olditem.data.id !== newitem.data.id &&
                        newitem.data.expanded === true) {
                        info.toggle = false;