2021-05-28 13:51:23 +00:00
|
|
|
{% if current_user.setting_dark_mode %}
|
|
|
|
<script src="{{ url_for('static', filename='js/darkreader.js') }}"></script>
|
|
|
|
<script>
|
|
|
|
DarkReader.enable({brightness: 150, contrast: 100, sepia: 0});
|
|
|
|
</script>
|
|
|
|
{% endif %}
|
|
|
|
<script src="{{ url_for('static', filename='js/jsonpatch.min.js') }}"></script>
|
|
|
|
<script src="{{ url_for('static', filename='js/list.min.js') }}"></script>
|
|
|
|
<script src="{{ url_for('static', filename='js/socket.io.min.js') }}"></script>
|
|
|
|
<script src="{{ url_for('static', filename='js/nopaque/main.js') }}"></script>
|
2021-07-16 08:51:39 +00:00
|
|
|
{% assets filters='rjsmin', output="js/nopaque/RessourceDisplays.min.bundle.js",
|
2021-05-28 13:51:23 +00:00
|
|
|
"js/nopaque/RessourceDisplays/RessourceDisplay.js",
|
|
|
|
"js/nopaque/RessourceDisplays/CorpusDisplay.js",
|
|
|
|
"js/nopaque/RessourceDisplays/JobDisplay.js" %}
|
|
|
|
<script src="{{ ASSET_URL }}"></script>
|
|
|
|
{% endassets %}
|
2021-07-16 08:51:39 +00:00
|
|
|
{% assets filters='rjsmin', output="js/nopaque/RessourceLists.min.bundle.js",
|
2021-05-28 13:51:23 +00:00
|
|
|
"js/nopaque/RessourceLists/RessourceList.js",
|
|
|
|
"js/nopaque/RessourceLists/CorpusList.js",
|
|
|
|
"js/nopaque/RessourceLists/CorpusFileList.js",
|
|
|
|
"js/nopaque/RessourceLists/JobList.js",
|
|
|
|
"js/nopaque/RessourceLists/JobInputList.js",
|
|
|
|
"js/nopaque/RessourceLists/JobResultList.js",
|
|
|
|
"js/nopaque/RessourceLists/QueryResultList.js",
|
|
|
|
"js/nopaque/RessourceLists/UserList.js" %}
|
|
|
|
<script src="{{ ASSET_URL }}"></script>
|
|
|
|
{% endassets %}
|
|
|
|
<script>
|
|
|
|
// Disable all option elements with no value
|
|
|
|
for (let optionElement of document.querySelectorAll('option[value=""]')) {optionElement.disabled = true;}
|
|
|
|
M.AutoInit();
|
|
|
|
M.CharacterCounter.init(document.querySelectorAll('input[data-length][type="email"], input[data-length][type="password"], input[data-length][type="text"], textarea[data-length]'));
|
|
|
|
M.Dropdown.init(document.querySelectorAll('#nav-more-dropdown-trigger'), {alignment: 'right', constrainWidth: false, coverTrigger: false});
|
|
|
|
nopaque.appClient = new AppClient({% if current_user.is_authenticated %}{{ current_user.id }}{% endif %});
|
|
|
|
nopaque.Forms.init();
|
|
|
|
for (let flashedMessage of {{ get_flashed_messages(with_categories=True)|tojson }}) {nopaque.appClient.flash(flashedMessage[1], flashedMessage[0]);}
|
|
|
|
</script>
|