Skip to content

Commit 123e87d

Browse files
committed
assets
1 parent 56a6ba0 commit 123e87d

File tree

6 files changed

+2473
-0
lines changed

6 files changed

+2473
-0
lines changed

assets/awesome-cpp.css

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
#content {
2+
max-width: 1024px;
3+
margin: 0 auto;
4+
padding: 0 10px;
5+
display: block;
6+
}
7+
8+
#awesomecpp {
9+
margin-top: 15px;
10+
text-align: center;
11+
}
12+
13+
#awesomecpp + p {
14+
margin-bottom: 30px;
15+
padding-bottom: 30px;
16+
text-align: center;
17+
font-size: 1.4rem;
18+
font-size: 25px;
19+
border-bottom: 1px solid #F1F1F1;
20+
line-height: 1.5
21+
}
22+
23+
ul li {
24+
padding-left: .3em;
25+
list-style-position: outside;
26+
padding: 10px 0;
27+
margin-top: 10px;
28+
border-bottom: 1px solid #EEE;
29+
}
30+
31+
ul li:last-child {
32+
border-bottom: none
33+
}
34+
35+
h2 {
36+
margin-top: 20px;
37+
border-top: 1px solid #BBB;
38+
padding-top: 20px;
39+
}

assets/awesome-cpp.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
var getFileData = function(url) {
2+
$.ajax({
3+
url: url,
4+
headers: {
5+
"Accept": "application/vnd.github.v3.raw"
6+
}
7+
}).done(function(data) {
8+
var converter = new Showdown.converter();
9+
var html = converter.makeHtml(data);
10+
$("#content").html(html)
11+
})
12+
};
13+
14+
$(document).ready(function(){
15+
$.getJSON("https://api.github.com/repos/fffaraz/awesome-cpp/git/trees/HEAD").
16+
done(function(data){
17+
for (var i = data.tree.length - 1; i >= 0; i--) {
18+
if(data.tree[i].path == "README.md") {
19+
getFileData(data.tree[i].url);
20+
break;
21+
}
22+
};
23+
});
24+
});

0 commit comments

Comments
 (0)