Skip to content

Commit 9e038d3

Browse files
committed
Bring back some additional js dependencies.
- Legacy-Id: 19707
1 parent a189b51 commit 9e038d3

32 files changed

Lines changed: 260 additions & 132 deletions

ietf/static/css/datepicker.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "~/node_modules/bootstrap-datepicker/dist/css/bootstrap-datepicker3.css";

ietf/static/js/datepicker.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
import "bootstrap-datepicker";
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
import "~/node_modules/highcharts/modules/exporting";
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import * as Highcharts from "~/node_modules/highcharts";
2+
3+
window.Highcharts = Highcharts;
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import * as Highcharts from "~/node_modules/highcharts/highstock";
2+
3+
window.Highcharts = Highcharts;
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
import "~/node_modules/highcharts/modules/offline-exporting";

ietf/static/js/stats.js

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
$(document).ready(function () {
2+
if (window.chartConf) {
3+
window.chartConf.credits = {
4+
enabled: false
5+
};
6+
window.chartConf.exporting = {
7+
fallbackToExportServer: false
8+
};
9+
10+
if (!window.chartConf.legend)
11+
window.chartConf.legend = {
12+
enabled: false
13+
};
14+
15+
var chart = Highcharts.chart('chart', window.chartConf);
16+
}
17+
18+
if (window.pieChartConf) {
19+
window.pieChartConf.credits = {
20+
enabled: false
21+
};
22+
var pieChart = Highcharts.chart('pie-chart', window.pieChartConf);
23+
}
24+
/*
25+
$(".popover-details").each(function () {
26+
var stdNameRegExp = new RegExp("^(rfc|bcp|fyi|std)[0-9]+$", 'i');
27+
var draftRegExp = new RegExp("^draft-", 'i');
28+
29+
var html = [];
30+
$.each(($(this).data("elements") || "").split("|"), function (i, element) {
31+
if (!$.trim(element))
32+
return;
33+
34+
if (draftRegExp.test(element) || stdNameRegExp.test(element)) {
35+
var displayName = element;
36+
37+
if (stdNameRegExp.test(element))
38+
displayName = element.slice(0, 3).toUpperCase() + " " + element.slice(3);
39+
40+
html.push('<div class="element"><a href="/doc/' + element + '/">' + displayName + '</a></div>');
41+
}
42+
else {
43+
html.push('<div class="element">' + element + '</div>');
44+
}
45+
});
46+
47+
if ($(this).data("sliced"))
48+
html.push('<div class="text-center">&hellip;</div>');
49+
50+
$(this).popover({
51+
trigger: "focus",
52+
template: '<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>',
53+
content: html.join(""),
54+
placement: "top",
55+
html: true
56+
}).on("click", function (e) {
57+
e.preventDefault();
58+
});
59+
});*/
60+
});

ietf/templates/doc/review/complete_review.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
{% block title %}{% if revising_review %}Revise{% elif assignment %}Complete{% else %}Submit unsolicited{% endif %} review of {{ doc.name }}{% endblock %}
66

77
{% block pagehead %}
8-
<link rel="stylesheet" href="{% static 'bootstrap-datepicker/css/bootstrap-datepicker3.min.css' %}">
8+
<link rel="stylesheet" href="{% static 'ietf/css/datepicker.css' %}">
99
{% endblock %}
1010

1111
{% block content %}
@@ -110,7 +110,7 @@ <h1>{% if revising_review %}Revise{% elif assignment %}Complete{% else %}Submit
110110
{% endblock %}
111111

112112
{% block js %}
113-
<script src="{% static 'bootstrap-datepicker/js/bootstrap-datepicker.min.js' %}"></script>
113+
<script src="{% static 'ietf/js/datepicker.js' %}"></script>
114114
<script>
115115
{% if assignment %}
116116
var searchMailArchiveUrl = "{% url "ietf.doc.views_review.search_mail_archive" name=doc.name assignment_id=assignment.pk %}";

ietf/templates/doc/review/edit_request_deadline.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
{% load origin django_bootstrap5 static %}
44

55
{% block pagehead %}
6-
<link rel="stylesheet" href="{% static 'bootstrap-datepicker/css/bootstrap-datepicker3.min.css' %}">
6+
<link rel="stylesheet" href="{% static 'ietf/css/datepicker.css' %}">
77
{% endblock %}
88

99
{% block title %}Edit review request deadline for {{ review_req.doc.name }}{% endblock %}
@@ -28,5 +28,5 @@ <h1>Edit review request deadline <br><small>{{ review_req.doc.name }}</small></h
2828
{% endblock %}
2929

3030
{% block js %}
31-
<script src="{% static 'bootstrap-datepicker/js/bootstrap-datepicker.min.js' %}"></script>
31+
<script src="{% static 'ietf/js/datepicker.js' %}"></script>
3232
{% endblock %}

ietf/templates/doc/review/request_review.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
{% block pagehead %}
66
{{ form.media.css }}
7-
<link rel="stylesheet" href="{% static 'bootstrap-datepicker/css/bootstrap-datepicker3.min.css' %}">
7+
<link rel="stylesheet" href="{% static 'ietf/css/datepicker.css' %}">
88
{% endblock %}
99

1010
{% block title %}Request review of {{ doc.name }} {% endblock %}
@@ -46,6 +46,6 @@ <h1>Request review<br><small>{{ doc.name }}</small></h1>
4646
{% endblock %}
4747

4848
{% block js %}
49-
<script src="{% static 'bootstrap-datepicker/js/bootstrap-datepicker.min.js' %}"></script>
49+
<script src="{% static 'ietf/js/datepicker.js' %}"></script>
5050
{{ form.media.js }}
5151
{% endblock %}

0 commit comments

Comments
 (0)