Permalink
Browse files

Merge pull request #1334 from jdlrobson/1329

Fix add-cover and manage-covers
  • Loading branch information...
mekarpeles committed Oct 12, 2018
2 parents 7c84439 + 9be3e32 commit c0abbf02a36aaabba98b70e6dc731ffd7767e959
@@ -10,7 +10,7 @@
$ intro = _("There are two ways to get a cover image on Open Library")
$ action = doc.url('/add-cover')
$elif doc.get_edition_covers:
$ intro = _("There are three ways to get a cover image on Open Library")
$ intro = _("There are two ways to get a cover image on Open Library")
$ action = doc.url('/add-cover')
$else:
$ intro = _("There are two ways to get a cover image on Open Library")
@@ -26,9 +26,7 @@
<script type="text/javascript">
<!--
\$().ready(carousels);
\$().ready(function(){\$('#popcovers').jcarousel();});
\$(function() {
window.q.push(function(){
parent.closeThrobber();
\$("#form.addcover-form").submit(function(event) {
@@ -4,7 +4,7 @@
$putctx('robots', 'noindex,nofollow')
<script type="text/javascript">
\$(function() {
window.q.push(function () {
\$(".column").sortable({
connectWith: '.trash'
});
@@ -13,10 +13,6 @@
});
\$(".column").disableSelection();
\$(".trash").disableSelection();
});
</script>
<script type="text/javascript">
\$().ready(function(){
\$("#topNotice").hide();
});
</script>
@@ -30,18 +30,6 @@
updateBookAvailability('#coversCarousel li ');
});
}
\$().ready(function() {
page.renderCovers = render_page;
page.displayCovers(0);
});
\$().ready(carousels);
\$().ready(function() {
carouselSetup(loadCoverCarousels);
\$('.jcarousel-next').attr('title','View the next editions').append('<h4 class="shift"><a href="#" onclick="return false;">View the next editions</a></h4>');
\$('.jcarousel-prev').attr('title','View the previous editions').append('<h4 class="shift"><a href="#" onclick="return false;">View the previous editions</a></h4>');
});
//-->
</script>
@@ -3,20 +3,24 @@
$ announcement = '<strong>New Feature:</strong> You can now embed Open Library books on your website! &nbsp; <a href="https://blog.openlibrary.org/2018/05/06/turn-your-website-into-a-library/" data-ol-link-track="AnnouncementsBar|BlogWidget" class="btn primary">Learn More</a>'
$ bodyid = ctx.get('bodyid', 'user')
$ show_banners = bodyid != 'form'
$if 'v2' in page:
<body id="$bodyid">
<script>
// Provide a signal that JS will load
document.body.className += ' client-js';
</script>
<span id="top"></span>
$:render_template("site/alert")
$:render_template("lib/nav_head", None)
$# on form pages e.g. manage-covers, add-cover we do not display the header
$# this is consistent with version 1.
$if show_banners:
$:render_template("site/alert")
$:render_template("lib/nav_head", None)
<div id="test-body-mobile">
<div class="page-banner page-banner-body">
$:announcement
</div>
$if show_banners:
<div class="page-banner page-banner-body">
$:announcement
</div>
$:page
</div>
@@ -37,7 +37,6 @@ body#form {
}
.column {
min-height: 90px;
float: left;
margin: 10px;
background-image: url(/images/back_sortable.png);
background-repeat: no-repeat;
View
@@ -4,8 +4,13 @@
max-width: 960px;
width: 100%;
margin: 0 auto;
margin-top: 20px;
background-color: @white;
border-radius: 5px;
border: 1px solid @dark-beige;
}
// For pages without a header we don't want a margin.
// This might be better placed in the header component in future
// but is kept here for backwards compatibility with v1 pages
header + #test-body-mobile {
margin-top: 20px;
}

0 comments on commit c0abbf0

Please sign in to comment.