Web demo crashes upon selecting "Custom HTML" interface

Steps to reproduce:

I'm not sure what the expected behavior of this is, but the demo currently crashes and will not recover upon selecting a different INTERFACE from the drop down:

The demo is currently at version 1.9.0 at the time of writing.
However, it suffices to reload the page to restore normal behavior.

Thanks, looks like this was a problem with the new site setup / demo server! Fixed it and the HTML example should now work as expected again :slightly_smiling_face:

This demo is very interesting :clap:

Is the code (js, html, recipe.py) published?

I want to change it to add a user interface language selection

Glad you like the demo :blush:

The live demo is just a demo and it doesn't actually run a recipe – it just serves static content from custom, pre-defined API endpoints. It also adds the dropdowns that just discard everything and reload the app, which is nice for a demo, but doesn't really make much sense in a "real world" application. I'm explaining a bit more about this here:

The UI language is typically set in the config on startup so there's not really a built-in way to change it at runtime, although it could be possible. (I haven't tried this yet, but one option would be to update the config of the current annotation task to overwrite it on a per-task basis – like: window.prodigy.update({ config: { ui_lang: 'fr' }}). But now sure how that behaves, it might switch back when the next task is loaded.)

1 Like