-
Notifications
You must be signed in to change notification settings - Fork 0
/
template.liquid
96 lines (94 loc) · 3.81 KB
/
template.liquid
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{{api.name}}</title>
<meta name="description" content="{{ api.description | strip_newlines | escape }}">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="sha384-1q8mTJOASx8j1Au+a5WDVnPi2lkFfwwEAa8hDDdjZlpLegxhjVME1fgjWPGmkzs7" crossorigin="anonymous">
<style>
tt, pre, code { font-family: Consolas, "Liberation Mono", Courier, monospace; background-color: transparent !important; }
pre.prettyprint { border: 0px !important; background-color: #fff; margin-bottom: -0.5em; }
table { width: 100%; border-collapse: collapse; margin-bottom: 1.3em; }
th { background: #f2f2f2; }
td, th { padding: 6px 9.5px; border: 1px solid #e4e4e4; text-align: left; }
tbody tr:nth-of-type(even){ background:rgba(220,220,220,0.2); }
.panel-heading h2 { margin-top: 0.5em; }
.bg-default { background-color: #F8F8F8; }
.snippet { background: #FFFFFF; list-style: none; display: none; }
.snippet-toggle { margin-top: -0.3em; }
.parameters { margin-bottom: 0; }
.parameters-li { padding: 0; }
.parameters td { vertical-align: top; border-color: #eee; border-width: 0 0 1px 0; }
.parameters td p { margin-bottom: 0; }
.parameters td code { padding: 0; }
.parameters thead th { padding: 3px 9px 3px 11px; color: #595959; font-weight: 400; font-size: 0.75em; }
.parameters tbody tr:nth-of-type(even){ background: #fff; }
.parameters tbody tr:last-child td { border-bottom: 0; }
.parameters tbody td:nth-child(1) { width: 10%; min-width: 100px; }
.parameters tbody td:nth-child(2) { width: 60%; }
.parameter-example { word-break: keep-all; }
.parameter-name { text-align: right; }
.parameters .label-string { background: #99ac6d; }
.parameters .label-boolean { background: #8298bd; }
.parameters .label-integer { background: #cd6a50; }
.parameters .label-time { background: #f0ad4e; }
@media screen and (max-width: 640px) {
.parameters {
overflow-x: auto;
display: block;
}
}
</style>
</head>
<body>
<div class="container">
<div class="row">
<div class="col-md-12">
<div class="page-header">
<h1>{{ api.name }}</h1>
<h2><small>{{ api.description | markdownize }}</small></h2>
</div>
</div>
</div>
<div class="row" style="margin-bottom: 2em;">
<div class="col-md-12">
{% render 'nav_resource_groups' with api.resourceGroups as resourceGroups %}
</div>
</div>
<div class="row">
<div class="col-xs-12 col-sm-12 col-md-12">
<div class="tab-content">
{% render 'resource_groups.liquid' with api.resourceGroups as resourceGroups %}
</div>
</div>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.3/jquery.min.js"></script>
<script src="https://cdn.rawgit.com/google/code-prettify/master/loader/run_prettify.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" integrity="sha384-0mSbJDEHialfmuBBQP6A4Qrprq5OVfW37PRR3j5ELqxss1yVqOtnepnHVP9aJ7xS" crossorigin="anonymous"></script>
<script>
jQuery(function($) {
$('#group-tab a[data-toggle="tab"]').on("click", function(e) {
window.location.hash = $(this).attr("href");
});
if(window.location.hash){
$('#group-tab a:first').tab('show');
$('#group-tab a[href$="'+ window.location.hash +'"]').tab("show");
} else {
$('#group-tab a:first').tab('show');
}
$('.snippet-toggle').on("click", function(e) {
e.preventDefault();
var target = $(this).data('target');
$(this).parent().next().toggle();
if ($(this).text() == "SHOW") {
$(this).text("HIDE");
} else {
$(this).text("SHOW");
}
});
});
</script>
</body>
</html>