fnp
/
wolnelektury.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
dbdd144
)
fix player placement in search results
author
Jan Szejko
<janek37@gmail.com>
Wed, 13 Dec 2017 15:22:36 +0000
(16:22 +0100)
committer
Jan Szejko
<janek37@gmail.com>
Wed, 13 Dec 2017 15:22:36 +0000
(16:22 +0100)
src/catalogue/templates/catalogue/book_searched.html
patch
|
blob
|
history
src/catalogue/templates/catalogue/book_short.html
patch
|
blob
|
history
src/catalogue/templates/catalogue/search_multiple_hits.html
patch
|
blob
|
history
src/wolnelektury/static/scss/main/book_box.scss
patch
|
blob
|
history
src/wolnelektury/static/scss/main/search.scss
patch
|
blob
|
history
diff --git
a/src/catalogue/templates/catalogue/book_searched.html
b/src/catalogue/templates/catalogue/book_searched.html
index
06bb4fd
..
4e91432
100644
(file)
--- a/
src/catalogue/templates/catalogue/book_searched.html
+++ b/
src/catalogue/templates/catalogue/book_searched.html
@@
-1,14
+1,8
@@
-{% spaceless %}
- {% load i18n %}
- {% load inline_tag_list from catalogue_tags %}
- {% load ssi_include from ssify %}
- {% load cache %}
-
- <div class="search-result">
- {% cache 86400 catalogue_book_short book.pk %}
- {% include 'catalogue/book_short.html' %}
- {% endcache %}
+{% extends "catalogue/book_short.html" %}
+{% load inline_tag_list from catalogue_tags %}
+{% block right-column %}
+ <div class="book-right-column">
<div class="snippets">
{% for hit in hits %}
{% if hit.snippet %}
<div class="snippets">
{% for hit in hits %}
{% if hit.snippet %}
@@
-21,17
+15,12
@@
{% inline_tag_list hit.themes_hit %}
{% endif %}
<a href="{{hit.fragment.get_absolute_url}}">
{% inline_tag_list hit.themes_hit %}
{% endif %}
<a href="{{hit.fragment.get_absolute_url}}">
- {% if hit.snippet %}
- {{hit.snippet|safe}}
- {% else %}
- {{hit.fragment.text|truncatewords_html:15|safe}} {# bad, now impossible #}
- {% endif %}
+ {{hit.snippet|safe}}
</a>
</div>
{% endif %}
{% endfor %}
</div>
</a>
</div>
{% endif %}
{% endfor %}
</div>
-
- <div style="clear: right"></div>
+ {% include 'catalogue/snippets/jplayer.html' %}
</div>
</div>
-{% endspaceless %}
\ No newline at end of file
+{% endblock %}
diff --git
a/src/catalogue/templates/catalogue/book_short.html
b/src/catalogue/templates/catalogue/book_short.html
index
24d93d0
..
70aaed3
100644
(file)
--- a/
src/catalogue/templates/catalogue/book_short.html
+++ b/
src/catalogue/templates/catalogue/book_short.html
@@
-131,7
+131,7
@@
{% block right-column %}
{% if audiobooks %}
{% block right-column %}
{% if audiobooks %}
- <div class="
audio
book-right-column">
+ <div class="book-right-column">
{% include 'catalogue/snippets/jplayer.html' %}
</div>
{% endif %}
{% include 'catalogue/snippets/jplayer.html' %}
</div>
{% endif %}
diff --git
a/src/catalogue/templates/catalogue/search_multiple_hits.html
b/src/catalogue/templates/catalogue/search_multiple_hits.html
index
b3f522b
..
ce43bf9
100644
(file)
--- a/
src/catalogue/templates/catalogue/search_multiple_hits.html
+++ b/
src/catalogue/templates/catalogue/search_multiple_hits.html
@@
-30,7
+30,9
@@
<ul class="work-list">
{% for result in results %}
<li class="Book-item">
<ul class="work-list">
{% for result in results %}
<li class="Book-item">
- {% book_searched result %}
+ <div class="search-result">
+ {% book_searched result %}
+ </div>
</li>
{% endfor %}
</ul>
</li>
{% endfor %}
</ul>
diff --git
a/src/wolnelektury/static/scss/main/book_box.scss
b/src/wolnelektury/static/scss/main/book_box.scss
index
44a5955
..
0e90611
100755
(executable)
--- a/
src/wolnelektury/static/scss/main/book_box.scss
+++ b/
src/wolnelektury/static/scss/main/book_box.scss
@@
-131,7
+131,7
@@
}
}
}
}
-.audiobook-box {
+.audiobook-box
, .search-result .book-box
{
.book-left-column {
@media screen and (min-width: 1024px) {
display: inline-block;
.book-left-column {
@media screen and (min-width: 1024px) {
display: inline-block;
@@
-139,9
+139,10
@@
}
}
}
}
- .
audio
book-right-column {
+ .book-right-column {
@media screen and (min-width: 1024px) {
float: right;
@media screen and (min-width: 1024px) {
float: right;
+ @include size(padding-top, 15px);
@include size(width, 360px);
}
}
@include size(width, 360px);
}
}
@@
-151,7
+152,6
@@
@media screen and (min-width: 1024px) {
float: right;
@media screen and (min-width: 1024px) {
float: right;
- margin-top: 48px;
}
}
}
}
}
}
diff --git
a/src/wolnelektury/static/scss/main/search.scss
b/src/wolnelektury/static/scss/main/search.scss
index
f77e84e
..
14d8f0d
100755
(executable)
--- a/
src/wolnelektury/static/scss/main/search.scss
+++ b/
src/wolnelektury/static/scss/main/search.scss
@@
-26,8
+26,7
@@
@include size(margin-bottom, 16px);
}
@include size(margin-bottom, 16px);
}
-
-.search-result {
+/*.search-result {
@include size(border, 1px solid #ddd);
@include size(box-shadow, 2px 2px 2px #ddd);
@include size(margin, 1px);
@include size(border, 1px solid #ddd);
@include size(box-shadow, 2px 2px 2px #ddd);
@include size(margin, 1px);
@@
-55,7
+54,7
@@
margin: 0;
}
}
margin: 0;
}
}
-}
+}
*/