Skip to content

Commit a6b77b9

Browse files
Merge branch 'main' into table-collapse-css
2 parents 1bccde0 + 2f9062b commit a6b77b9

File tree

6 files changed

+49
-73
lines changed

6 files changed

+49
-73
lines changed

.github/workflows/lint.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
name: Lint
22

3-
on: [push, pull_request, workflow_dispatch]
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
workflow_dispatch:
49

510
env:
611
FORCE_COLOR: 1

counts.py

Lines changed: 0 additions & 30 deletions
This file was deleted.

requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
gitpython
22
urllib3
33
potodo
4-
polib
54
jinja2
65
docutils
76
sphinx

src/style.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ a:hover {
7272
position: relative;
7373
}
7474

75-
.progress-bar-index {
75+
.progress-bar {
7676
display: inline-block;
7777
color: white;
7878
height: 100%;

templates/index.html.jinja

Lines changed: 40 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,49 @@
11
{% extends "base.html.jinja" %}
22

33
{% block main %}
4-
<div>
5-
<div class="row">
6-
{% for project in completion_progress | sort(attribute='completion') | reverse %}
7-
<div class="col-12 col-sm-6 col-md-4 d-flex">
8-
<div class="card shadow mb-3 w-100">
9-
<div class="card-body">
10-
<h3 class="card-title">{{ project.language.name }}</h3>
11-
<h5 class="card-subtitle mb-2 text-muted">{{ project.translated_name }}</h5>
12-
<p class="text-muted">Completion: <strong>{{ '{:.2f}%'.format(project.completion) }}</strong></p>
13-
<p class="text-muted">30-day progress: {{ '{:.2f}%'.format(project.change) }}</p>
14-
<p style="text-align: center;">
15-
{% if project.built %}
16-
<a href="https://docs.python.org/{{ project.language.code }}/3/" style="color: #1595fe;">View</a>
17-
18-
{% endif %}
19-
{% if project.contribution_link %}
20-
<a href="{{ project.contribution_link }}" style="color: #1595fe;">Contribute</a>
21-
{% elif project.uses_platform %}
22-
<a href="https://app.transifex.com/join/?o=python-doc&p=python-newest&t=opensource" style="color: #1595fe;">Contribute</a>
23-
{% else %}
24-
<a href="https://devguide.python.org/documentation/translations/translating/" style="color: #1595fe;">Contribute</a>
25-
{% endif %}
26-
</p>
27-
<div class="progress-bar-container">
28-
<div class="progress-bar-index" style="width: {{ project.completion }}%;
29-
{% if project.change %}
30-
background: linear-gradient(to left, #94cf96 {{ project.change * 100 / project.completion }}%, #4caf50 {{ project.change * 100 / project.completion }}%);
31-
{% else %}
32-
background-color: #4caf50;
33-
{% endif %}">
34-
</div>
35-
</div>
4+
<div>
5+
<div class="row">
6+
{% for project in completion_progress | sort(attribute='completion') | reverse %}
7+
<div class="col-12 col-sm-6 col-md-4 d-flex">
8+
<div class="card shadow mb-3 w-100">
9+
<div class="card-body">
10+
<h3 class="card-title">{{ project.language.name }}</h3>
11+
<h5 class="card-subtitle mb-2 text-muted">{{ project.translated_name }}</h5>
12+
<p class="text-muted">Completion: <strong>{{ '{:.2f}%'.format(project.completion) }}</strong></p>
13+
<p class="text-muted">30-day progress: {{ '{:.2f}%'.format(project.change) }}</p>
14+
15+
<p style="text-align: center;">
16+
{% if project.built %}
17+
<a href="https://docs.python.org/{{ project.language.code }}/3/" style="color: #1595fe;">View</a>
18+
19+
{% endif %}
20+
{% if project.contribution_link %}
21+
<a href="{{ project.contribution_link }}" style="color: #1595fe;">Contribute</a>
22+
{% elif project.uses_platform %}
23+
<a href="https://app.transifex.com/join/?o=python-doc&p=python-newest&t=opensource" style="color: #1595fe;">Contribute</a>
24+
{% else %}
25+
<a href="https://devguide.python.org/documentation/translations/translating/" style="color: #1595fe;">Contribute</a>
26+
{% endif %}
27+
</p>
28+
<div class="progress-bar-container">
29+
<div class="progress-bar" style="width: {{ project.completion }}%;
30+
{% if project.change %}
31+
background: linear-gradient(to left, #94cf96 {{ project.change * 100 / project.completion }}%, #4caf50 {{ project.change * 100 / project.completion }}%);
32+
{% else %}
33+
background-color: #4caf50;
34+
{% endif %}">
3635
</div>
3736
</div>
3837
</div>
39-
{% endfor %}
38+
</div>
4039
</div>
41-
</div>
40+
{% endfor %}
41+
</div>
42+
</div>
4243

43-
<p style="text-align: center;">
44-
Last updated {{ generation_time.strftime('on %A %-d %B %Y at %-H:%M:%S %Z') }} (in {{ duration // 60 }} minutes and {{ duration % 60 }} seconds).<br/>
45-
You can find the scripts used to generate this website <a href="https://github.com/python-docs-translations/dashboard/">on GitHub</a>.<br/>
46-
You can download the data on this page in <a href="https://raw.githubusercontent.com/python-docs-translations/dashboard/refs/heads/gh-pages/index.json">JSON format</a>.
47-
</p>
44+
<p style="text-align: center;">
45+
Last updated {{ generation_time.strftime('on %A %-d %B %Y at %-H:%M:%S %Z') }} (in {{ duration // 60 }} minutes and {{ duration % 60 }} seconds).<br/>
46+
You can find the scripts used to generate this website <a href="https://github.com/python-docs-translations/dashboard/">on GitHub</a>.<br/>
47+
You can download the data on this page in <a href="https://raw.githubusercontent.com/python-docs-translations/dashboard/refs/heads/gh-pages/index.json">JSON format</a>.
48+
</p>
4849
{% endblock %}

templates/metadata.html.jinja

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
{% endfor %}
3030
</tbody>
3131
</table>
32+
3233
<p>* number of Sphinx build process warnings</p>
33-
<p>Last updated at {{ generation_time.strftime('%A, %-d %B %Y, %-H:%M:%S %Z') }} (in {{ duration // 60 }}:{{ "{:02}".format(duration % 60) }} minutes).</p>
34+
<p>Last updated at {{ generation_time.strftime('%A, %-d %B %Y, %-H:%M:%S %Z') }} (in {{ duration // 60 }}:{{ "{:02}".format(duration % 60) }} minutes).</p>
3435
{% endblock %}

0 commit comments

Comments
 (0)