mirror of
https://github.com/minetest/contentdb.git
synced 2025-01-10 23:17:37 +01:00
Improve card and user profile formatting
This commit is contained in:
parent
5dcff01436
commit
09a201759b
@ -3,6 +3,10 @@
|
||||
@import "packagegrid.scss";
|
||||
@import "comments.scss";
|
||||
|
||||
.dropdown-menu {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.dropdown:hover .dropdown-menu {
|
||||
display: block;
|
||||
}
|
||||
@ -21,6 +25,10 @@
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.card .table {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.btn-download {
|
||||
color: #fff;
|
||||
background-color: #00b05c;
|
||||
|
@ -1,5 +1,5 @@
|
||||
{% macro render_topics_table(topics, show_author=True) -%}
|
||||
<table>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<th>Id</th>
|
||||
<th></th>
|
||||
|
@ -146,7 +146,6 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% 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 %}
|
||||
@ -155,11 +154,13 @@
|
||||
{% set package_warning="Non-free media." %}
|
||||
{% endif %}
|
||||
{% if package_warning %}
|
||||
<div class="card-body">
|
||||
<div class="alert alert-danger">
|
||||
<b>Warning:</b> {{ package_warning }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
<table>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>Name</td>
|
||||
<td>{{ package.name }}</td>
|
||||
@ -216,7 +217,6 @@
|
||||
</td>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% if package.type == package.type.MOD %}
|
||||
<div class="card my-4">
|
||||
|
@ -7,17 +7,19 @@
|
||||
{% block content %}
|
||||
|
||||
{% if not current_user.is_authenticated and user.rank == user.rank.NOT_JOINED and user.forums_username %}
|
||||
<div class="box box_grey alert alert-info">
|
||||
Is this you? Claim your account now!
|
||||
<div class="alert alert-info alert alert-info">
|
||||
<a class="float-right btn btn-default btn-sm"
|
||||
href="{{ url_for('user_claim_page', username=user.forums_username) }}">Claim</a>
|
||||
|
||||
<a class="alert_right button" href="{{ url_for('user_claim_page', username=user.forums_username) }}">Claim</a>
|
||||
Is this you? Claim your account now!
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="box box_grey">
|
||||
<h2>{{ user.display_name }}</h2>
|
||||
|
||||
<table class="box-body">
|
||||
<div class="row mb-3">
|
||||
<div class="col-sm-6">
|
||||
<div class="card">
|
||||
<h2 class="card-header">{{ user.display_name }}</h2>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>Rank:</td>
|
||||
<td>
|
||||
@ -64,15 +66,15 @@
|
||||
{% endif %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% if form %}
|
||||
{% from "macros/forms.html" import render_field, render_submit_field %}
|
||||
<div class="box box_grey">
|
||||
<h2>Edit Details</h2>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="card">
|
||||
<h2 class="card-header">Edit Details</h2>
|
||||
<div class="card-body">
|
||||
<form action="" method="POST" class="form box-body" role="form">
|
||||
<div class="row">
|
||||
<div class="col-sm-6 col-md-5 col-lg-4">
|
||||
{{ form.hidden_tag() }}
|
||||
|
||||
{% if user.checkPerm(current_user, "CHANGE_DNAME") %}
|
||||
@ -89,28 +91,27 @@
|
||||
{% endif %}
|
||||
|
||||
{{ render_submit_field(form.submit, tabindex=280) }}
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% from "macros/packagegridtile.html" import render_pkggrid %}
|
||||
{{ render_pkggrid(packages, show_author=False) }}
|
||||
|
||||
{% if topics_to_add %}
|
||||
<div class="box box_grey">
|
||||
<h2>Unadded Packages</h2>
|
||||
<div class="card mt-3">
|
||||
<h2 class="card-header">Unadded Packages</h2>
|
||||
|
||||
<div class="box-body">
|
||||
<p>
|
||||
<p class="card-body">
|
||||
List of your forum topics which do not have a matching package.
|
||||
</p>
|
||||
|
||||
{% from "macros/topics.html" import render_topics_table %}
|
||||
{{ render_topics_table(topics_to_add, show_author=False) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
||||
|
Loading…
Reference in New Issue
Block a user