forked from ietf-tools/datatracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocument_html.html
More file actions
336 lines (335 loc) · 20.1 KB
/
document_html.html
File metadata and controls
336 lines (335 loc) · 20.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
{# Copyright The IETF Trust 2016, All Rights Reserved #}
<!DOCTYPE html>
{% load analytical %}
{% load origin %}
{% load static %}
{% load ietf_filters textfilters %}
{% origin %}
<html data-bs-theme="auto" lang="en">
<head>
{% analytical_head_top %}
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>
{% if doc.type_id == "rfc" %}
RFC {{ doc.rfc_number }} - {{ doc.title }}
{% else %}
{{ doc.name }}-{{ doc.rev }}
{% endif %}
</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="{{ settings.STATIC_IETF_ORG }}/fonts/inter/import.css" rel="stylesheet">
<link href="{{ settings.STATIC_IETF_ORG }}/fonts/noto-sans-mono/import.css" rel="stylesheet">
{% if request.COOKIES.pagedeps == 'inline' %}
<script>{{ js|safe }}</script>
<style>{{ css|safe }}</style>
{% else %}
<link rel="stylesheet" href="{% static 'ietf/css/document_html_referenced.css' %}">
{% if html %}
<link rel="stylesheet" href="{% static 'ietf/css/document_html_txt.css' %}">
{% endif %}
<script src="{% static 'ietf/js/document_html.js' %}"></script>
<script src="{% static 'ietf/js/theme.js' %}"></script>
{% endif %}
<link rel="alternate" type="application/atom+xml" title="Document changes" href="/feed/document-changes/{{ doc.name }}/">
<meta name="description"
{% if doc.type_id == "rfc" %}
content="{{ doc.title }} (RFC {{ doc.rfc_number }}, {{ published.time|date:'F Y' }}{% if obsoleted_by %}; obsoleted by {% for rel in obsoleted_by %}{{ rel.source.name|prettystdname}}{% if not forloop.last%}, {% endif %}{% endfor %}{% endif %})"
{% else %}
content="{{ doc.title }} (Internet-Draft, {{ doc.time|date:'Y' }})"
{% endif %}>
{% include "base/icons.html" %}
{% include "doc/opengraph.html" %}
{% analytical_head_bottom %}
<style>
{# Force "text-overflow: ellipsis" to hide the beginning of a doc name #}
.diff-form .select2-selection__rendered {
direction: rtl;
text-align: left;
}
</style>
</head>
<body>
{% analytical_body_top %}
<div class="btn-toolbar sidebar-toolbar position-fixed top-0 end-0 m-2 m-lg-3 d-print-none">
<div class="dropdown">
<button class="btn btn-outline-secondary btn-sm me-1 dropdown-toggle d-flex align-items-center"
id="bd-theme" type="button" aria-expanded="false" data-bs-toggle="dropdown"
aria-label="Toggle theme">
<i class="theme-icon-active bi bi-circle-half"></i>
</button>
<ul class="dropdown-menu" aria-labelledby="bd-theme">
<li>
<button type="button" class="dropdown-item d-flex align-items-center"
data-bs-theme-value="light" aria-pressed="false">
<i class="me-2 opacity-50 theme-icon bi bi-sun-fill"></i>
Light<i class="bi bi-check2 ms-auto d-none"></i>
</button>
</li>
<li>
<button type="button" class="dropdown-item d-flex align-items-center"
data-bs-theme-value="dark" aria-pressed="false">
<i class="me-2 opacity-50 theme-icon bi bi-moon-stars-fill"></i>
Dark<i class="bi bi-check2 ms-auto d-none"></i>
</button>
</li>
<li>
<button type="button" class="dropdown-item d-flex align-items-center active"
data-bs-theme-value="auto" aria-pressed="true">
<i class="me-2 opacity-50 theme-icon bi bi-circle-half"></i>
Auto<i class="bi bi-check2 ms-auto d-none"></i>
</button>
</li>
</ul>
</div>
<button class="btn btn-outline-secondary btn-sm sidebar-toggle"
type="button"
data-bs-toggle="collapse"
data-bs-target="#sidebar"
aria-expanded="{% if request.COOKIES.sidebar != 'off'%}true{% else %}false{% endif %}"
aria-controls="sidebar"
aria-label="Toggle metadata sidebar"
title="Toggle metadata sidebar">
<i class="bi bi-arrow-bar-left sidebar-shown"></i>
<i class="bi bi-arrow-bar-right sidebar-collapsed"></i>
</button>
</div>
<nav class="navbar bg-light-subtle px-1 fixed-top d-print-none d-md-none">
<a class="nav-link ps-1"
href="{% url 'ietf.doc.views_doc.document_main' name=doc.name %}">
{% if doc.type_id == "rfc" %}
RFC {{ doc.rfc_number }}
{% else %}
{{ doc.name }}-{{ doc.rev }}
{% endif %}
<br class="d-sm-none">
<span class="ms-sm-3 badge rounded-pill badge-{% if not snapshot %}{{ doc|std_level_to_label_format }}{% else %}draft{% endif %}">
{% if not snapshot %}
{{ doc.std_level }}
{% else %}
Internet-Draft
{% endif %}
</span>
</a>
<button class="navbar-toggler p-1"
type="button"
data-bs-toggle="collapse"
data-bs-target="#docinfo-collapse"
aria-controls="docinfo-collapse"
aria-expanded="false"
aria-label="Show document information">
<span class="navbar-toggler-icon small"></span>
</button>
<div class="navbar-nav navbar-nav-scroll overscroll-none collapse pt-1" id="docinfo-collapse">
<div class="bg-light-subtle p-0">
<table class="table table-sm table-borderless small">
<tbody class="meta align-top">
<tr>
<th scope="row"></th>
<th scope="row">Title</th>
<td class="edit"></td>
<td>{{ doc.title }}</td>
</tr>
</tbody>
{% include "doc/document_info.html" with sidebar=False %}
<tr>
<th scope="row"></th>
<th scope="row"></th>
<td class="edit"></td>
<td>
<a class="btn btn-sm btn-warning mb-3"
target="_blank"
href="https://github.com/ietf-tools/datatracker/issues/new/choose">
Report a bug
<i class="bi bi-bug"></i>
</a>
</td>
</tr>
</table>
</div>
</div>
</nav>
<div class="row g-0">
<div class="col-md-9 d-flex justify-content-center lh-sm"
data-bs-spy="scroll"
data-bs-target="#toc-nav"
data-bs-smooth-scroll="true"
tabindex="0"
id="content">
{% if html and request.COOKIES.htmlconf != 'txt' %}
<div class="rfchtml">
<br class="noprint">
{{ html|safe }}
</div>
{% else %}
<div class="rfcmarkup">
<br class="noprint">
<!-- [html-validate-disable-block attr-quotes, void-style, element-permitted-content, heading-level -- FIXME: rfcmarkup/rfc2html generates HTML with issues] -->
{{ doc.htmlized|default:"Generation of htmlized text failed"|safe }}
</div>
{% endif %}
</div>
<div class="d-print-none col-md-3 bg-light-subtle collapse{% if request.COOKIES.sidebar != 'off'%} show{% endif %}" id="sidebar">
<div class="position-fixed border-start sidebar overflow-scroll overscroll-none no-scrollbar">
<div class="d-flex flex-column vh-100 pt-2 pt-lg-3 ps-3 pl-md-2 pl-lg-3">
<div>
<a class="btn btn-primary btn-sm" href="{% url 'ietf.doc.views_doc.document_main' name=doc.name %}">Datatracker</a>
<p class="fw-bold pt-2">
{% if doc.type_id == "rfc" %}
RFC {{ doc.rfc_number }}
{% else %}
{{ doc.name }}-{{ doc.rev }}
{% endif %}
<br>
<span class="badge rounded-pill badge-{% if not snapshot %}{{ doc|std_level_to_label_format }}{% else %}draft{% endif %}">
{% if not snapshot %}
{{ doc.std_level }}
{% else %}
Internet-Draft
{% endif %}
</span>
</p>
</div>
{% if request.COOKIES.htmlconf and request.COOKIES.htmlconf != 'html' and html %}
<div class="alert alert-info small">
You are viewing the legacy <code><a class="text-decoration-none text-reset" href="https://github.com/ietf-tools/rfc2html">rfc2html</a></code>
rendering of this document. Change the
preferences for a modern <code><a class="text-decoration-none text-reset" href="https://github.com/ietf-tools/xml2rfc">xml2rfc</a></code>-based
HTMLization.
</div>
{% elif request.COOKIES.htmlconf == 'html' and not html %}
<div class="alert alert-info small">
You are viewing the legacy <code><a class="text-decoration-none text-reset" href="https://github.com/ietf-tools/rfc2html">rfc2html</a></code>
rendering, because no <code><a class="text-decoration-none text-reset" href="https://github.com/ietf-tools/xml2rfc">xml2rfc</a></code>-generated
HTML is available for this document.
</div>
{% endif %}
<ul class="nav nav-tabs nav-fill small me-2" role="tablist">
<li class="nav-item" role="presentation" title="Document information">
<button class="nav-link px-2"
id="docinfo-tab"
data-bs-toggle="tab"
data-bs-target="#docinfo-tab-pane"
type="button"
role="tab"
aria-controls="docinfo-tab-pane"
aria-selected="true">
<i class="bi bi-info-circle"></i><span class="d-none d-md-block d-xl-inline ms-xl-1">Info</span>
</button>
</li>
<li class="nav-item" role="presentation" title="Table of contents">
<button class="nav-link px-2"
id="toc-tab"
data-bs-toggle="tab"
data-bs-target="#toc-tab-pane"
type="button"
role="tab"
aria-controls="toc-tab-pane"
aria-selected="false">
<i class="bi bi-list-ol"></i><span class="d-none d-md-block d-xl-inline ms-xl-1">Contents</span>
</button>
</li>
<li class="nav-item" role="presentation" title="Preferences">
<button class="nav-link px-2"
id="pref-tab"
data-bs-toggle="tab"
data-bs-target="#pref-tab-pane"
type="button"
role="tab"
aria-controls="pref-tab-pane"
aria-selected="false">
<i class="bi bi-gear"></i><span class="d-none d-md-block d-xl-inline ms-xl-1">Prefs</span>
</button>
</li>
</ul>
<div class="overflow-auto tab-content pt-2 me-2">
<div class="tab-pane"
id="docinfo-tab-pane"
role="tabpanel"
aria-labelledby="docinfo-tab"
tabindex="0">
<table class="table table-sm table-borderless">
{% include "doc/document_info.html" with sidebar=True %}
</table>
<a class="btn btn-sm btn-warning mb-3"
target="_blank"
href="https://github.com/ietf-tools/datatracker/issues/new/choose">
Report a datatracker bug
<i class="bi bi-bug"></i>
</a>
</div>
<div class="tab-pane mb-5"
id="toc-tab-pane"
role="tabpanel"
aria-labelledby="toc-tab"
tabindex="0">
<nav class="nav nav-pills flex-column small" id="toc-nav">
</nav>
</div>
<div class="tab-pane mb-5 small"
id="pref-tab-pane"
role="tabpanel"
aria-labelledby="pref-tab"
tabindex="0">
<label class="form-label fw-bold mb-2">Show sidebar by default</label>
<div class="btn-group-vertical btn-group-sm d-flex" role="group">
<input type="radio" class="btn-check" name="sidebar" id="on-radio">
<label class="btn btn-outline-primary" for="on-radio">Yes</label>
<input type="radio" class="btn-check" name="sidebar" id="off-radio">
<label class="btn btn-outline-primary" for="off-radio">No</label>
</div>
<label class="form-label fw-bold mt-4 mb-2">Tab to show by default</label>
<div class="btn-group-vertical btn-group-sm d-flex" role="group">
<input type="radio" class="btn-check" name="deftab" id="docinfo-radio">
<label class="btn btn-outline-primary" for="docinfo-radio">
<i class="bi bi-info-circle me-1"></i>Info
</label>
<input type="radio" class="btn-check" name="deftab" id="toc-radio">
<label class="btn btn-outline-primary" for="toc-radio">
<i class="bi bi-list-ol me-1"></i>Contents
</label>
</div>
<label class="form-label fw-bold mt-4 mb-2">HTMLization configuration</label>
<div class="btn-group-vertical btn-group-sm d-flex" role="group">
<input type="radio" class="btn-check" name="htmlconf" id="txt-radio">
<label class="btn btn-outline-primary" for="txt-radio" title="This is the traditional HTMLization method.">
<i class="bi bi-badge-sd me-1"></i>HTMLize the plaintext
</label>
<input type="radio" class="btn-check" name="htmlconf" id="html-radio">
<label class="btn btn-outline-primary" for="html-radio" title="This is the modern HTMLization method.">
<i class="bi bi-badge-hd me-1"></i>Plaintextify the HTML
</label>
</div>
<label class="form-label fw-bold mt-4 mb-2" for="ptsize">Maximum font size</label>
<input type="range" class="form-range" min="7" max="16" id="ptsize" oninput="ptdemo.value = ptsize.value">
<label class="form-label fw-bold mt-4 mb-2">Page dependencies</label>
<div class="btn-group-vertical btn-group-sm d-flex" role="group">
<input type="radio" class="btn-check" name="pagedeps" id="inline-radio">
<label class="btn btn-outline-primary" for="inline-radio" title="Generate larger, standalone web pages that do not require network access to render.">
<i class="bi bi-box me-1"></i>Inline
</label>
<input type="radio" class="btn-check" name="pagedeps" id="reference-radio">
<label class="btn btn-outline-primary" for="reference-radio" title="Generate regular web pages that require network access to render.">
<i class="bi bi-link-45deg me-1"></i>Reference
</label>
</div>
<label class="form-label fw-bold mt-4 mb-2">Citation links</label>
<div class="btn-group-vertical btn-group-sm d-flex" role="group">
<input type="radio" class="btn-check" name="reflinks" id="refsection-radio">
<label class="btn btn-outline-primary" for="refsection-radio" title="Citation links go to the reference section.">
<i class="bi bi-arrow-clockwise"></i> Go to reference section
</label>
<input type="radio" class="btn-check" name="reflinks" id="citation-radio">
<label class="btn btn-outline-primary" for="citation-radio" title="Citation links go directly to the cited document.">
<i class="bi bi-link-45deg me-1"></i>Go to linked document
</label>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
{% analytical_body_bottom %}
</body>
</html>