mirror of https://github.com/zulip/zulip.git
team: Move contributors_list into page_params.
This sidesteps tricky escaping issues, and will make it easier to build a strict Content-Security-Policy. Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
This commit is contained in:
parent
7494f1600c
commit
fe7d814e8d
|
@ -1,6 +1,4 @@
|
|||
// Contributor list is baked into the /team's page template, so we can silent
|
||||
// eslint's error.
|
||||
/* global contributors_list */
|
||||
const contributors_list = page_params.contrib;
|
||||
|
||||
// `repos` are repositories to be shown as tabs, whereas `hidden_repos` are
|
||||
// repositories that should count towards the total but not have tabs.
|
||||
|
|
|
@ -5,10 +5,6 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block customhead %}
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<script>
|
||||
var contributors_list = {{ contrib|safe }};
|
||||
</script>
|
||||
{{ bundle('landing-page') }}
|
||||
{% endblock %}
|
||||
|
||||
|
|
|
@ -537,5 +537,10 @@ def team_view(request: HttpRequest) -> HttpResponse:
|
|||
return render(
|
||||
request,
|
||||
'zerver/team.html',
|
||||
context=data,
|
||||
context={
|
||||
'page_params': {
|
||||
'contrib': data['contrib'],
|
||||
},
|
||||
'date': data['date'],
|
||||
},
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue