UUDigitalHumanitieslab / parseport

Dutch sentence parser for Spindle + Æthel (and maybe others in the future).
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Feature/export #3

Closed XanderVertegaal closed 10 months ago

XanderVertegaal commented 10 months ago

Spindle parse results export to TeX, PDF and Overleaf

Addresses Issue #2

With this PR, the frontend gets three new buttons: "Export to LaTeX", "Export to PDF" and "Open in Overleaf".

For this PR to work, make sure you are running the spindle-server container (on the feature/export branch) and the latex-service container

Known issues / room for improvement

tijmenbaarda commented 10 months ago

This works very well!

When testing it as a user, I was a bit confused about where to click - it is a bit unusual that you can export something before seeing the result. I think it would be best if a user first clicks a parse button, sees the result as an image and then is given opportunity to export it. But that can come later of course!

There is still a problem with version.ts; a line to run node ./build/build-pre.js in frontend/package.json is missing. I tried copying the scripts section of frontend/package.json from another project and then it works fine (this is from jewish-historical-migration):

    "start": "yarn serve",
    "build": "ng build --deploy-url='/static/'",
    "watch": "ng build --watch",
    "test": "ng test --watch=true",
    "prebuild": "node ./build/build-pre.js",
    "build:en": "ng build  --deploy-url='/static/' --configuration=production-en",
    "i18n": "ng extract-i18n --output-path locale",
    "preserve": "yarn prebuild",
    "serve": "ng serve --proxy-config ../proxy.conf.json",
    "serve:en": "ng serve --proxy-config ../proxy.conf.json --configuration=en",
    "stop": "lsof -t -i tcp:4200 | xargs kill -9 || echo \"not running\"",
    "pretest": "yarn prebuild",
    "test-once": "ng test --watch=false"

I have no idea where the differences come from though.

In my view you can best merge this as soon as the tests are passing again, and then we can try to put it on the testing server, so that we can show it in action!