File tree 3 files changed +32
-2
lines changed
3 files changed +32
-2
lines changed Original file line number Diff line number Diff line change @@ -176,10 +176,10 @@ r##"<!DOCTYPE html>
176
176
krate = layout. krate,
177
177
play_url = layout. playground_url,
178
178
play_js = if layout. playground_url. is_empty( ) {
179
- "" . to_string ( )
179
+ format! ( r#"<script src="{}extra.js"></script>"# , page . root_path )
180
180
} else {
181
181
format!( r#"<script src="{}playpen.js"></script>"# , page. root_path)
182
- } ,
182
+ }
183
183
)
184
184
}
185
185
Original file line number Diff line number Diff line change
1
+ // Copyright 2014-2016 The Rust Project Developers. See the COPYRIGHT
2
+ // file at the top-level directory of this distribution and at
3
+ // http://rust-lang.org/COPYRIGHT.
4
+ //
5
+ // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6
+ // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7
+ // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8
+ // option. This file may not be copied, modified, or distributed
9
+ // except according to those terms.
10
+
11
+ /*jslint browser: true, es5: true */
12
+ /*globals $: true, rootPath: true */
13
+
14
+ document . addEventListener ( 'DOMContentLoaded' , function ( ) {
15
+ 'use strict' ;
16
+
17
+ if ( ! window . playgroundUrl ) {
18
+ var runButtons = document . querySelectorAll ( ".test-arrow" ) ;
19
+
20
+ for ( var i = 0 ; i < runButtons . length ; i ++ ) {
21
+ runButtons [ i ] . classList . remove ( "test-arrow" ) ;
22
+ }
23
+ return ;
24
+ }
25
+ } ) ;
Original file line number Diff line number Diff line change @@ -15,6 +15,11 @@ document.addEventListener('DOMContentLoaded', function() {
15
15
'use strict' ;
16
16
17
17
if ( ! window . playgroundUrl ) {
18
+ var runButtons = document . querySelectorAll ( ".test-arrow" ) ;
19
+
20
+ for ( var i = 0 ; i < runButtons . length ; i ++ ) {
21
+ runButtons [ i ] . classList . remove ( "test-arrow" ) ;
22
+ }
18
23
return ;
19
24
}
20
25
You can’t perform that action at this time.
0 commit comments