1
0
mirror of https://github.com/lxsang/antd-web-apps synced 2024-12-28 02:08:22 +01:00
antd-web-apps/blog/view/top.ls

121 lines
5.6 KiB
Plaintext
Raw Normal View History

2018-02-25 02:31:13 +01:00
<?lua
local arg = {...}
local title = arg[1]
2018-03-15 23:31:31 +01:00
local render = arg[2]
2018-06-25 18:10:07 +02:00
local url = arg[3]
local tags = arg[4]
2018-02-25 13:54:37 +01:00
local cls = ""
if HEADER.mobile then
cls = "navmobile"
end
2018-02-25 02:31:13 +01:00
?>
2018-02-23 19:52:10 +01:00
<!DOCTYPE html>
<html lang="en">
<head>
2018-02-25 02:31:13 +01:00
<title><?=title?></title>
2018-02-23 19:52:10 +01:00
<meta charset="UTF-8">
2018-03-18 14:22:15 +01:00
<!--meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' https://platform.twitter.com/widgets.js https://connect.facebook.net/en_US/sdk.js https://apis.google.com/js/plusone.js https://platform.twitter.com/js/button.556f0ea0e4da4e66cfdc182016dbd6db.js https://apis.google.com/_/scs/apps-static/_/js/k=oz.gapi.fr.G6aVHqjZQ7w.O/m=plusone/rt=j/sv=1/d=1/ed=1/am=AQE/rs=AGLTcCM3jVZaR98LsOLZhkxFJYLRGgZQ6A/cb=gapi.loaded_0 https://apis.google.com/_/scs/apps-static/_/js/k=oz.gapi.fr.G6aVHqjZQ7w.O/m=auth/exm=plusone/rt=j/sv=1/d=1/ed=1/am=AQE/rs=AGLTcCM3jVZaR98LsOLZhkxFJYLRGgZQ6A/cb=gapi.loaded_1"-->
2018-02-23 19:52:10 +01:00
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" href="rst/ubuntu-regular.css" />
<link rel="stylesheet" type="text/css" href="rst/font-awesome.css" />
<link rel="stylesheet" type="text/css" href="assets/style.css" />
2018-03-15 22:36:05 +01:00
<script src="rst/gscripts/riot.min.js"> </script>
<script src="rst/resources/antos_tags.js"></script>
2018-04-12 23:17:19 +02:00
<script src="rst/gscripts/jquery-3.2.1.min.js"> </script>
2018-03-15 22:36:05 +01:00
<script src="rst/main.js"></script>
2018-06-26 13:45:24 +02:00
<meta property="og:image" content="" />
2018-03-15 23:31:31 +01:00
<?lua if render then ?>
2018-06-26 10:56:53 +02:00
<meta name="twitter:card" content="summary" />
<meta name="twitter:site" content="@blog.lxsang.me" />
<meta name="twitter:creator" content="@lexsang" />
<meta property="og:url" content="<?=url?>" />
2018-06-26 13:45:24 +02:00
<meta property="og:type" content="article" />
2018-06-26 10:56:53 +02:00
<meta property="og:title" content="<?=title?>" />
<meta property="og:description" content="<?=tags?>" />
2018-04-12 23:17:19 +02:00
<link rel="stylesheet" type="text/css" href="rst/hljs/github.css" />
<link rel="stylesheet" type="text/css" href="rst/katex/katex.min.css" />
2018-03-15 23:31:31 +01:00
<script src="rst/hljs/highlight.pack.js"> </script>
<script src="rst/hljs/highlightjs-line-numbers.min.js"> </script>
2018-04-12 23:17:19 +02:00
<script src="rst/katex/katex.min.js"> </script>
<script src="rst/katex/auto-render.min.js"> </script>
2018-06-26 10:56:53 +02:00
<?lua else ?>
<meta property="og:url" content="https://blog.lxsang.me" />
2018-06-26 13:45:24 +02:00
<meta property="og:type" content="article" />
2018-06-26 10:56:53 +02:00
<meta property="og:title" content="Xuan Sang LE's blog" />
<meta property="og:description" content="My personal space" />
2018-03-15 23:31:31 +01:00
<?lua end ?>
<script>
2018-03-15 23:38:32 +01:00
2018-03-15 23:31:31 +01:00
<?lua if render then ?>
2018-03-15 23:38:32 +01:00
$(document).ready(function() {
2018-04-12 23:17:19 +02:00
renderMathInElement($("#container")[0]);
2018-02-23 19:52:10 +01:00
$('pre code').each(function(i, block) {
hljs.highlightBlock(block);
hljs.lineNumbersBlock(block);
});
2018-03-15 23:38:32 +01:00
});
2018-03-15 23:31:31 +01:00
<?lua end ?>
2018-02-25 16:11:37 +01:00
window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));
// facebook
(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = 'https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.12';
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
2018-06-05 15:40:15 +02:00
/*(function() {
2018-02-25 16:11:37 +01:00
var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
po.src = 'https://apis.google.com/js/plusone.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
2018-06-05 15:40:15 +02:00
})();*/
2018-02-23 19:52:10 +01:00
</script>
</head>
<body>
2018-02-25 16:11:37 +01:00
<div id="fb-root"></div>
2018-02-23 19:52:10 +01:00
<div id = "top">
2018-02-25 13:54:37 +01:00
<div id = "navbar" class = "<?=cls?>">
2018-02-23 19:52:10 +01:00
<div class = "logo"><a href = "https://lxsang.me"></a></div>
<ul>
<li><i class = "fa fa-home"></i><a href="./">Home</a></li>
<li ><i class = "fa fa-address-card"></i><a href="https://info.lxsang.me" >Porfolio</a></li>
2018-06-05 16:28:53 +02:00
<li><i class = "fa fa-envelope"></i><a href="#" onclick="mailtoMe('rst')" >Contact</a></li>
2018-02-25 13:54:37 +01:00
<?lua
if not HEADER.mobile then
?>
2018-06-05 16:28:53 +02:00
<li> <i class = "fa fa-paper-plane"></i><a href="#" onclick="subscribe('rst')">Subscribe</a></li>
2018-02-23 22:39:28 +01:00
<li > <i class = "fa fa-globe"></i><a href = "https://os.lxsang.me" target="_blank">AntOS</a></li>
2018-02-25 13:54:37 +01:00
<?lua end ?>
2018-02-23 19:52:10 +01:00
</ul>
2018-02-25 13:54:37 +01:00
<?lua
if not HEADER.mobile then
?>
2018-02-23 19:52:10 +01:00
<input type = "text" class = "search-box"></input>
<div class= "search-icon"></div>
2018-02-25 13:54:37 +01:00
<?lua
end
?>
2018-02-23 19:52:10 +01:00
</div>
</div>
2018-03-15 22:36:05 +01:00
<div id = "desktop">
2018-02-23 19:52:10 +01:00
<div id = "container">