-
Notifications
You must be signed in to change notification settings - Fork 13
/
index.html
108 lines (96 loc) · 5.42 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Showdown Live Editor</title>
<link href='http://fonts.googleapis.com/css?family=Old+Standard+TT:400,400italic,700' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,600' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/foundation/5.5.2/css/foundation.min.css">
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<link rel="apple-touch-icon" sizes="57x57" href="img/apple-touch-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="img/apple-touch-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="img/apple-touch-icon-72x72.png">
<link rel="apple-touch-icon" sizes="76x76" href="img/apple-touch-icon-76x76.png">
<link rel="apple-touch-icon" sizes="114x114" href="img/apple-touch-icon-114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="img/apple-touch-icon-120x120.png">
<link rel="apple-touch-icon" sizes="144x144" href="img/apple-touch-icon-144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="img/apple-touch-icon-152x152.png">
<link rel="apple-touch-icon" sizes="180x180" href="img/apple-touch-icon-180x180.png">
<link rel="icon" type="image/png" href="img/favicon-32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="img/android-chrome-192x192.png" sizes="192x192">
<link rel="icon" type="image/png" href="img/favicon-96x96.png" sizes="96x96">
<link rel="icon" type="image/png" href="img/favicon-16x16.png" sizes="16x16">
<link rel="manifest" href="manifest.json">
<meta name="msapplication-TileColor" content="#2b5797">
<meta name="msapplication-TileImage" content="img/mstile-144x144.png">
<meta name="theme-color" content="#ffffff">
<!-- conditional load of showdown's version based on the cookie -->
<script>
(function() {
function getCookie(name) {
var value = "; " + document.cookie;
var parts = value.split("; " + name + "=");
if (parts.length === 2) return parts.pop().split(";").shift();
}
var ver = getCookie('version') || 'develop',
url = 'https://rawgit.com/showdownjs/showdown/' + ver + '/dist/showdown.min.js',
scrp = document.createElement('script');
scrp.setAttribute("type","text/javascript");
scrp.src = url;
document.getElementsByTagName("head")[0].appendChild(scrp);
})();
</script>
</head>
<body data-ng-controller="editorCtrl">
<nav class="top-bar" data-topbar role="navigation" data-ng-include="'partials/nav.html'"></nav>
<div id="editor-wrapper" class="container">
<textarea id="editor" data-ng-model="text"></textarea>
<div id="preview" sd-model-to-html="text"></div>
</div>
<div class="lateral-menu" pageslide ps-open="checked" ps-side="left" ps-body-class="squeezed-body">
<div class="lateral-menu-content">
<div class="title">Options</div>
<div class="lateral-menu-content-inner">
<div ng-repeat="opt in checkOpts">
<input id="checkOpt-{{$id}}" ng-click="updateOptions(); repaint();" type="checkbox" ng-model="opt.value" />
<label for="checkOpt-{{$id}}" class="inline">{{opt.name}}</label>
</div>
<hr>
<div ng-repeat="opt in numOpts">
<label for="option-{opt.name}">{{opt.name}}</label>
<input id="option-{opt.name}" ng-change="updateOptions(); repaint();" type="number" ng-model="opt.value"/>
</div>
<div ng-repeat="opt in textOpts">
<label for="option-{opt.name}">{{opt.name}}</label>
<input id="textOption-{opt.name}" data-ng-change="updateOptions(); repaint();" type="text" ng-model="opt.value"/>
</div>
<div>
<label for="showdownVersion">Showdown Version</label>
<select id="showdownVersion" ng-model="version" ng-options="v for v in versions" ng-change="loadVersion()"></select>
</div>
</div>
</div>
</div>
<!-- modal -->
<div data-ng-hide="!showModal" class="modal-wrapper ng-hide">
<div class="modal-inner" aria-labelledby="modalTitle" aria-hidden="true" role="dialog">
<div class="modal-topbar">
<span><i> Limited to 1000 characters</i></span><a class="modal-close-btn" aria-label="Close" data-ng-click="showModal = false"><i class="fa fa-lg fa-close"></i></a>
</div>
<div class="link-area">
<textarea id="dlnk" style="resize: none;">{{hashTxt}}</textarea>
</div>
</div>
</div>
<!-- end modal -->
<script src="js/semver.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.7.5/angular.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.7.5/angular-sanitize.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.7.5/angular-animate.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.7.5/angular-route.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.7.5/angular-cookies.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular-pageslide-directive/2.2.0/angular-pageslide-directive.js" integrity="sha256-FW2YsacWIn83+j6c02CWOR8fuY4WyzbmmGwz7VOdEI0=" crossorigin="anonymous"></script>
<script src="js/editor.js"></script>
</body>
</html>