mirror of
https://git.mirrors.martin98.com/https://github.com/google/draco
synced 2025-08-12 06:59:03 +08:00
Merge pull request #152 from louquillio/bootstrap-spec-template
Adapt spec-related pages to Bootstrap.
This commit is contained in:
commit
6eb4920e64
6
docs/_includes/footer.html
Normal file
6
docs/_includes/footer.html
Normal file
@ -0,0 +1,6 @@
|
||||
<div class="container">
|
||||
<footer>
|
||||
<hr>
|
||||
<p>© 2017 The Draco authors</p>
|
||||
</footer>
|
||||
</div> <!-- /container -->
|
@ -153,13 +153,7 @@
|
||||
|
||||
</div> <!-- /container -->
|
||||
|
||||
<div class="container">
|
||||
<footer>
|
||||
<p>© 2017 The Draco authors</p>
|
||||
</footer>
|
||||
</div> <!-- /container -->
|
||||
</div> <!-- /container -->
|
||||
|
||||
{% include footer.html %}
|
||||
|
||||
<!-- Bootstrap core JavaScript
|
||||
================================================== -->
|
||||
|
115
docs/_layouts/spec-page.html
Normal file
115
docs/_layouts/spec-page.html
Normal file
@ -0,0 +1,115 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
<title>{{ page.title }}</title>
|
||||
|
||||
<!-- Bootstrap core CSS -->
|
||||
<link rel="stylesheet" href="{{ 'assets/css/bootstrap.min.css' | relative_url }}">
|
||||
|
||||
<!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
|
||||
<link rel="stylesheet" href="{{ 'assets/css/ie10-viewport-bug-workaround.css' | relative_url }}">
|
||||
|
||||
<!-- Custom styles for this template -->
|
||||
<link rel="stylesheet" href="{{ 'assets/css/navbar-fixed-top.css' | relative_url }}">
|
||||
|
||||
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
|
||||
<!--[if lt IE 9]>
|
||||
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
|
||||
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
|
||||
<![endif]-->
|
||||
<link rel="apple-touch-icon" sizes="57x57" href="{{ 'artwork/favicon/apple-icon-57x57.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="60x60" href="{{ 'artwork/favicon/apple-icon-60x60.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="72x72" href="{{ 'artwork/favicon/apple-icon-72x72.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="76x76" href="{{ 'artwork/favicon/apple-icon-76x76.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="114x114" href="{{ 'artwork/favicon/apple-icon-114x114.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="120x120" href="{{ 'artwork/favicon/apple-icon-120x120.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="144x144" href="{{ 'artwork/favicon/apple-icon-144x144.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="152x152" href="{{ 'artwork/favicon/apple-icon-152x152.png' | relative_url }}">
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="{{ 'artwork/favicon/apple-icon-180x180.png' | relative_url }}">
|
||||
<link rel="icon" type="image/png" sizes="36x36" href="{{ 'artwork/favicon/android-icon-36x36.png' | relative_url }}">
|
||||
<link rel="icon" type="image/png" sizes="96x96" href="{{ 'artwork/favicon/android-icon-96x96.png' | relative_url }}">
|
||||
<link rel="manifest" href="{{ 'artwork/favicon/manifest.json' | relative_url }}">
|
||||
<meta name="msapplication-TileColor" content="#ffffff">
|
||||
<meta name="msapplication-TileImage" content="{{ 'artwork/favicon/ms-icon-144x144.png' | relative_url }}">
|
||||
<meta name="theme-color" content="#ffffff">
|
||||
<link rel="stylesheet" href="{{ 'assets/css/spec-style.css' | relative_url }}">
|
||||
<style>
|
||||
body {counter-reset: h2}
|
||||
h2 {counter-reset: h3}
|
||||
h3 {counter-reset: h4}
|
||||
h4 {counter-reset: h5}
|
||||
h5 {counter-reset: h6}
|
||||
|
||||
h2:before {counter-increment: h2; content: counter(h2) ". "}
|
||||
h3:before {counter-increment: h3; content: counter(h2) "." counter(h3) ". "}
|
||||
h4:before {counter-increment: h4; content: counter(h2) "." counter(h3) "." counter(h4) ". "}
|
||||
h5:before {counter-increment: h5; content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) ". "}
|
||||
h6:before {counter-increment: h6; content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) "." counter(h6) ". "}
|
||||
|
||||
h2.nocount:before, h3.nocount:before, h4.nocount:before, h5.nocount:before, h6.nocount:before { content: ""; counter-increment: none }
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-default navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="/">Draco 3D</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="https://github.com/google/draco">Github</a></li>
|
||||
<li><a href="https://storage.googleapis.com/demos.webmproject.org/draco/draco_loader_throw.html">Demo</a></li>
|
||||
<li><a href="https://github.com/google/draco/tree/master/javascript/example">Example</a></li>
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Spec <span class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a href="spec">Draft Specification</a></li>
|
||||
<li><a href="spec/README.html">Author README</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li></li>
|
||||
<li></li>
|
||||
</ul>
|
||||
</div><!--/.nav-collapse -->
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xs-12 col-sm-12 col-md-10 col-md-offset-1">
|
||||
{{ content }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div> <!-- /container -->
|
||||
|
||||
{% include footer.html %}
|
||||
|
||||
<!-- Bootstrap core JavaScript
|
||||
================================================== -->
|
||||
<!-- Placed at the end of the document so the pages load faster -->
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
|
||||
<script src="{{ 'assets/js/bootstrap.min.js' | relative_url }}"></script>
|
||||
<!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
|
||||
<script src="{{ 'assets/js/ie10-viewport-bug-workaround.js' | relative_url }}"></script>
|
||||
{% include analytics.html %}
|
||||
</body>
|
||||
</html>
|
@ -9,33 +9,6 @@ $monofont: 'Inconsolata', monospace
|
||||
$gridcolor: #ddd
|
||||
$gridweight: 2px
|
||||
|
||||
body
|
||||
font-family: Arial, sans-serif
|
||||
margin: 5% 25% 10% 10%
|
||||
line-height: 1.3
|
||||
|
||||
a
|
||||
color: navy
|
||||
text-decoration: none
|
||||
&:visited
|
||||
color: navy
|
||||
text-decoration: none
|
||||
&:hover
|
||||
text-decoration: underline
|
||||
|
||||
pre
|
||||
//font-family: $monofont
|
||||
//border: $gridweight solid $gridcolor
|
||||
//background-color: #f7f7f7
|
||||
//padding: 1em
|
||||
//margin-left: 1em
|
||||
//overflow-x: auto
|
||||
|
||||
code
|
||||
//color: #060
|
||||
//background-color: #f2f2f2
|
||||
font-family: $monofont
|
||||
|
||||
table
|
||||
border-collapse: collapse
|
||||
min-width: 50%
|
||||
@ -82,15 +55,62 @@ figure.highlight
|
||||
|
||||
div.draco-syntax pre
|
||||
background-color: #fff
|
||||
background-image: linear-gradient(90deg, transparent 580px, #abced4 580px, #abced4 582px, transparent 582px), linear-gradient($gridcolor .1em, transparent .1em)
|
||||
background-image: linear-gradient(90deg, transparent 660px, #abced4 660px, #abced4 662px, transparent 582px), linear-gradient($gridcolor .1em, transparent .1em)
|
||||
background-size: 100% 1.3em
|
||||
border-left: $gridweight solid $gridcolor
|
||||
border-right: $gridweight solid $gridcolor
|
||||
border-bottom: $gridweight solid $gridcolor
|
||||
white-space: pre
|
||||
font-family: $monofont
|
||||
font-size: 1em
|
||||
padding-left: 1em
|
||||
font-size: 14px
|
||||
padding: 0 14px
|
||||
line-height: 18px
|
||||
margin-left: 1em
|
||||
width: 720px
|
||||
width: 840px
|
||||
//overflow: auto
|
||||
|
||||
ol.breadcrumb
|
||||
background-color: #fff
|
||||
padding-left: 0
|
||||
font-size: 12px
|
||||
|
||||
// Auto heading-number styles
|
||||
|
||||
body
|
||||
counter-reset: h2
|
||||
|
||||
h2
|
||||
counter-reset: h3
|
||||
|
||||
h3
|
||||
counter-reset: h4
|
||||
|
||||
h4
|
||||
counter-reset: h5
|
||||
|
||||
h5
|
||||
counter-reset: h6
|
||||
|
||||
h2:before
|
||||
counter-increment: h2
|
||||
content: counter(h2) ". "
|
||||
|
||||
h3:before
|
||||
counter-increment: h3
|
||||
content: counter(h2) "." counter(h3) ". "
|
||||
|
||||
h4:before
|
||||
counter-increment: h4
|
||||
content: counter(h2) "." counter(h3) "." counter(h4) ". "
|
||||
|
||||
h5:before
|
||||
counter-increment: h5
|
||||
content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) ". "
|
||||
|
||||
h6:before
|
||||
counter-increment: h6
|
||||
content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) "." counter(h6) ". "
|
||||
|
||||
h2.nocount:before, h3.nocount:before, h4.nocount:before, h5.nocount:before, h6.nocount:before
|
||||
content: ""
|
||||
counter-increment: none
|
||||
|
@ -1,5 +1,5 @@
|
||||
---
|
||||
layout: spec
|
||||
layout: spec-page
|
||||
title: "README: Draco Spec Authoring Information"
|
||||
---
|
||||
|
||||
@ -189,7 +189,7 @@ them up as follows:
|
||||
immediately after the code-block closing delimiter.
|
||||
|
||||
* Some syntax elements as annotated with their type and size in a right-hand
|
||||
column. In your text editor, position these annotations at column 73.
|
||||
column. In your text editor, position these annotations at column **86**.
|
||||
|
||||
**Example:**
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
---
|
||||
layout: spec
|
||||
layout: spec-page
|
||||
title: Draco Bitstream Specification (Draft)
|
||||
version: Version 1,2
|
||||
version_date: Released 2017-xx-xx
|
||||
|
Loading…
x
Reference in New Issue
Block a user