-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
120 lines (109 loc) · 4.61 KB
/
index.html
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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
<!doctype html>
<html>
<head>
<title>Easy HttpStatus</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" href="style.css" type="text/css">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
<meta name="author" content="Vardan Torosyan">
<meta name="copyright" content="vtorosyan.github.io">
<meta name="summary" content="Easy HttpStatus">
<meta name="description" content="Choosing HTTP Status made easy">
</head>
<body>
<div class="container">
<div id="root">
<div class="progress">
<div class="progress-bar progress-bar-striped active" style="width: 100%">
Loading...
</div>
</div>
</div>
</div>
<script type="text/html" id="easy-http-status-app">
{{#partial introductionComponent}}
<div class="jumbotron vertical-center">
<div class="container-fluid text-center">
<div class="row extra-bottom-padding vertical-center-row">
<div class="col-xs-12">
<h4><i>Easy HttpStatus</i> is designated to make choosing an HTTP status for RESTful APIs easy. <br/><br/> By answering to the simple questions with <b>Yes</b> or <b>No</b>, it gives you the status code with a short description which can/should be used.</h4>
</div>
</div>
<div class="row">
<div class="col-xs-12 text-center">
<a href="#" class="btn btn-success start" role="button" on-click="start">Start</a>
</div>
</div>
</div>
</div>
{{/partial}}
{{#partial answerComponent}}
<div class="jumbotron vertical-center">
<div class="container-fluid text-center">
<div class="row extra-bottom-padding vertical-center-row">
<div class="col-xs-12 " style="color: forestgreen">
<h2><a target="_blank" href="{{answer['source']}}">{{answer['code']}}</a></h2>
</div>
</div>
<div class="row extra-bottom-padding vertical-center-row">
<div class="col-xs-12 ">
{{answer['description']}}
</div>
</div>
<div class="row">
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" on-click="go-back:{{currentItem}}">Go
Back</a>
</div>
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" on-click="restart">Start Again</a>
</div>
</div>
</div>
</div>
{{/partial}}
{{#partial questionComponent}}
<div class="jumbotron vertical-center">
<div class="container-fluid text-center">
<div class="row extra-bottom-padding vertical-center-row">
<div class="col-xs-12 ">
<h3>{{currentItem['question']}}</h3>
</div>
</div>
<div class="row bottom-padding">
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" on-click="answer-yes:{{currentItem}}">Yes</a>
</div>
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" role="button"
on-click="answer-no:{{currentItem}}">No
</div>
</div>
{{#if hasPrevious}}
<div class="row">
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" on-click="go-back:{{currentItem}}">Go
Back</a>
</div>
<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6">
<a href="#" class="btn btn-default btn-block" role="button" on-click="restart">Start Again</a>
</div>
</div>
{{/if}}
</div>
</div>
{{/partial}}
{{#if answer}}
{{> answerComponent}}
{{elseif isIntroduction}}
{{> introductionComponent}}
{{else}}
{{> questionComponent}}
{{/if}}
</script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/ractive/0.7.3/ractive.min.js'></script>
<script src="data.js"></script>
<script src="main.js"></script>
</body>
</html>