[pbs-devel] [PATCH proxmox-backup v2 2/4] docs: add Toolkit.js to prune simulator
Dominik Csapak
d.csapak at proxmox.com
Fri Jun 4 14:35:28 CEST 2021
from proxmox-widget-toolkit-dev and not as normal dependency,
else we would have to ship widget-toolkit on the wiki
Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
debian/control | 1 +
debian/debcargo.toml | 1 +
docs/Makefile | 8 ++++++++
.../{prune-simulator.js => prune-simulator_source.js} | 6 ++----
4 files changed, 12 insertions(+), 4 deletions(-)
rename docs/prune-simulator/{prune-simulator.js => prune-simulator_source.js} (99%)
diff --git a/debian/control b/debian/control
index 5bf595b4..f0eaea95 100644
--- a/debian/control
+++ b/debian/control
@@ -96,6 +96,7 @@ Build-Depends: debhelper (>= 11),
graphviz <!nodoc>,
latexmk <!nodoc>,
patchelf,
+ proxmox-widget-toolkit-dev <!nodoc>,
pve-eslint (>= 7.18.0-1),
python3-docutils,
python3-pygments,
diff --git a/debian/debcargo.toml b/debian/debcargo.toml
index da1a90a4..2b8ec883 100644
--- a/debian/debcargo.toml
+++ b/debian/debcargo.toml
@@ -17,6 +17,7 @@ build_depends = [
"graphviz <!nodoc>",
"latexmk <!nodoc>",
"patchelf",
+ "proxmox-widget-toolkit-dev <!nodoc>",
"pve-eslint (>= 7.18.0-1)",
"python3-docutils",
"python3-pygments",
diff --git a/docs/Makefile b/docs/Makefile
index 722c0c3e..a416ce1f 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -46,6 +46,10 @@ PRUNE_SIMULATOR_FILES := \
prune-simulator/clear-trigger.png \
prune-simulator/prune-simulator.js
+PRUNE_SIMULATOR_JS_SOURCE := \
+ /usr/share/javascript/proxmox-widget-toolkit-dev/Toolkit.js \
+ prune-simulator/prune-simulator_source.js
+
LTO_BARCODE_FILES := \
lto-barcode/index.html \
lto-barcode/code39.js \
@@ -199,6 +203,10 @@ api-viewer/apidata.js: ${COMPILEDIR}/docgen
api-viewer/apidoc.js: api-viewer/apidata.js api-viewer/PBSAPI.js
cat api-viewer/apidata.js api-viewer/PBSAPI.js >$@
+prune-simulator/prune-simulator.js: ${PRUNE_SIMULATOR_JS_SOURCE}
+ cat ${PRUNE_SIMULATOR_JS_SOURCE} >$@.tmp
+ mv $@.tmp $@
+
.PHONY: html
html: ${GENERATED_SYNOPSIS} images/proxmox-logo.svg custom.css conf.py ${PRUNE_SIMULATOR_FILES} ${LTO_BARCODE_FILES} ${API_VIEWER_SOURCES}
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
diff --git a/docs/prune-simulator/prune-simulator.js b/docs/prune-simulator/prune-simulator_source.js
similarity index 99%
rename from docs/prune-simulator/prune-simulator.js
rename to docs/prune-simulator/prune-simulator_source.js
index f1119f89..0964178c 100644
--- a/docs/prune-simulator/prune-simulator.js
+++ b/docs/prune-simulator/prune-simulator_source.js
@@ -1,7 +1,5 @@
-// FIXME: HACK! Makes scrolling in number spinner work again. fixed in ExtJS >= 6.1
-if (Ext.isFirefox) {
- Ext.$eventNameMap.DOMMouseScroll = 'DOMMouseScroll';
-}
+// for Toolkit.js
+function gettxt(val) { return val; };
Ext.onReady(function() {
const NOW = new Date();
--
2.20.1
More information about the pbs-devel
mailing list