]> git.proxmox.com Git - pve-docs.git/commitdiff
api-viewer: fine-tune RAW return type showing
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 10 Dec 2019 13:51:53 +0000 (14:51 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 10 Dec 2019 13:51:53 +0000 (14:51 +0100)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
api-viewer/PVEAPI.js

index dadc45b40774f9ef4c3fc55e4099cb95c9a0a05a..d0da407d324238d9c748abca97175c9896642ac8 100644 (file)
@@ -241,8 +241,7 @@ Ext.onReady(function() {
                    }
 
                    var rawSection = Ext.create('Ext.panel.Panel', {
-                       title: 'RAW ' + rtype,
-                       bodyPadding: 10,
+                       bodyPadding: '0px 10px 10px 10px',
                        html: returnhtml,
                        hidden: true
                    });
@@ -286,12 +285,13 @@ Ext.onReady(function() {
                            flex: 6
                        }
                    ],
-                   tbar: [
+                   bbar: [
                        {
                            xtype: 'button',
-                           text: 'Toggle RAW',
-                           handler: function() {
+                           text: 'Show RAW',
+                           handler: function(btn) {
                                rawSection.setVisible(!rawSection.isVisible());
+                               btn.setText(rawSection.isVisible() ? 'Hide RAW' : 'Show RAW');
                            }}
                    ]
                });