-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathindex.html
More file actions
155 lines (141 loc) · 5.46 KB
/
Copy pathindex.html
File metadata and controls
155 lines (141 loc) · 5.46 KB
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
---
layout: szhang_default
title: Welcome!
---
<style>
.custom-nav {
z-index: 70;
position: fixed;
float: right;
padding: 0;
margin: 0;
top: 10px;
right: 10px;
font-family: Arial;
font-size: 16px;
line-height: 18px;
}
.custom-nav ul {
margin: 0px;
}
.custom-nav ul li {
display: table-cell;
}
.custom-nav ul li a {
display: block;
margin-left: 5px;
padding: 1px 6px;
}
</style>
<div class="custom-nav">
<ul class="nav">
<li><a href="#Home">Home</a></li>
<li><a href="#About">About</a></li>
</ul>
</div>
<section id="Home"></section>
<h1>Home <small>{{ site.tagline }}</small><a target="_blank" title="visit my github repository" href="https://github.com/iontrapnet" style="float:right;margin:5px;"><img src="/static/images/github.png"></a></h1>
<h2><a href="/notes">Recent Notes</a></h2>
<ul>
{% for post in site.posts limit:10 %}
{% if post.category == 'notes' %}
<li>
<i class="fa fa-calendar"></i><span class="index_date"> {{ post.date | date: "%Y/%m/%d" }}</span>
-
<a href="{{ post.url }}">{{ post.title }}</a>
</li>
{% endif %}
{% endfor %}
</ul>
{% for post in site.posts %}
{% if post.category == 'publications' %}
{% if post.pdf %}
<a href="{{ post.pdf }}">
<img src="/static/images/pdf32.png" align="right">
</a>
{% endif %}
<i class="fa fa-calendar"></i><span class="index_date"> {{ post.date | date: "%B, %Y" }}</span> - <a href="{{ post.url }}">{{ post.title }}</a>
<br/>
{% if post.introduction %}
{{ post.introduction }}
{% endif %}
{% if post.cover %}
<div class="center">
<a href="{{ post.url }}"><img src="{{ post.cover }}" width="75%"></a>
</div>
{% endif %}
<p align="right"><a href="{{ post.link }}" target="_blank"><em>{{ post.journal }}</em>, {{ post.volume }}</a></p><hr/>
{% endif %}
{% endfor %}
{% for post in site.posts %}
{% if post.category == 'groups' %}
<i class="fa fa-calendar"></i><span class="index_date"> {{ post.date | date: "%B, %Y" }}</span> - <a href="{{ post.url }}">{{ post.title }}</a>
{% if post.cover %}
<div class="center">
<a href="{{ post.url }}"><img src="{{ post.cover }}" width="75%"></a>
</div>
{% endif %}
<hr/>
{% endif %}
{% endfor %}
{% for post in site.posts %}
{% if post.category == 'projects' %}
<i class="fa fa-calendar"></i><span class="index_date"> {{ post.date | date: "%B, %Y" }}</span> - <a href="{{ post.url }}">{{ post.title }}</a>
{% if post.cover %}
<div class="center">
<a href="{{ post.url }}"><img src="{{ post.cover }}" width="75%"></a>
</div>
{% endif %}
<hr/>
{% endif %}
{% endfor %}
<section id="About"></section>
<h2><a href="/blog">Blog Updates</a></h2>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0-alpha1/jquery.min.js"></script>
<!--link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js" crossorigin="anonymous"></script-->
<!--section class="github-widget" data-repo="iontrapnet/iontrapnet.github.io"></section>
<script src="/javascripts/jquery.githubRepoWidget.js"></script-->
<section class="github-box-content" style="margin-bottom:30px"><ul></ul></section>
<script type="text/javascript">
var repo_name = 'iontrapnet/iontrapnet.github.io';
var html_encode = function (str) {
if (!str || str.length == 0) return "";
return str.replace(/</g, "<").replace(/>/g, ">");
};
$.ajax({
url: 'https://api.github.com/repos/' + repo_name,
dataType: 'jsonp',
success: function (results) {
var repo = results.data;
console.log(results);
//var pushed_at = repo.pushed_at.substr(0, 10);
var url_regex = /((http|https):\/\/)*[\w-]+(\.[\w-]+)+([\w.,@?^=%&:\/~+#-]*[\w@?^=%&\/~+#-])?/
if (repo.homepage && (m = repo.homepage.match(url_regex))) {
if (m[0] && !m[1]) repo.homepage = 'http://' + m[0];
}
else {
repo.homepage = '';
}
$.ajax({
url: 'https://api.github.com/repos/' + repo_name + "/issues?state=open&per_page=5&page=1&sort=updated",
dataType: 'jsonp',
success: function (results) {
var issues = results.data;
var $issues_table = $(".github-box-content ul");
//$issues_table.append('<tr><td colspan="2"><a href="' + repo.html_url + '/issues" target="_blank"><strong>Issues</strong></a></td></tr>');
for (var i = 0; i < issues.length; i++) {
//var updated_at = issues[i].updated_at.substr(0, 10);
var updated_at = new Date(issues[i].updated_at);
$issues_table.append('<li><a href="' + issues[i].html_url + '" target="_blank">#' + issues[i].number + '</a> - <a href="' + issues[i].html_url.replace('https://github.com/' + repo_name + '/', '/Blog/#') + '">' + html_encode(issues[i].title) + '</a> by <a href="' + issues[i].user.url.replace('api.', '').replace('users/', '')
+ '" target="_blank">' + issues[i].user.login
+ '</a> at <span>'
//+ updated_at
+ updated_at.toLocaleDateString() + ' ' + updated_at.toLocaleTimeString()
+ '</span></li>');
}
}
});
}
});
</script>