forked from ksky521/nodeppt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
markdown.ejs
executable file
·123 lines (122 loc) · 4.04 KB
/
markdown.ejs
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
121
122
123
<!--
Powered By nodePPT - This is probably the best web presentation tool so far!
version: <%= nodeppt_version %>
site: <%= nodeppt_site %>
-->
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title><%= title %> - By <%= speaker %></title>
<link rel="stylesheet" media="all" href="/css/nodeppt.css">
<link rel="stylesheet" media="only screen and (max-device-width: 480px)" href="/css/phone.css">
<%if (query && (query.print || query.pdf)) {%>
<link rel="stylesheet" media="all" href="/css/pdf.css">
<%}%>
<link rel="stylesheet" href="/js/highlight/styles/<%if (hasOwnProperty('highlightStyle') && highlightStyle!=='') { %><%- highlightStyle %><% }else{%>monokai_sublime<%}%>.css">
<link rel="stylesheet" href="/css/font-awesome.css">
<%- headFiles %>
</head>
<body>
<div class="slides">
<slides id="container">
<%- content %>
<%if (query && query.withThanks) {%>
<slide class="slide thank-you-slide segue nobackground">
<article class="flexbox vleft auto-fadein">
<h2>Q & A</h2>
<h3><Thank You!></h3>
</article>
</slide>
<%}%>
<slide class="slide logoslide dark nobackground">
<article class="flexbox vcenter">
<h2 style="color: white;">Powered By nodePPT v<%= nodeppt_version %></h2>
</article>
</slide>
<div class="slideTip" id="tip"></div>
</slides>
</div>
<canvas id="drawBoard" class="draw-board" width="900" height="700"></canvas>
<div class="progress"><span id="progress"></span></div>
<div id="_buttons">
<div class="_btn-box" id="_btn-box" style="display:none;">
<button class="fa fa-arrow-circle-left" id="_btn-prev"></button>
<button class="fa fa-arrow-circle-right" id="_btn-next"></button>
<button class="fa fa-paint-brush" id="_btn-brush"></button>
<button class="fa fa-compress" id="_btn-overview" data-toggle="fa fa-expand"></button>
</div>
<button class="fa fa-bars" id="_btn-bar" data-toggle="fa fa-close"></button>
</div>
<script src="/js/mixjs/lib/mix.0.3.0.min.js"></script>
<script>
var base = location.protocol + '//' + location.host;
<%if (hasOwnProperty('generate') && generate) { %>
var path = location.pathname.split('/').filter(function(v){
return !!v;
});
path.pop();
path = path.join('/');
MixJS.config({
baseURL: [ base, path, 'js'].join('/')+'/'
});
<% }else{ %>
MixJS.config({
baseURL: [ base, 'js'].join('/')+'/'
});
<% } %>
</script>
<script src="/js/mixjs/lib/event/broadcast.js"></script>
<script src="/js/nodeppt.js"></script>
<script>
Slide.init({
containerID: 'container',
drawBoardID: 'drawBoard',
slideClass: '.slide',
buildClass: '.build',
progressID: 'progress',
transition: '<%- transition %>',
width: 1100,
dir: './',
<% if (query && query.controller === 'socket'){ %>
control:{
type: 'socket',
args:{
isControl: <% if (query.iscontroller) {%>true<%} else{%> false<%}%>,
host: base,
clientId: "<% if (query.clientid) {%><%-query.clientid%><%} else{%> 0<%}%>",
//摇一摇
shake: <% if (!query.noshake) {%>true<%} else{%> false<%}%>
}
},
<% } else { %>
//打开下面的注释就开启postMessage方式
//访问网址127.0.0.1:8080/ppt/demo#client
control:{
type: 'postMessage',
args:{
isControl: <% if (query._multiscreen=='controller') {%>true<%} else{%> false<%}%>
}
},
<% } %>
tipID: 'tip'
});
MixJS.loadJS('/js/highlight/highlight.pack.js',function(){
hljs.tabReplace = ' ';
hljs.initHighlightingOnLoad();
});
</script>
<%- files %>
<% if (usemathjax == 'yes'){ %>
<!-- MathJax -->
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
config: ["TeX-AMS-MML_HTMLorMML.js"],
tex2jax: {inlineMath: [['\\(','\\)']]}});
//['$','$'], 避免货币价格冲突
</script>
<script type="text/javascript" src="/js/mathjax/MathJax.js"></script>
<% } %>
<!--placeholder-->
</body>
</html>