added new landing page
This commit is contained in:
@@ -8,17 +8,20 @@ $(document).ready(function() {
|
||||
$("table.striped tbody tr:even").addClass("even");
|
||||
$("table.striped tbody tr:odd").addClass("odd");
|
||||
|
||||
// More link
|
||||
$("#site-map-link").click(function(e) {
|
||||
$("#more-links").toggle();
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
});
|
||||
$("#more-links").hide().offset({top: $("#site-map-link").offset().top + $("#site-map-link").height() + 10, left: $("#site-map-link").offset().left});
|
||||
|
||||
$(document).click(function(e) {
|
||||
$("#more-links").hide();
|
||||
});
|
||||
if ($("#site-map-link").length > 0) {
|
||||
// More link
|
||||
$("#site-map-link").click(function(e) {
|
||||
$("#more-links").toggle();
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
});
|
||||
|
||||
$("#more-links").hide().offset({top: $("#site-map-link").offset().top + $("#site-map-link").height() + 10, left: $("#site-map-link").offset().left});
|
||||
|
||||
$(document).click(function(e) {
|
||||
$("#more-links").hide();
|
||||
});
|
||||
}
|
||||
|
||||
// Ajax links
|
||||
$("a[data-remote=true]").click(function(e) {
|
||||
|
||||
8
app/assets/javascripts/landings.js
Normal file
8
app/assets/javascripts/landings.js
Normal file
@@ -0,0 +1,8 @@
|
||||
$(function() {
|
||||
$("#c-landings div.data").each(function(i, div) {
|
||||
var $div = $(div);
|
||||
var $image = $div.prev();
|
||||
|
||||
$div.width($image.width() - 10).height($image.height() - 10).offset({top: $image.position().top, left: $image.position().left});
|
||||
});
|
||||
});
|
||||
@@ -31,4 +31,8 @@ a.login {
|
||||
|
||||
a.forum-updated {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
a.wiki-link {
|
||||
margin-right: 0.3em;
|
||||
}
|
||||
44
app/assets/stylesheets/specific/landing.css.scss
Normal file
44
app/assets/stylesheets/specific/landing.css.scss
Normal file
@@ -0,0 +1,44 @@
|
||||
div#c-landings {
|
||||
div#a-show {
|
||||
padding-top: 4em;
|
||||
width: 960px;
|
||||
margin: auto;
|
||||
|
||||
h1 {
|
||||
text-align: center;
|
||||
font-size: 4em;
|
||||
}
|
||||
|
||||
p.slogan {
|
||||
text-align: center;
|
||||
font-size: 1.5em;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
div.column {
|
||||
width: 480px;
|
||||
vertical-align: top;
|
||||
float: left;
|
||||
background-color: #000;
|
||||
}
|
||||
|
||||
div.landing-post {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
div.landing-post:hover img {
|
||||
opacity: 0.25;
|
||||
}
|
||||
|
||||
div.landing-post:hover div.data {
|
||||
opacity: 1.0;
|
||||
}
|
||||
|
||||
div.landing-post div.data {
|
||||
position: absolute;
|
||||
color: white;
|
||||
padding: 5px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -26,6 +26,14 @@ article.post-preview {
|
||||
}
|
||||
}
|
||||
|
||||
div.text-post-medium {
|
||||
height: 150px;
|
||||
width: 480px;
|
||||
text-align: center;
|
||||
line-height: 480px;
|
||||
border: 1px solid #CCC;
|
||||
}
|
||||
|
||||
article.post-preview.blacklisted-active {
|
||||
display: none;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user