7
7
8
8
9
9
<!-- Custom HTML head -->
10
-
11
- < meta content ="text/html; charset=utf-8 " http-equiv ="Content-Type ">
12
- < meta name ="description " content ="A description ">
10
+
11
+ < meta name ="description " content ="Rust by Example (RBE) is a collection of runnable examples that illustrate various Rust concepts and standard libraries. ">
13
12
< meta name ="viewport " content ="width=device-width, initial-scale=1 ">
14
13
< meta name ="theme-color " content ="#ffffff " />
15
14
35
34
</ head >
36
35
< body >
37
36
<!-- Provide site root to javascript -->
38
- < script type =" text/javascript " >
37
+ < script >
39
38
var path_to_root = "" ;
40
39
var default_theme = window . matchMedia ( "(prefers-color-scheme: dark)" ) . matches ? "navy" : "light" ;
41
40
</ script >
42
41
43
42
<!-- Work around some values being stored in localStorage wrapped in quotes -->
44
- < script type =" text/javascript " >
43
+ < script >
45
44
try {
46
45
var theme = localStorage . getItem ( 'mdbook-theme' ) ;
47
46
var sidebar = localStorage . getItem ( 'mdbook-sidebar' ) ;
57
56
</ script >
58
57
59
58
<!-- Set the theme before any content is loaded, prevents flash -->
60
- < script type =" text/javascript " >
59
+ < script >
61
60
var theme ;
62
61
try { theme = localStorage . getItem ( 'mdbook-theme' ) ; } catch ( e ) { }
63
62
if ( theme === null || theme === undefined ) { theme = default_theme ; }
69
68
</ script >
70
69
71
70
<!-- Hide / unhide sidebar before it is displayed -->
72
- < script type =" text/javascript " >
71
+ < script >
73
72
var html = document . querySelector ( 'html' ) ;
74
73
var sidebar = 'hidden' ;
75
74
if ( document . body . clientWidth >= 1080 ) {
90
89
< div id ="page-wrapper " class ="page-wrapper ">
91
90
92
91
< div class ="page ">
93
- < div id ="menu-bar-hover-placeholder "> </ div >
92
+ < div id ="menu-bar-hover-placeholder "> </ div >
94
93
< div id ="menu-bar " class ="menu-bar sticky bordered ">
95
94
< div class ="left-buttons ">
96
95
< button id ="sidebar-toggle " class ="icon-button " type ="button " title ="Toggle Table of Contents " aria-label ="Toggle Table of Contents " aria-controls ="sidebar ">
100
99
< i class ="fa fa-paint-brush "> </ i >
101
100
</ button >
102
101
< ul id ="theme-list " class ="theme-popup " aria-label ="Themes " role ="menu ">
103
- < li role ="none "> < button role ="menuitem " class ="theme " id ="light "> Light (default) </ button > </ li >
102
+ < li role ="none "> < button role ="menuitem " class ="theme " id ="light "> Light</ button > </ li >
104
103
< li role ="none "> < button role ="menuitem " class ="theme " id ="rust "> Rust</ button > </ li >
105
104
< li role ="none "> < button role ="menuitem " class ="theme " id ="coal "> Coal</ button > </ li >
106
105
< li role ="none "> < button role ="menuitem " class ="theme " id ="navy "> Navy</ button > </ li >
@@ -136,7 +135,7 @@ <h1 class="menu-title">Rust By Example 日本語版</h1>
136
135
</ div >
137
136
138
137
<!-- Apply ARIA attributes after the sidebar and the sidebar toggle button are added to the DOM -->
139
- < script type =" text/javascript " >
138
+ < script >
140
139
document . getElementById ( 'sidebar-toggle' ) . setAttribute ( 'aria-expanded' , sidebar === 'visible' ) ;
141
140
document . getElementById ( 'sidebar' ) . setAttribute ( 'aria-hidden' , sidebar !== 'visible' ) ;
142
141
Array . from ( document . querySelectorAll ( '#sidebar a' ) ) . forEach ( function ( link ) {
@@ -163,6 +162,7 @@ <h1 id="アトリビュート"><a class="header" href="#アトリビュート">
163
162
* link to a foreign library
164
163
* mark functions as unit tests
165
164
* mark functions that will be part of a benchmark
165
+ * [attribute like macros][macros]
166
166
-->
167
167
< ul >
168
168
< li > < a href ="attribute/cfg.html "> コンパイル時の条件分岐</ a > </ li >
@@ -193,8 +193,7 @@ <h1 id="アトリビュート"><a class="header" href="#アトリビュート">
193
193
194
194
195
195
#[attribute(value, value2, value3,
196
- value4, value5)]
197
- </ code > </ pre >
196
+ value4, value5)]</ code > </ pre >
198
197
199
198
</ main >
200
199
@@ -227,24 +226,27 @@ <h1 id="アトリビュート"><a class="header" href="#アトリビュート">
227
226
228
227
229
228
229
+ < script >
230
+ window . playground_line_numbers = true ;
231
+ </ script >
230
232
231
- < script type =" text/javascript " >
233
+ < script >
232
234
window . playground_copyable = true ;
233
235
</ script >
234
236
235
- < script src ="ace.js " type =" text/javascript " charset =" utf-8 " > </ script >
236
- < script src ="editor.js " type =" text/javascript " charset =" utf-8 " > </ script >
237
- < script src ="mode-rust.js " type =" text/javascript " charset =" utf-8 " > </ script >
238
- < script src ="theme-dawn.js " type =" text/javascript " charset =" utf-8 " > </ script >
239
- < script src ="theme-tomorrow_night.js " type =" text/javascript " charset =" utf-8 " > </ script >
237
+ < script src ="ace.js "> </ script >
238
+ < script src ="editor.js "> </ script >
239
+ < script src ="mode-rust.js "> </ script >
240
+ < script src ="theme-dawn.js "> </ script >
241
+ < script src ="theme-tomorrow_night.js "> </ script >
240
242
241
- < script src ="elasticlunr.min.js " type =" text/javascript " charset =" utf-8 " > </ script >
242
- < script src ="mark.min.js " type =" text/javascript " charset =" utf-8 " > </ script >
243
- < script src ="searcher.js " type =" text/javascript " charset =" utf-8 " > </ script >
243
+ < script src ="elasticlunr.min.js "> </ script >
244
+ < script src ="mark.min.js "> </ script >
245
+ < script src ="searcher.js "> </ script >
244
246
245
- < script src ="clipboard.min.js " type =" text/javascript " charset =" utf-8 " > </ script >
246
- < script src ="highlight.js " type =" text/javascript " charset =" utf-8 " > </ script >
247
- < script src ="book.js " type =" text/javascript " charset =" utf-8 " > </ script >
247
+ < script src ="clipboard.min.js "> </ script >
248
+ < script src ="highlight.js "> </ script >
249
+ < script src ="book.js "> </ script >
248
250
249
251
<!-- Custom JS scripts -->
250
252
0 commit comments