Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
templates: initial semantic-ui integration
- Loading branch information
1 parent
123b3db
commit 591d877
Showing
8 changed files
with
69 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
/* | ||
* This file is part of Invenio. | ||
* Copyright (C) 2016-2018 CERN. | ||
* Copyright (C) 2016 TIND. | ||
* | ||
* Invenio is free software; you can redistribute it and/or modify it | ||
* under the terms of the MIT License; see LICENSE file for more details. | ||
*/ | ||
|
||
import * as $ from "jquery/dist/jquery"; | ||
|
||
$(document).ready(function() { | ||
$("#lang-code").on("change", function() { | ||
$("#language-code-form").submit(); | ||
}); | ||
}); |
This file was deleted.
Oops, something went wrong.
26 changes: 0 additions & 26 deletions
26
invenio_i18n/static/js/invenio_i18n/angularLangSelector.js
This file was deleted.
Oops, something went wrong.
24 changes: 24 additions & 0 deletions
24
invenio_i18n/templates/semantic-ui/invenio_i18n/macros/language_selector.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{# -*- coding: utf-8 -*- | ||
|
||
This file is part of Invenio. | ||
Copyright (C) 2015-2018 CERN. | ||
Copyright (C) 2016 TIND. | ||
|
||
Invenio is free software; you can redistribute it and/or modify it | ||
under the terms of the MIT License; see LICENSE file for more details. | ||
#} | ||
|
||
{% macro language_selector_dropdown() %} | ||
<form id="language-code-form" class="lang-select" | ||
action="{{ url_for('invenio_i18n.set_lang')}}" | ||
method="POST"> | ||
<div> | ||
<label>{{ _('Language:') }}</label> | ||
<select id="lang-code" name="lang_code"> | ||
{% for l in current_i18n.get_locales() %} | ||
<option {% if current_i18n.language == l.language %}selected {% endif %}value="{{ l.language }}">{{ l.get_display_name() }}</option> | ||
{% endfor %} | ||
</select> | ||
</div> | ||
</form> | ||
{% endmacro %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters