This viewer is a simple electron application (just use npm start to run)
which uses XSLT files to convert XML to HTML.
In the doc folder there is a documentation on Electron fundamentals and XSLT details.
Set up one time with
npm install @vue/cli-service
npm install electron-builder
npm install electron-forge
npm update
then
npm start
Use CTRL+B to open the developer console.
npm start of course starts the application for local testing.
npm run start
should tell you if the software runs
npm run pack
will build a executable installer in releases.
If you do not run it from the start menu, but in a shell directly from
\Users\<your user name>\AppData\Local\Programs\quba_viewer\quba_viewer.exe
you will also see potential error output on the console.
Common issues include listing runtime dependencies as devDepencencies or not listing files to be included in the deployment in the build.files.filter (both issues can be fixed in the package.json).
Test ideas: build (pack) version opens and displays and has every file it needs if settings keep thr set language, files open, opens side by side, rects on tab click, reacts on show xml click, resolves codelists and opens dev console performs autoupdate, opens and closes example page
vue-18n-next is used. For unknown reasons there is a src/transaltion/de.json and a app/locales/de/translation.json ZUGFeRD#36
uninstall %AppData%/Roaming/Quba
The final update can then be deployed by Github users who have been granted access via a powershell using
$env:GH_TOKEN = '<private github access token>'
npm run publish
Actually only the Mac can build all three versions, there and on Linux use export GH_TOKEN=<your token>.
Also
cp doc/template.xml node_modules/app-builder-lib/templates/msi
Since there is an error in the build please use npm run build afterwards to also create the
autoupdate files latest.yml, latest-mac.yml and latest-linux.yml and upload them manually to
the release in Github.
To access the console (not only of the browser windows but also of main.js)
start Quba in a shell, e.g.
%AppData%\Local\Programs\quba_viewer\quba_viewer.exe
This will build the msi version.
To build the exe change package.json and remove the "msi" from "target" from "win", leaving
only the "nsis" target and npm run build again.
On the mac please change in package.json from --win to --mac --linux
To build linux change to --linux, on Linux run git clone, npm i and npm run build