diff --git a/swh/web/ui/templates/layout.html b/swh/web/ui/templates/layout.html index 3b9d6d2a..6e2f8502 100644 --- a/swh/web/ui/templates/layout.html +++ b/swh/web/ui/templates/layout.html @@ -1,38 +1,37 @@ {% block title %}{% endblock %} - The Software Heritage Archive + - +

{{ self.title() }}

{% with messages = get_flashed_messages(with_categories=true) %} {% if messages %}
{% for category, message in messages %} {% endfor %}
{% endif %} {% endwith %}
{% block content %}{% endblock %}
diff --git a/swh/web/ui/templates/upload_and_search.html b/swh/web/ui/templates/upload_and_search.html index a29f36c3..8d60b281 100644 --- a/swh/web/ui/templates/upload_and_search.html +++ b/swh/web/ui/templates/upload_and_search.html @@ -1,30 +1,98 @@ {% extends "layout.html" %} -{% block title %}Search or Upload/Hash/Search{% endblock %} +{% block title %}Search SWH{% endblock %} {% block content %} -
- Input some hash: -
+ + + + + +
+
- - or some file to hash: - + +
+
+ +
+
+
+ +
+ Drag and drop or click here to hash files and search for them. + Your files will NOT be uploaded, hashing is done locally. + Filesizes over 20Mb may be slow to process, use with care. +
+
+
+
+
+
- - {% if messages is not none %} + + {% if search_stats is not none and search_stats %} + + {% endif %} + {% if responses is not none and responses %} + + + + + + + {% for resp in responses %} + + + {% if resp['found'] %} + + + {% else %} + + + {% endif %} + + {% endfor %} +
File nameSHA1 checksumResult
{{ resp['filename'] }}{{ resp['sha1'] }}{{ resp['sha1'] }}
+ {% endif %} + {% if messages is not none and messages %} +
{% for message in messages %} -
-
{{ message | safe }}
- {% endfor %} +
+
{{ message | safe }}
+ {% endfor %} +
{% endif %} - + +
+
{% endblock %}