{% extends "base.html" %} {% set query=package.name %} {% set release = package.get_download_release() %} {% set meta = package.get_translated() %} {% block title %} {{ meta.title }} {% endblock %} {% block description -%} {{ meta.short_desc }} {% endblock %} {% block headextra %} {% if package.get_thumb_url(3, True, "png") -%} {%- endif %} {% endblock %} {% block scriptextra %} {% if current_user.is_authenticated %} {% endif %} {% endblock %} {% macro render_license(license) %} {% if license.url %} {{ license.name }} {% else %} {{ license.name }} {% endif %} {% endmacro %} {% block download_btn %} {% if release %}
{{ _("Download") }} ({{ release.file_size }})
{% if release and (release.min_rel or release.max_rel) %} {% if release.min_rel and release.max_rel %} {{ _("Luanti %(min)s - %(max)s", min=release.min_rel.name, max=release.max_rel.name) }} {% elif release.min_rel %} {{ _("For Luanti %(min)s and above", min=release.min_rel.name) }} {% elif release.max_rel %} {{ _("Luanti %(max)s and below", max=release.max_rel.name) }} {% endif %} {% endif %}

{{ _("How do I install this?") }}

{% else %} {{ _("No downloads available") }} {% endif %} {% endblock %} {% block container %} {% if not package.license.is_foss and not package.media_license.is_foss and package.type != package.type.TXP %} {% set package_warning=_("Non-free code and media") %} {% elif not package.license.is_foss and package.type != package.type.TXP %} {% set package_warning=_("Non-free code") %} {% elif not package.media_license.is_foss %} {% set package_warning=_("Non-free media") %} {% endif %}
{% if not package.approved %}
{% from "macros/package_approval.html" import render_banners %} {{ render_banners(package, current_user, validation) }} {% if review_thread and review_thread.check_perm(current_user, "SEE_THREAD") %}

{% if review_thread.private %}🔒{% endif %} {{ review_thread.title }}

{% if review_thread.private %}

{{ _("This thread is only visible to its creator, package maintainers, users of Approver rank or above, and @mentioned users.") }}

{% endif %} {% from "macros/threads.html" import render_thread %} {{ render_thread(review_thread, current_user, form=False) }} {% endif %}
{% endif %} {% set cover_image = package.get_cover_image_url() %}
{% if package.check_perm(current_user, "EDIT_PACKAGE") %} {{ _("Edit") }} {% endif %} {% if package.check_perm(current_user, "MAKE_RELEASE") %} {{ _("Release") }} {% endif %} {% if package.check_perm(current_user, "DELETE_PACKAGE") or package.check_perm(current_user, "UNAPPROVE_PACKAGE") %} {{ _("Remove") }} {% endif %}

{{ meta.title }}

{{ meta.short_desc }}

{% if package.dev_state.name == "LOOKING_FOR_MAINTAINER" or package.dev_state.name == "DEPRECATED" %} {{ package.dev_state.value }} {% endif %} {% if package_warning %} {{ package_warning }} {% endif %} {% for warning in package.content_warnings %} {{ warning.title }} {% endfor %} {% if package.dev_state.name == "WIP" %} {{ _("Work in Progress") }} {% endif %} {% for tag in package.tags %} {{ tag.get_translated().title }} {% endfor %}

{{ self.download_btn() }}
{% set screenshots = package.screenshots.all() %} {% if package.check_perm(current_user, "ADD_SCREENSHOTS") %} {{ _("Edit") }} {% endif %} {% if screenshots or package.check_perm(current_user, "ADD_SCREENSHOTS") or package.video_url %} {% if screenshots %} {% endif %} {% endif %} {% if meta.desc %}
{{ meta.desc | markdown }}
{% endif %}

{{ _("Reviews") }}

{% from "macros/reviews.html" import render_reviews, render_review_form, render_review_preview with context %} {% if package.state.name == "APPROVED" %} {% if current_user.is_authenticated %} {% if has_review %}

{{ _("Edit Review") }}

{% elif current_user in package.maintainers %}

{{ _("You can't review your own package.") }}

{% else %} {{ render_review_preview(package) }} {% endif %} {% else %} {{ render_review_preview(package) }} {% endif %} {% else %}

{{ _("Package needs to be approved before it can be reviewed.") }}

{% endif %} {% if current_user.is_authenticated and current_user.rank.at_least(current_user.rank.ADMIN) %} {{ _("Review Votes") }} {% endif %} {{ render_reviews(package.reviews, current_user) }} {% if packages_uses %}

{{ _("Used By") }}

{% from "macros/packagegridtile.html" import render_pkggrid %} {{ render_pkggrid(packages_uses) }} {% endif %} {% if package.type == package.type.GAME %}

{{ _("Content") }}

{{ _("View content for game") }} {% endif %}
{% endblock %}