summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYukai Huang2017-01-21 14:05:51 +0800
committerYukai Huang2017-01-21 14:05:51 +0800
commit0e479111e55354434b5100ae165627f5fabe06b5 (patch)
tree451aced97ba8a111a9635a2e0d113aa8fcc7d5b7
parent74b04d08b5a4cf51ba71dd1ea12388974e74f4df (diff)
parenta669c201beb3755703e87984268cbd08145e9ac6 (diff)
Merge branch 'master' into es6-integration
Diffstat (limited to '')
-rw-r--r--public/views/error.ejs6
-rw-r--r--public/views/hackmd.ejs12
-rw-r--r--public/views/hackmd/body.ejs (renamed from public/views/body.ejs)8
-rw-r--r--public/views/hackmd/foot.ejs (renamed from public/views/foot.ejs)4
-rw-r--r--public/views/hackmd/footer.ejs (renamed from public/views/footer.ejs)0
-rw-r--r--public/views/hackmd/head.ejs (renamed from public/views/head.ejs)6
-rw-r--r--public/views/hackmd/header.ejs (renamed from public/views/header.ejs)0
-rw-r--r--public/views/index.ejs216
-rw-r--r--public/views/index/body.ejs175
-rw-r--r--public/views/index/foot.ejs13
-rw-r--r--public/views/index/footer.ejs0
-rw-r--r--public/views/index/head.ejs22
-rw-r--r--public/views/index/header.ejs0
-rw-r--r--public/views/pretty.ejs6
-rw-r--r--public/views/shared/disqus.ejs (renamed from public/views/disqus.ejs)0
-rw-r--r--public/views/shared/ga.ejs (renamed from public/views/ga.ejs)0
-rw-r--r--public/views/shared/help-modal.ejs (renamed from public/views/help-modal.ejs)0
-rw-r--r--public/views/shared/polyfill.ejs (renamed from public/views/polyfill.ejs)0
-rw-r--r--public/views/shared/refresh-modal.ejs (renamed from public/views/refresh-modal.ejs)0
-rw-r--r--public/views/shared/revision-modal.ejs (renamed from public/views/revision-modal.ejs)0
-rw-r--r--public/views/shared/signin-modal.ejs (renamed from public/views/signin-modal.ejs)0
-rw-r--r--public/views/slide.ejs6
22 files changed, 239 insertions, 235 deletions
diff --git a/public/views/error.ejs b/public/views/error.ejs
index 402b5eb0..a40ed39c 100644
--- a/public/views/error.ejs
+++ b/public/views/error.ejs
@@ -2,18 +2,18 @@
<html lang="en">
<head>
- <%- include head %>
+ <%- include hackmd/head %>
<link rel="stylesheet" href="<%- url %>/css/center.css">
</head>
<body>
- <%- include header %>
+ <%- include hackmd/header %>
<div class="container-fluid text-center">
<div class="vertical-center-row">
<h1><%- code %> <%- detail %> <small><%- msg %></small></h1>
</div>
</div>
- <%- include footer %>
+ <%- include hackmd/footer %>
</body>
</html> \ No newline at end of file
diff --git a/public/views/hackmd.ejs b/public/views/hackmd.ejs
index c5778fc9..49084a63 100644
--- a/public/views/hackmd.ejs
+++ b/public/views/hackmd.ejs
@@ -2,14 +2,14 @@
<html lang="en">
<head>
- <%- include head %>
+ <%- include hackmd/head %>
</head>
<body>
- <%- include header %>
- <%- include body %>
- <%- include footer %>
- <%- include foot %>
+ <%- include hackmd/header %>
+ <%- include hackmd/body %>
+ <%- include hackmd/footer %>
+ <%- include hackmd/foot %>
</body>
-</html> \ No newline at end of file
+</html>
diff --git a/public/views/body.ejs b/public/views/hackmd/body.ejs
index 5ad1733e..d8a3f108 100644
--- a/public/views/body.ejs
+++ b/public/views/hackmd/body.ejs
@@ -244,7 +244,7 @@
</div>
</div>
</div>
-<%- include refresh-modal %>
-<%- include signin-modal %>
-<%- include help-modal %>
-<%- include revision-modal %>
+<%- include ../shared/refresh-modal %>
+<%- include ../shared/signin-modal %>
+<%- include ../shared/help-modal %>
+<%- include ../shared/revision-modal %>
diff --git a/public/views/foot.ejs b/public/views/hackmd/foot.ejs
index c1df65c2..178b5504 100644
--- a/public/views/foot.ejs
+++ b/public/views/hackmd/foot.ejs
@@ -20,9 +20,9 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/gist-embed/2.6.0/gist-embed.min.js" integrity="sha256-KyF2D6xPIJUW5sUDSs93vWyZm+1RzIpKCexxElmxl8g=" crossorigin="anonymous" defer></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/viz.js/1.4.1/viz.js" integrity="sha256-U0a9HpXT7zG0N3tVzo58B5S+QXUxo4FdBIjrBMYrxZI=" crossorigin="anonymous" defer></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/1000hz-bootstrap-validator/0.11.8/validator.min.js" integrity="sha256-LHeY7YoYJ0SSXbCx7sR14Pqna+52moaH3bhv0Mjzd/M=" crossorigin="anonymous" defer></script>
-<%- include build/index-scripts %>
+<%- include ../build/index-scripts %>
<% } else { %>
<script src="<%- url %>/build/MathJax/MathJax.js" defer></script>
<script src="<%- url %>/build/MathJax/config/TeX-AMS-MML_HTMLorMML.js" defer></script>
-<%- include build/index-pack-scripts %>
+<%- include ../build/index-pack-scripts %>
<% } %>
diff --git a/public/views/footer.ejs b/public/views/hackmd/footer.ejs
index e69de29b..e69de29b 100644
--- a/public/views/footer.ejs
+++ b/public/views/hackmd/footer.ejs
diff --git a/public/views/head.ejs b/public/views/hackmd/head.ejs
index 218847f7..d0663993 100644
--- a/public/views/head.ejs
+++ b/public/views/hackmd/head.ejs
@@ -14,9 +14,9 @@
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css" integrity="sha256-3iu9jgsy9TpTwXKb7bNQzqWekRX7pPK+2OLj3R922fo=" crossorigin="anonymous" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/octicons/3.5.0/octicons.min.css" integrity="sha256-QiWfLIsCT02Sdwkogf6YMiQlj4NE84MKkzEMkZnMGdg=" crossorigin="anonymous" />
<link rel="stylesheet" href='<%- url %>/build/emojify.js/dist/css/basic/emojify.min.css'>
-<%- include build/index-header %>
+<%- include ../build/index-header %>
<% } else { %>
<link rel="stylesheet" href='<%- url %>/build/emojify.js/dist/css/basic/emojify.min.css'>
-<%- include build/index-pack-header %>
+<%- include ../build/index-pack-header %>
<% } %>
-<%- include polyfill %> \ No newline at end of file
+<%- include ../shared/polyfill %> \ No newline at end of file
diff --git a/public/views/header.ejs b/public/views/hackmd/header.ejs
index bb4e3174..bb4e3174 100644
--- a/public/views/header.ejs
+++ b/public/views/hackmd/header.ejs
diff --git a/public/views/index.ejs b/public/views/index.ejs
index 4bcea0eb..5732db4a 100644
--- a/public/views/index.ejs
+++ b/public/views/index.ejs
@@ -2,220 +2,14 @@
<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.0, user-scalable=no">
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="black">
- <meta name="mobile-web-app-capable" content="yes">
- <meta name="description" content="<%= __('Best way to write and share your knowledge in markdown.') %>">
- <meta name="keywords" content="Collaborative, Markdown, Notes">
- <title>HackMD - <%= __('Collaborative markdown notes') %></title>
- <link rel="icon" type="image/png" href="<%- url %>/favicon.png">
- <link rel="apple-touch-icon" href="<%- url %>/apple-touch-icon.png">
- <% if(useCDN) { %>
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w=" crossorigin="anonymous" />
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous" />
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-social/4.9.0/bootstrap-social.min.css" integrity="sha256-02JtFTurpwBjQJ6q13iJe82/NF0RbZlJroDegK5g87Y=" crossorigin="anonymous" />
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.4/select2.min.css" integrity="sha256-ijlUKKj3hJCiiT2HWo1kqkI79NTEYpzOsw5Rs3k42dI=" crossorigin="anonymous" />
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.4/select2-bootstrap.min.css" integrity="sha256-NAWFcNIZdH+TS1xpWujF/EB/Y8gwBbEOCoaK/eqaer8=" crossorigin="anonymous" />
- <%- include build/cover-header %>
- <% } else { %>
- <%- include build/cover-pack-header %>
- <% } %>
- <%- include polyfill %>
+ <%- include index/head %>
</head>
<body>
- <div class="site-wrapper">
- <div class="site-wrapper-inner">
- <div class="cover-container">
-
- <div class="masthead clearfix">
- <div class="inner">
- <h3 class="masthead-brand"></h3>
- <nav>
- <ul class="nav masthead-nav">
- <li class="ui-home<% if(!signin) { %> active<% } %>"><a href="#"><%= __('Intro') %></a>
- </li>
- <li class="ui-history<% if(signin) { %> active<% } %>"><a href="#"><%= __('History') %></a>
- </li>
- <div class="ui-signin" style="float: right; margin-top: 8px;<% if(signin) { %> display: none;<% } %>">
- <% if(allowAnonymous) { %>
- <a type="button" href="<%- url %>/new" class="btn btn-sm btn-link"><i class="fa fa-plus"></i> <%= __('New guest note') %></a>
- <% } %>
- <% if(facebook || twitter || github || gitlab || dropbox || google || ldap || email) { %>
- <button class="btn btn-sm btn-success ui-signin" data-toggle="modal" data-target=".signin-modal"><%= __('Sign In') %></button>
- <% } %>
- </div>
- <div class="ui-signout" style="float: right; margin-top: 8px;<% if(!signin) { %> display: none;<% } %>">
- <a type="button" href="<%- url %>/new" class="btn btn-sm btn-link"><i class="fa fa-plus"></i> <%= __('New note') %></a>
- <span class="ui-profile dropdown pull-right">
- <button id="profileLabel" class="btn btn-sm btn-link ui-profile-label" style="padding-right: 0;" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
- <img class="ui-avatar" width="20" height="20"><span class="hidden-xs hidden-sm">&ensp;<span class="ui-name"></span></span>&ensp;<i class="fa fa-caret-down"></i>
- </button>
- <ul class="dropdown-menu" aria-labelledby="profileLabel">
- <li><a href="<%- url %>/logout"><i class="fa fa-sign-out fa-fw"></i> <%= __('Sign Out') %></a></li>
- </ul>
- </span>
- </div>
- </ul>
- </nav>
- </div>
- </div>
-
- <div id="home" class="section"<% if(signin) { %> style="display:none;"<% } %>>
- <div class="inner cover">
- <h1 class="cover-heading"><i class="fa fa-file-text"></i> HackMD</h1>
- <p class="lead">
- <%= __('Best way to write and share your knowledge in markdown.') %>
- </p>
- <% if (infoMessage && infoMessage.length > 0) { %>
- <div class="alert alert-info" style="max-width: 400px; margin: 0 auto;"><%= infoMessage %></div>
- <% } %>
- <% if (errorMessage && errorMessage.length > 0) { %>
- <div class="alert alert-danger" style="max-width: 400px; margin: 0 auto;"><%= errorMessage %></div>
- <% } %>
- <% if(facebook || twitter || github || gitlab || dropbox || google || ldap || email) { %>
- <span class="ui-signin">
- <br>
- <a type="button" class="btn btn-lg btn-success ui-signin" data-toggle="modal" data-target=".signin-modal" style="min-width: 200px;"><%= __('Sign In') %></a>
- </span>
- <span class="ui-or"><%= __('or') %></span>
- <% } %>
- <span class="ui-signin">
- <a type="button" href="<%- url %>/features" class="btn btn-lg btn-primary" style="min-width: 200px;"><%= __('Explore all features') %></a>
- <br>
- <br>
- <img src="<%- url %>/screenshot.png" class="screenshot ui-signin">
- </span>
- <div class="lead row" style="width: 90%; margin: 0 auto;">
- <div class="col-md-4 inner">
- <a href="<%- url %>/features#share-notes">
- <i class="fa fa-bolt fa-3x"></i>
- <h4><%= __('Collaborate with URL') %></h4>
- </a>
- </div>
- <div class="col-md-4 inner">
- <a href="<%- url %>/features#mathjax">
- <i class="fa fa-bar-chart fa-3x"></i>
- <h4><%= __('Support charts and MathJax') %></h4>
- </a>
- </div>
- <div class="col-md-4 inner">
- <a href="<%- url %>/features#slide-mode">
- <i class="fa fa-tv fa-3x"></i>
- <h4><%= __('Support slide mode') %></h4>
- </a>
- </div>
- </div>
- </div>
- </div>
-
- <div id="history" class="section"<% if(!signin) { %> style="display:none;"<% } %>>
- <div class="ui-signin"<% if(signin) { %> style="display:none;"<% } %>>
- <p><%= __('Below is the history from browser') %></p>
- </div>
- <br>
- <form class="form-inline">
- <div class="form-group" style="vertical-align: bottom;">
- <input class="form-control ui-use-tags" placeholder="<%= __('Select tags...') %>" />
- </div>
- <div class="form-group">
- <input class="search form-control" placeholder="<%= __('Search keyword...') %>" />
- </div>
- <a href="#" class="sort btn btn-default" data-sort="text" title="<%= __('Sort by title') %>">
- <%= __('Title') %>
- </a>
- <a href="#" class="sort btn btn-default" data-sort="timestamp" title="<%= __('Sort by time') %>">
- <%= __('Time') %>
- </a>
- <span class="hidden-xs hidden-sm">
- <a href="#" class="btn btn-default ui-save-history" title="<%= __('Export history') %>"><i class="fa fa-save"></i></a>
- <span class="btn btn-default btn-file ui-open-history" title="<%= __('Import history') %>">
- <i class="fa fa-folder-open-o"></i><input type="file" />
- </span>
- <a href="#" class="btn btn-default ui-clear-history" title="<%= __('Clear history') %>" data-toggle="modal" data-target=".delete-modal"><i class="fa fa-trash-o"></i></a>
- </span>
- <a href="#" class="btn btn-default ui-refresh-history" title="<%= __('Refresh history') %>"><i class="fa fa-refresh"></i></a>
- </form>
- <h4 class="ui-nohistory" style="display:none;">
- <%= __('No history') %>
- </h4>
- <a href="#" class="btn btn-primary ui-import-from-browser" style="display:none;"><%= __('Import from browser') %></a>
- <ul id="history-list" class="list">
- </ul>
- <ul class="pagination"></ul>
- </div>
-
- <div class="mastfoot">
- <div class="inner">
- <h6 class="social-foot">
- <iframe src="//ghbtns.com/github-btn.html?user=hackmdio&repo=hackmd&type=star&count=true" frameborder="0" scrolling="0" width="104px" height="20px"></iframe>
- </h6>
- <p>
- &copy; 2017 <a href="https://www.facebook.com/hackmdio" target="_blank"><i class="fa fa-facebook-square"></i> HackMD</a> | <a href="<%- url %>/s/release-notes" target="_blank"><%= __('Releases') %></a>
- </p>
- <select class="ui-locale">
- <option value="en">English</option>
- <option value="zh">中文</option>
- <option value="fr">Français</option>
- <option value="de">Deutsch</option>
- <option value="ja">日本語</option>
- <option value="es">Español</option>
- <option value="el">Ελληνικά</option>
- <option value="pt">Português</option>
- <option value="it">italiano</option>
- <option value="tr">Türkçe</option>
- <option value="ru">Русский</option>
- <option value="nl">Nederlands</option>
- <option value="hr">hrvatski jezik</option>
- <option value="pl">język polski</option>
- <option value="uk">Українська</option>
- <option value="hi">हिन्दी</option>
- <option value="sv">svenska</option>
- <option value="eo">Esperanto</option>
- </select>
- </div>
- </div>
- </div>
- </div>
- </div>
- <!-- delete modal -->
- <div class="modal fade delete-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
- <div class="modal-dialog modal-sm">
- <div class="modal-content">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span>
- </button>
- <h4 class="modal-title" id="myModalLabel"><%= __('Are you sure?') %></h4>
- </div>
- <div class="modal-body" style="color:black;">
- <h5 class="ui-delete-modal-msg"></h5>
- <strong class="ui-delete-modal-item"></strong>
- </div>
- <div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal"><%= __('Cancel') %></button>
- <button type="button" class="btn btn-danger ui-delete-modal-confirm"><%= __('Yes, do it!') %></button>
- </div>
- </div>
- </div>
- </div>
- <%- include signin-modal %>
-
- <% if(useCDN) { %>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js" integrity="sha256-hVVnYaiADRTO2PzUGmuLJr8BLUSjGIZsDYGmIJLv2b8=" crossorigin="anonymous"></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/velocity/1.4.0/velocity.min.js" integrity="sha256-bhm0lgEt6ITaZCDzZpkr/VXVrLa5RP4u9v2AYsbzSUk=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/list.pagination.js/0.1.1/list.pagination.min.js" integrity="sha256-WwTza96H3BgcQTfEfxX7MFaFc/dZA0QrPRKDRLdFHJo=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.2/select2.min.js" integrity="sha256-HzzZFiY4t0PIv02Tm8/R3CVvLpcjHhO1z/YAUCp4oQ4=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.17.1/moment-with-locales.min.js" integrity="sha256-vvT7Ok9u6GbfnBPXnbM6FVDEO8E1kTdgHOFZOAXrktA=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/js-url/2.3.0/url.min.js" integrity="sha256-HOZJz4x+1mn1Si84WT5XKXPtOlTytmZLnMb6n1v4+5Q=" crossorigin="anonymous" defer></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/1000hz-bootstrap-validator/0.11.8/validator.min.js" integrity="sha256-LHeY7YoYJ0SSXbCx7sR14Pqna+52moaH3bhv0Mjzd/M=" crossorigin="anonymous" defer></script>
- <%- include build/cover-scripts %>
- <% } else { %>
- <%- include build/cover-pack-scripts %>
- <% } %>
+ <%- include index/header %>
+ <%- include index/body %>
+ <%- include index/footer %>
+ <%- include index/foot %>
</body>
</html>
diff --git a/public/views/index/body.ejs b/public/views/index/body.ejs
new file mode 100644
index 00000000..b8072450
--- /dev/null
+++ b/public/views/index/body.ejs
@@ -0,0 +1,175 @@
+<div class="site-wrapper">
+ <div class="site-wrapper-inner">
+ <div class="cover-container">
+
+ <div class="masthead clearfix">
+ <div class="inner">
+ <h3 class="masthead-brand"></h3>
+ <nav>
+ <ul class="nav masthead-nav">
+ <li class="ui-home<% if(!signin) { %> active<% } %>"><a href="#"><%= __('Intro') %></a>
+ </li>
+ <li class="ui-history<% if(signin) { %> active<% } %>"><a href="#"><%= __('History') %></a>
+ </li>
+ <div class="ui-signin" style="float: right; margin-top: 8px;<% if(signin) { %> display: none;<% } %>">
+ <% if(allowAnonymous) { %>
+ <a type="button" href="<%- url %>/new" class="btn btn-sm btn-link"><i class="fa fa-plus"></i> <%= __('New guest note') %></a>
+ <% } %>
+ <% if(facebook || twitter || github || gitlab || dropbox || google || ldap || email) { %>
+ <button class="btn btn-sm btn-success ui-signin" data-toggle="modal" data-target=".signin-modal"><%= __('Sign In') %></button>
+ <% } %>
+ </div>
+ <div class="ui-signout" style="float: right; margin-top: 8px;<% if(!signin) { %> display: none;<% } %>">
+ <a type="button" href="<%- url %>/new" class="btn btn-sm btn-link"><i class="fa fa-plus"></i> <%= __('New note') %></a>
+ <span class="ui-profile dropdown pull-right">
+ <button id="profileLabel" class="btn btn-sm btn-link ui-profile-label" style="padding-right: 0;" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
+ <img class="ui-avatar" width="20" height="20"><span class="hidden-xs hidden-sm">&ensp;<span class="ui-name"></span></span>&ensp;<i class="fa fa-caret-down"></i>
+ </button>
+ <ul class="dropdown-menu" aria-labelledby="profileLabel">
+ <li><a href="<%- url %>/logout"><i class="fa fa-sign-out fa-fw"></i> <%= __('Sign Out') %></a></li>
+ </ul>
+ </span>
+ </div>
+ </ul>
+ </nav>
+ </div>
+ </div>
+
+ <div id="home" class="section"<% if(signin) { %> style="display:none;"<% } %>>
+ <div class="inner cover">
+ <h1 class="cover-heading"><i class="fa fa-file-text"></i> HackMD</h1>
+ <p class="lead">
+ <%= __('Best way to write and share your knowledge in markdown.') %>
+ </p>
+ <% if (infoMessage && infoMessage.length > 0) { %>
+ <div class="alert alert-info" style="max-width: 400px; margin: 0 auto;"><%= infoMessage %></div>
+ <% } %>
+ <% if (errorMessage && errorMessage.length > 0) { %>
+ <div class="alert alert-danger" style="max-width: 400px; margin: 0 auto;"><%= errorMessage %></div>
+ <% } %>
+ <% if(facebook || twitter || github || gitlab || dropbox || google || ldap || email) { %>
+ <span class="ui-signin">
+ <br>
+ <a type="button" class="btn btn-lg btn-success ui-signin" data-toggle="modal" data-target=".signin-modal" style="min-width: 200px;"><%= __('Sign In') %></a>
+ </span>
+ <span class="ui-or"><%= __('or') %></span>
+ <% } %>
+ <span class="ui-signin">
+ <a type="button" href="<%- url %>/features" class="btn btn-lg btn-primary" style="min-width: 200px;"><%= __('Explore all features') %></a>
+ <br>
+ <br>
+ <img src="<%- url %>/screenshot.png" class="screenshot ui-signin">
+ </span>
+ <div class="lead row" style="width: 90%; margin: 0 auto;">
+ <div class="col-md-4 inner">
+ <a href="<%- url %>/features#share-notes">
+ <i class="fa fa-bolt fa-3x"></i>
+ <h4><%= __('Collaborate with URL') %></h4>
+ </a>
+ </div>
+ <div class="col-md-4 inner">
+ <a href="<%- url %>/features#mathjax">
+ <i class="fa fa-bar-chart fa-3x"></i>
+ <h4><%= __('Support charts and MathJax') %></h4>
+ </a>
+ </div>
+ <div class="col-md-4 inner">
+ <a href="<%- url %>/features#slide-mode">
+ <i class="fa fa-tv fa-3x"></i>
+ <h4><%= __('Support slide mode') %></h4>
+ </a>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div id="history" class="section"<% if(!signin) { %> style="display:none;"<% } %>>
+ <div class="ui-signin"<% if(signin) { %> style="display:none;"<% } %>>
+ <p><%= __('Below is the history from browser') %></p>
+ </div>
+ <br>
+ <form class="form-inline">
+ <div class="form-group" style="vertical-align: bottom;">
+ <input class="form-control ui-use-tags" placeholder="<%= __('Select tags...') %>" />
+ </div>
+ <div class="form-group">
+ <input class="search form-control" placeholder="<%= __('Search keyword...') %>" />
+ </div>
+ <a href="#" class="sort btn btn-default" data-sort="text" title="<%= __('Sort by title') %>">
+ <%= __('Title') %>
+ </a>
+ <a href="#" class="sort btn btn-default" data-sort="timestamp" title="<%= __('Sort by time') %>">
+ <%= __('Time') %>
+ </a>
+ <span class="hidden-xs hidden-sm">
+ <a href="#" class="btn btn-default ui-save-history" title="<%= __('Export history') %>"><i class="fa fa-save"></i></a>
+ <span class="btn btn-default btn-file ui-open-history" title="<%= __('Import history') %>">
+ <i class="fa fa-folder-open-o"></i><input type="file" />
+ </span>
+ <a href="#" class="btn btn-default ui-clear-history" title="<%= __('Clear history') %>" data-toggle="modal" data-target=".delete-modal"><i class="fa fa-trash-o"></i></a>
+ </span>
+ <a href="#" class="btn btn-default ui-refresh-history" title="<%= __('Refresh history') %>"><i class="fa fa-refresh"></i></a>
+ </form>
+ <h4 class="ui-nohistory" style="display:none;">
+ <%= __('No history') %>
+ </h4>
+ <a href="#" class="btn btn-primary ui-import-from-browser" style="display:none;"><%= __('Import from browser') %></a>
+ <ul id="history-list" class="list">
+ </ul>
+ <ul class="pagination"></ul>
+ </div>
+
+ <div class="mastfoot">
+ <div class="inner">
+ <h6 class="social-foot">
+ <iframe src="//ghbtns.com/github-btn.html?user=hackmdio&repo=hackmd&type=star&count=true" frameborder="0" scrolling="0" width="104px" height="20px"></iframe>
+ </h6>
+ <p>
+ &copy; 2017 <a href="https://www.facebook.com/hackmdio" target="_blank"><i class="fa fa-facebook-square"></i> HackMD</a> | <a href="<%- url %>/s/release-notes" target="_blank"><%= __('Releases') %></a>
+ </p>
+ <select class="ui-locale">
+ <option value="en">English</option>
+ <option value="zh">中文</option>
+ <option value="fr">Français</option>
+ <option value="de">Deutsch</option>
+ <option value="ja">日本語</option>
+ <option value="es">Español</option>
+ <option value="el">Ελληνικά</option>
+ <option value="pt">Português</option>
+ <option value="it">italiano</option>
+ <option value="tr">Türkçe</option>
+ <option value="ru">Русский</option>
+ <option value="nl">Nederlands</option>
+ <option value="hr">hrvatski jezik</option>
+ <option value="pl">język polski</option>
+ <option value="uk">Українська</option>
+ <option value="hi">हिन्दी</option>
+ <option value="sv">svenska</option>
+ <option value="eo">Esperanto</option>
+ </select>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+<!-- delete modal -->
+<div class="modal fade delete-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
+ <div class="modal-dialog modal-sm">
+ <div class="modal-content">
+ <div class="modal-header">
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span>
+ </button>
+ <h4 class="modal-title" id="myModalLabel"><%= __('Are you sure?') %></h4>
+ </div>
+ <div class="modal-body" style="color:black;">
+ <h5 class="ui-delete-modal-msg"></h5>
+ <strong class="ui-delete-modal-item"></strong>
+ </div>
+ <div class="modal-footer">
+ <button type="button" class="btn btn-default" data-dismiss="modal"><%= __('Cancel') %></button>
+ <button type="button" class="btn btn-danger ui-delete-modal-confirm"><%= __('Yes, do it!') %></button>
+ </div>
+ </div>
+ </div>
+</div>
+<%- include ../shared/signin-modal %> \ No newline at end of file
diff --git a/public/views/index/foot.ejs b/public/views/index/foot.ejs
new file mode 100644
index 00000000..293c6698
--- /dev/null
+++ b/public/views/index/foot.ejs
@@ -0,0 +1,13 @@
+<% if(useCDN) { %>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js" integrity="sha256-hVVnYaiADRTO2PzUGmuLJr8BLUSjGIZsDYGmIJLv2b8=" crossorigin="anonymous"></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/velocity/1.4.0/velocity.min.js" integrity="sha256-bhm0lgEt6ITaZCDzZpkr/VXVrLa5RP4u9v2AYsbzSUk=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/list.pagination.js/0.1.1/list.pagination.min.js" integrity="sha256-WwTza96H3BgcQTfEfxX7MFaFc/dZA0QrPRKDRLdFHJo=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.2/select2.min.js" integrity="sha256-HzzZFiY4t0PIv02Tm8/R3CVvLpcjHhO1z/YAUCp4oQ4=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.17.1/moment-with-locales.min.js" integrity="sha256-vvT7Ok9u6GbfnBPXnbM6FVDEO8E1kTdgHOFZOAXrktA=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/js-url/2.3.0/url.min.js" integrity="sha256-HOZJz4x+1mn1Si84WT5XKXPtOlTytmZLnMb6n1v4+5Q=" crossorigin="anonymous" defer></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/1000hz-bootstrap-validator/0.11.8/validator.min.js" integrity="sha256-LHeY7YoYJ0SSXbCx7sR14Pqna+52moaH3bhv0Mjzd/M=" crossorigin="anonymous" defer></script>
+<%- include ../build/cover-scripts %>
+<% } else { %>
+<%- include ../build/cover-pack-scripts %>
+<% } %> \ No newline at end of file
diff --git a/public/views/index/footer.ejs b/public/views/index/footer.ejs
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/public/views/index/footer.ejs
diff --git a/public/views/index/head.ejs b/public/views/index/head.ejs
new file mode 100644
index 00000000..bbd14567
--- /dev/null
+++ b/public/views/index/head.ejs
@@ -0,0 +1,22 @@
+<meta charset="utf-8">
+<meta http-equiv="X-UA-Compatible" content="IE=edge">
+<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
+<meta name="apple-mobile-web-app-capable" content="yes">
+<meta name="apple-mobile-web-app-status-bar-style" content="black">
+<meta name="mobile-web-app-capable" content="yes">
+<meta name="description" content="<%= __('Best way to write and share your knowledge in markdown.') %>">
+<meta name="keywords" content="Collaborative, Markdown, Notes">
+<title>HackMD - <%= __('Collaborative markdown notes') %></title>
+<link rel="icon" type="image/png" href="<%- url %>/favicon.png">
+<link rel="apple-touch-icon" href="<%- url %>/apple-touch-icon.png">
+<% if(useCDN) { %>
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w=" crossorigin="anonymous" />
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous" />
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-social/4.9.0/bootstrap-social.min.css" integrity="sha256-02JtFTurpwBjQJ6q13iJe82/NF0RbZlJroDegK5g87Y=" crossorigin="anonymous" />
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.4/select2.min.css" integrity="sha256-ijlUKKj3hJCiiT2HWo1kqkI79NTEYpzOsw5Rs3k42dI=" crossorigin="anonymous" />
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/select2/3.5.4/select2-bootstrap.min.css" integrity="sha256-NAWFcNIZdH+TS1xpWujF/EB/Y8gwBbEOCoaK/eqaer8=" crossorigin="anonymous" />
+<%- include ../build/cover-header %>
+<% } else { %>
+<%- include ../build/cover-pack-header %>
+<% } %>
+<%- include ../shared/polyfill %> \ No newline at end of file
diff --git a/public/views/index/header.ejs b/public/views/index/header.ejs
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/public/views/index/header.ejs
diff --git a/public/views/pretty.ejs b/public/views/pretty.ejs
index ced65ed8..a6913f6c 100644
--- a/public/views/pretty.ejs
+++ b/public/views/pretty.ejs
@@ -28,7 +28,7 @@
<link rel="stylesheet" href='<%- url %>/build/emojify.js/dist/css/basic/emojify.min.css'>
<%- include build/pretty-pack-header %>
<% } %>
- <%- include polyfill %>
+ <%- include shared/polyfill %>
</head>
<body style="display:none;">
@@ -66,7 +66,7 @@
<div id="ui-toc-affix" class="ui-affix-toc ui-toc-dropdown unselectable hidden-print" data-spy="affix" style="display:none;"></div>
<% if(typeof disqus !== 'undefined' && disqus) { %>
<div class="container-fluid" style="max-width: 758px; margin-bottom: 40px;">
- <%- include disqus %>
+ <%- include shared/disqus %>
</div>
<% } %>
</body>
@@ -96,4 +96,4 @@
<script src="<%- url %>/build/MathJax/config/TeX-AMS-MML_HTMLorMML.js" defer></script>
<%- include build/pretty-pack-scripts %>
<% } %>
-<%- include ga %>
+<%- include shared/ga %>
diff --git a/public/views/disqus.ejs b/public/views/shared/disqus.ejs
index cceaa85c..cceaa85c 100644
--- a/public/views/disqus.ejs
+++ b/public/views/shared/disqus.ejs
diff --git a/public/views/ga.ejs b/public/views/shared/ga.ejs
index 66d4acd9..66d4acd9 100644
--- a/public/views/ga.ejs
+++ b/public/views/shared/ga.ejs
diff --git a/public/views/help-modal.ejs b/public/views/shared/help-modal.ejs
index b1ea681d..b1ea681d 100644
--- a/public/views/help-modal.ejs
+++ b/public/views/shared/help-modal.ejs
diff --git a/public/views/polyfill.ejs b/public/views/shared/polyfill.ejs
index 5c885642..5c885642 100644
--- a/public/views/polyfill.ejs
+++ b/public/views/shared/polyfill.ejs
diff --git a/public/views/refresh-modal.ejs b/public/views/shared/refresh-modal.ejs
index 5be41b2a..5be41b2a 100644
--- a/public/views/refresh-modal.ejs
+++ b/public/views/shared/refresh-modal.ejs
diff --git a/public/views/revision-modal.ejs b/public/views/shared/revision-modal.ejs
index f824cf06..f824cf06 100644
--- a/public/views/revision-modal.ejs
+++ b/public/views/shared/revision-modal.ejs
diff --git a/public/views/signin-modal.ejs b/public/views/shared/signin-modal.ejs
index a8af62e7..a8af62e7 100644
--- a/public/views/signin-modal.ejs
+++ b/public/views/shared/signin-modal.ejs
diff --git a/public/views/slide.ejs b/public/views/slide.ejs
index b0323a0e..ffbfdce6 100644
--- a/public/views/slide.ejs
+++ b/public/views/slide.ejs
@@ -45,7 +45,7 @@
document.getElementsByTagName( 'head' )[0].appendChild( link );
</script>
- <%- include polyfill %>
+ <%- include shared/polyfill %>
</head>
<body>
<div class="container">
@@ -79,7 +79,7 @@
</div>
<% if(typeof disqus !== 'undefined' && disqus) { %>
<div style="margin-top: 25px; margin-bottom: 15px;">
- <%- include disqus %>
+ <%- include shared/disqus %>
</div>
<% } %>
</div>
@@ -113,4 +113,4 @@
</body>
</html>
-<%- include ga %>
+<%- include shared/ga %>