]> git.proxmox.com Git - pmg-docs.git/commitdiff
api-viewer: use our extjs package instead of the cloudflare cdn
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Sat, 17 Aug 2019 10:48:21 +0000 (12:48 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sat, 17 Aug 2019 10:48:25 +0000 (12:48 +0200)
The loading of an external hosted ExtJS is from a time where we did
not have a extra ExtJS package as it still was in the pve-manager
one, which was not desired to be installed on a non-pmg machine.
Add a dependency on libjs-extjs and a link from api-viewer/extjs to
the installation directory of the ExtJS package, this allows to reuse
ExtJS on PMG node hosted docs and on the hosted docs from proxmox.com
at the same time.

Adapted from the Proxmox VE version[0] of this change.

[0]: https://git.proxmox.com/?p=pve-docs.git;a=commitdiff;h=e56030c4d7c3bd0de1ebc109d528fb6b7bef05a3

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
api-viewer/extjs [new symlink]
api-viewer/index.html
debian/control
debian/pmg-docs.links [new file with mode: 0644]

diff --git a/api-viewer/extjs b/api-viewer/extjs
new file mode 120000 (symlink)
index 0000000..b71ec6e
--- /dev/null
@@ -0,0 +1 @@
+/usr/share/javascript/extjs
\ No newline at end of file
index 97ed69e4de673b96f7f7a0008f58500fcacc6e9b..85284208f16a33cae9160be36754da9ad6c391d2 100644 (file)
@@ -5,8 +5,8 @@
     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
     <title>Proxmox VE API Documentation</title>
 
-    <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/extjs/6.0.1/classic/theme-crisp-touch/resources/theme-crisp-touch-all.css">
-   <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/extjs/6.0.1/ext-all-debug.js"></script>   
+    <link rel="stylesheet" type="text/css" href="extjs/theme-crisp/resources/theme-crisp-all.css">
+    <script type="text/javascript" src="extjs/ext-all.js"></script>
     <script type="text/javascript" src="apidoc.js"></script>
 </head>
 <body></body>
index 7ec1794143ae17badc1f56b83d6d1e7ab8a1a9cb..8d2ccde7e1e9d9b5d51936753ac8e7292d033da9 100644 (file)
@@ -23,6 +23,7 @@ Description: Proxmox Mail Gateway Documentation helpers
 
 Package: pmg-docs
 Section: doc
+Depends: libjs-extjs
 Architecture: all
 Description: Proxmox Mail Gateway Documentation
  This package contains the Proxmox Mail Gateway documentation files.
diff --git a/debian/pmg-docs.links b/debian/pmg-docs.links
new file mode 100644 (file)
index 0000000..6964af5
--- /dev/null
@@ -0,0 +1 @@
+/usr/share/javascript/extjs /usr/share/pmg-docs/api-viewer/extjs