Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F8322664
content-display.html
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Subscribers
None
content-display.html
View Options
{% comment %}
Copyright (C) 2017-2018 The Software Heritage developers
See the AUTHORS file at the top-level directory of this distribution
License: GNU Affero General Public License version 3, or any later version
See top-level LICENSE file for more information
{% endcomment %}
{% load swh_templatetags %}
{% if snapshot_context and snapshot_context.is_empty %}
{% include "includes/empty-snapshot.html" %}
{% else %}
<
div
class
=
"card"
>
{% if swh_object_metadata.filename %}
<
div
class
=
"card-header bg-gray-light swh-heading-color"
>
{{ swh_object_metadata.filename }}
</
div
>
{% endif %}
<
div
class
=
"swh-content"
>
{% if content_size > max_content_size %}
Content is too large to be displayed (size is greater than {{ max_content_size|filesizeformat }}).
{% elif "inode/x-empty" == mimetype %}
<
i
>
File is empty
</
i
>
{% elif swh_object_metadata.filename and swh_object_metadata.filename|default:""|slice:"-5:" == "ipynb" %}
<
div
class
=
"swh-ipynb"
>
</
div
>
{% elif "text/" in mimetype %}
<
div
class
=
"highlightjs"
>
<
pre
><
code
class
=
"{{ language }}"
>
{{ content }}
</
code
></
pre
>
</
div
>
{% elif "image/" in mimetype and content %}
<
img
src
=
"data:{{ mimetype }};base64,{{ content }}"
/>
{% elif "application/pdf" == mimetype %}
<
div
class
=
"text-center"
>
<
div
class
=
"py-2"
>
<
button
class
=
"btn btn-default btn-sm"
id
=
"pdf-prev"
>
Previous
</
button
>
<
span
>
Page:
<
span
id
=
"pdf-page-num"
></
span
>
/
<
span
id
=
"pdf-page-count"
></
span
></
span
>
<
button
class
=
"btn btn-default btn-sm"
id
=
"pdf-next"
>
Next
</
button
>
</
div
>
<
canvas
id
=
"pdf-canvas"
></
canvas
>
</
div
>
{% elif content %}
Content with mime type {{ mimetype }} can not be displayed.
{% else %}
{% include "includes/http-error.html" %}
{% endif %}
</
div
>
</
div
>
<
script
>
{
%
if
"application/pdf"
==
mimetype
%
}
swh
.
webapp
.
renderPdf
({{
top_right_link
.
url
|
jsonify
}});
{
%
elif
swh_object_metadata
.
filename
and
swh_object_metadata
.
filename
|
default
:
""
|
slice
:
"-5:"
==
"ipynb"
%
}
swh
.
webapp
.
renderNotebook
({{
top_right_link
.
url
|
jsonify
}},
'.swh-ipynb'
);
{
%
elif
content
%
}
swh
.
webapp
.
highlightCode
();
{
%
endif
%
}
</
script
>
{% endif %}
File Metadata
Details
Attached
Mime Type
text/html
Expires
Tue, Jun 3, 7:41 AM (4 d, 19 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3344253
Attached To
R65 Staging repository
Event Timeline
Log In to Comment