|
| 1 | +<!DOCTYPE HTML> |
| 2 | +<html lang="{{ language }}"> |
| 3 | + <head> |
| 4 | + <meta charset="UTF-8"> |
| 5 | + <title>{{ title }}</title> |
| 6 | + <meta content="text/html; charset=utf-8" http-equiv="Content-Type"> |
| 7 | + <meta name="description" content="{% block description %}{% endblock %}"> |
| 8 | + <meta name="viewport" content="width=device-width, initial-scale=1"> |
| 9 | + |
| 10 | + <base href="{{ path_to_root }}"> |
| 11 | + |
| 12 | + <link rel="stylesheet" href="book.css"> |
| 13 | + <link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'> |
| 14 | + |
| 15 | + <!-- Font Awesome --> |
| 16 | + <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css"> |
| 17 | + |
| 18 | + <link rel="stylesheet" href="highlight.css"> |
| 19 | + <link rel="stylesheet" href="tomorrow-night.css"> |
| 20 | + |
| 21 | + <!-- MathJax --> |
| 22 | + <script type="text/javascript" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script> |
| 23 | + |
| 24 | + <!-- Fetch JQuery from CDN but have a local fallback --> |
| 25 | + <script src="http://code.jquery.com/jquery-2.1.4.min.js"></script> |
| 26 | + <script> |
| 27 | + if (typeof jQuery == 'undefined') { |
| 28 | + document.write(unescape("%3Cscript src='jquery.js'%3E%3C/script%3E")); |
| 29 | + } |
| 30 | + </script> |
| 31 | + </head> |
| 32 | + <body> |
| 33 | + <!-- Set the theme before any content is loaded, prevents flash --> |
| 34 | + <script type="text/javascript"> |
| 35 | + var theme = localStorage.getItem('theme'); |
| 36 | + if (theme == null) { theme = 'light'; } |
| 37 | + $('body').removeClass().addClass(theme); |
| 38 | + </script> |
| 39 | + |
| 40 | + <!-- Hide / unhide sidebar before it is displayed --> |
| 41 | + <script type="text/javascript"> |
| 42 | + var sidebar = localStorage.getItem('sidebar'); |
| 43 | + if (sidebar === "hidden") { $("html").addClass("sidebar-hidden") } |
| 44 | + else if (sidebar === "visible") { $("html").addClass("sidebar-visible") } |
| 45 | + </script> |
| 46 | + |
| 47 | + <div id="sidebar" class="sidebar"> |
| 48 | + {{#toc}}{{/toc}} |
| 49 | + </div> |
| 50 | + |
| 51 | + <div id="page-wrapper" class="page-wrapper"> |
| 52 | + |
| 53 | + <div class="page"> |
| 54 | + <div id="menu-bar" class="menu-bar"> |
| 55 | + <div class="left-buttons"> |
| 56 | + <i id="sidebar-toggle" class="fa fa-bars"></i> |
| 57 | + <i id="theme-toggle" class="fa fa-paint-brush"></i> |
| 58 | + </div> |
| 59 | + |
| 60 | + <h1 class="menu-title">{{ title }}</h1> |
| 61 | + |
| 62 | + <div class="right-buttons"> |
| 63 | + <i id="print-button" class="fa fa-print" title="Print this book"></i> |
| 64 | + </div> |
| 65 | + </div> |
| 66 | + |
| 67 | + <div id="content" class="content"> |
| 68 | + |
| 69 | + <div class="warning" style="border: 1px solid #aaaaaa; border-radius: 5px; padding: 20px;"> |
| 70 | + <i class="fa fa-warning fa-2x" style="float: left; display: inline-block; color: #FFAA00;"></i> |
| 71 | + <div style="dislay: inline-block; padding-left: 50px;"> |
| 72 | + This book is in the process of being rewritten. Some sections are in form of drafts and |
| 73 | + others haven't been rewritten yet. The stable version can be found <a href="https://doc.rust-lang.org/stable/book/">here</a>. |
| 74 | + </div> |
| 75 | + </div> |
| 76 | + |
| 77 | + {{{ content }}} |
| 78 | + </div> |
| 79 | + |
| 80 | + <!-- Mobile navigation buttons --> |
| 81 | + {{#previous}} |
| 82 | + <a href="{{link}}" class="mobile-nav-chapters previous"> |
| 83 | + <i class="fa fa-angle-left"></i> |
| 84 | + </a> |
| 85 | + {{/previous}} |
| 86 | + |
| 87 | + {{#next}} |
| 88 | + <a href="{{link}}" class="mobile-nav-chapters next"> |
| 89 | + <i class="fa fa-angle-right"></i> |
| 90 | + </a> |
| 91 | + {{/next}} |
| 92 | + |
| 93 | + </div> |
| 94 | + |
| 95 | + {{#previous}} |
| 96 | + <a href="{{link}}" class="nav-chapters previous"> |
| 97 | + <i class="fa fa-angle-left"></i> |
| 98 | + </a> |
| 99 | + {{/previous}} |
| 100 | + |
| 101 | + {{#next}} |
| 102 | + <a href="{{link}}" class="nav-chapters next"> |
| 103 | + <i class="fa fa-angle-right"></i> |
| 104 | + </a> |
| 105 | + {{/next}} |
| 106 | + |
| 107 | + </div> |
| 108 | + |
| 109 | + |
| 110 | + <!-- Local fallback for Font Awesome --> |
| 111 | + <script> |
| 112 | + if ($(".fa").css("font-family") !== "FontAwesome") { |
| 113 | + $('<link rel="stylesheet" type="text/css" href="_FontAwesome/css/font-awesome.css">').prependTo('head'); |
| 114 | + } |
| 115 | + </script> |
| 116 | + |
| 117 | + <script src="highlight.js"></script> |
| 118 | + <script src="book.js"></script> |
| 119 | + </body> |
| 120 | +</html> |
0 commit comments