fix: Replace deprecated bootstrap CSS classes with 5.3 ones (#6166)
* fix: Replace deprecated bootstrap CSS classes with 5.3 ones * Fix test * Remove debug print
This commit is contained in:
parent
53be2c3793
commit
aa955f0e9b
|
@ -856,6 +856,7 @@ def badgeify(blob):
|
|||
(r"has issues", "warning", "exclamation-lg"),
|
||||
(r"assigned", "info", "person-plus-fill"),
|
||||
(r"will not review|overtaken by events|withdrawn", "secondary", "dash-lg"),
|
||||
(r"no response", "warning", "question-lg"),
|
||||
]
|
||||
text = str(blob)
|
||||
|
||||
|
@ -868,7 +869,7 @@ def badgeify(blob):
|
|||
|
||||
return mark_safe(
|
||||
f"""
|
||||
<span class="badge rounded-pill text-bg-{color}">
|
||||
<span class="badge rounded-pill text-bg-{color} text-wrap">
|
||||
<i class="bi bi-{icon}"></i> {text.capitalize()}
|
||||
</span>
|
||||
"""
|
||||
|
|
|
@ -236,7 +236,7 @@ class ReviewTests(TestCase):
|
|||
r = self.client.get(url)
|
||||
self.assertEqual(r.status_code, 200)
|
||||
# We should see the new document with status of no response
|
||||
self.assertContains(r, "No Response")
|
||||
self.assertContains(r, "No response")
|
||||
self.assertContains(r, review_req1.doc.name)
|
||||
self.assertContains(r, review_req2.doc.name)
|
||||
# None of the reviews should be completed this time,
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
data-group-menu-data-url="{% url 'ietf.group.views.group_menu_data' %}">
|
||||
{% analytical_body_top %}
|
||||
<a class="visually-hidden visually-hidden-focusable" href="#content">Skip to main content</a>
|
||||
<nav class="navbar navbar-expand-lg fixed-top {% if server_mode and server_mode != "production" %}bg-danger-subtle{% else %}bg-secondary{% endif %}">
|
||||
<nav class="navbar navbar-expand-lg fixed-top {% if server_mode and server_mode != "production" %}bg-danger-subtle{% else %}bg-secondary-subtle{% endif %}">
|
||||
<div class="container-fluid">
|
||||
<a class="navbar-brand" href="/">
|
||||
{% include "logo.html" with org="ietf" classes="me-2" nor=True only %}
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
<td class="edit"></td>
|
||||
<td>
|
||||
<span id="statement-type">{% if doc.get_state.slug != "active" %}{{doc.get_state.name}} {% endif %}{% if doc.group %}{{doc.group.acronym|upper}} {%endif%}Statement</span>
|
||||
{% if snapshot %}<span class="badge rounded-pill bg-warning">Snapshot</span>{% endif %}
|
||||
{% if snapshot %}<span class="badge rounded-pill text-bg-warning">Snapshot</span>{% endif %}
|
||||
{% if replaced_by %}<div>Replaced by {{ replaced_by|urlize_related_source_list:False|join:", " }}</div>{% endif %}
|
||||
{% if replaces %}<div>Replaces {{ replaces|urlize_related_target_list:False|join:", " }}</div>{% endif %}
|
||||
</td>
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
</thead>
|
||||
{% for state, docs in grouped_docs %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="5">{{ state.name }}</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
<a class="text-body-secondary"
|
||||
href="{% url 'ietf.doc.views_review.review_request' review_assignment.review_request.doc.name review_assignment.review_request.pk %}">
|
||||
{{ review_assignment.review_request.team.acronym|upper }} {{ review_assignment.review_request.type.name }} Review due {{ review_assignment.review_request.deadline|date:"Y-m-d" }}</a>
|
||||
<span class="badge rounded-pill ms-1 bg-secondary">
|
||||
<span class="badge rounded-pill text-bg-secondary ms-1">
|
||||
Incomplete
|
||||
</span>
|
||||
{% endif %}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
href="{% url 'ietf.doc.views_review.review_request' review_request.doc.name review_request.pk %}">
|
||||
{{ review_request.team.acronym|upper }} {{ review_request.type.name }} Review due {{ review_request.deadline|date:"Y-m-d" }}
|
||||
</a>
|
||||
<span class="badge rounded-pill ms-1 bg-secondary">
|
||||
<span class="badge rounded-pill text-bg-secondary ms-1">
|
||||
Requested
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
|
@ -46,7 +46,7 @@
|
|||
{% regroup docs by search_heading as grouped_docs %}
|
||||
{% for doc_group in grouped_docs %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<td></td>
|
||||
<th scope="col" colspan="{{ meta.headers|length|add:"-1" }}">
|
||||
{{ doc_group.grouper|plural:doc_group.list }} ({{ doc_group.list|length }} {{"hit"|plural:doc_group.list }})
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
</thead>
|
||||
{% for state in state_groups %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="2">{{ state.grouper }}</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
{% for grouptype in grouped_groups %}
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="col" colspan="2" class="bg-info">
|
||||
<th scope="col" colspan="2" class="table-info">
|
||||
Active {% firstof grouptype.grouper.verbose_name grouptype.grouper.name 'Top-level Administration' %}
|
||||
</th>
|
||||
</tr>
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
{% regroup iabgroups by type as grouped_groups %}
|
||||
{% for grouptype in grouped_groups %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle"><th scope="col" colspan="3">
|
||||
<tr class="table-info"><th scope="col" colspan="3">
|
||||
{% firstof grouptype.grouper.verbose_name grouptype.grouper.name %}{{ grouptype.list|pluralize }}
|
||||
</th></tr>
|
||||
</tbody>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
{% for grouptype in grouped_groups %}
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="col" colspan="2" class="bg-info">
|
||||
<th scope="col" colspan="2" class="table-info">
|
||||
Active {% firstof grouptype.grouper.verbose_name grouptype.grouper.name 'Top-level Organization' %} Groups
|
||||
</th>
|
||||
</tr>
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle" id="unassigned-review-requests">
|
||||
<tr class="table-info" id="unassigned-review-requests">
|
||||
<th scope="col" colspan="6">Unassigned review requests</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
@ -79,7 +79,7 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle" id="open_review_assignments">
|
||||
<tr class="table-info" id="open_review_assignments">
|
||||
<th scope="col" colspan="7">Open review requests</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
@ -147,7 +147,7 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="6">
|
||||
Closed review requests
|
||||
</th>
|
||||
|
@ -211,7 +211,7 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="8">
|
||||
Closed review assignments
|
||||
</th>
|
||||
|
|
|
@ -98,7 +98,7 @@
|
|||
<a href="{% url 'ietf.doc.views_review.review_request' name=doc_name request_id=req_pk %}">{{ deadline|date|split:"-"|join:"-<wbr>" }}</a>
|
||||
</div>
|
||||
<div class="col-md-2 me-1">
|
||||
<span class="badge rounded-pill bg-{% if state.slug == 'completed' or state.slug == 'part-completed' %}success{% elif state.slug == 'no-response' %}danger{% elif state.slug == 'overtaken' %}warning{% elif state.slug == 'requested' or state.slug == 'accepted' %}primary{% else %}secondary{% endif %} text-wrap">{{ state.name }}</span>
|
||||
{{ state.name|badgeify }}
|
||||
</div>
|
||||
<div class="col-md-1 me-1 text-end d-none d-lg-block">
|
||||
{% if assignment_to_closure_days != None %}
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
{% for doc in docs %}
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="col" class="bg-info" colspan="3">
|
||||
<th scope="col" class="table-info" colspan="3">
|
||||
Results for {{ doc.name|prettystdname|urlize_ietf_docs }} ("{{ doc.document.title }}"){% if not forloop.first %}{% if doc.related %}, which was {{ doc.relation|lower }} {{ doc.related.source|prettystdname|urlize_ietf_docs }} ("{{ doc.related.source.title }}"){% endif %}{% endif %}
|
||||
</th>
|
||||
</tr>
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
{% for alias in docs %}
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="col" class="bg-info" colspan="3">
|
||||
<th scope="col" class="table-info" colspan="3">
|
||||
IPR that is related to {{ alias.name|prettystdname:""|urlize_ietf_docs }} ("{{ alias.document.title }}")
|
||||
{% if alias.related %}
|
||||
that was {{ alias.relation|lower }} {{ alias.related.source.name|prettystdname:""|urlize_ietf_docs }} ("{{ alias.related.source.title }}")
|
||||
|
|
|
@ -43,7 +43,7 @@
|
|||
{% endifchanged %}
|
||||
{% endif %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="3">
|
||||
{% block intro_prefix %}IPR that was submitted by "{{ q }}" and{% endblock %}
|
||||
{% block related %}
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
</thead>
|
||||
{% for alias in docs %}
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="col" colspan="3">
|
||||
IPR related to {{ alias.name|prettystdname|urlize_ietf_docs }} ("{{ alias.document.title }}")
|
||||
{% if alias.related %}
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
</p>
|
||||
<table class="table table-sm table-striped">
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="colgroup" colspan="2">Form buttons and resulting actions:</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
@ -85,7 +85,7 @@
|
|||
</p>
|
||||
<table class="table table-sm table-striped">
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="colgroup" colspan="2">Form buttons and resulting actions:</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
@ -104,7 +104,7 @@
|
|||
</tr>
|
||||
</tbody>
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="colgroup" colspan="2">
|
||||
When no metadata error is detected:
|
||||
</th>
|
||||
|
@ -145,7 +145,7 @@
|
|||
</p>
|
||||
<table class="table table-sm table-striped">
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="colgroup" colspan="2">
|
||||
Form buttons and resulting actions:
|
||||
</th>
|
||||
|
@ -186,7 +186,7 @@
|
|||
</p>
|
||||
<table class="table table-sm table-striped">
|
||||
<tbody>
|
||||
<tr class="bg-info-subtle">
|
||||
<tr class="table-info">
|
||||
<th scope="colgroup" colspan="2">
|
||||
Form buttons and resulting actions:
|
||||
</th>
|
||||
|
|
Loading…
Reference in a new issue