Fix #1903659 [[Enhancement - Content server] Don't show arrows on cover when viewing random book](https://bugs.launchpad.net/calibre/+bug/1903659)

This commit is contained in:
Kovid Goyal 2020-11-10 15:33:08 +05:30
parent 4cc7c45559
commit bcb324ffb9
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -457,6 +457,7 @@ def next_book(book_id, delta):
def render_book(container_id, book_id):
render_book.book_id = book_id
is_random = parse_url_params().book_id is '0'
c = document.getElementById(container_id)
if not c:
return
@ -469,6 +470,8 @@ def render_book(container_id, book_id):
button_style = f'cursor: pointer; border-radius: {border_radius//5}px;'
button_style += 'color: #ccc; background-color:rgba(0, 0, 0, 0.75);'
button_style += 'display: flex; justify-content: center; align-items: center; padding: 2px;'
if is_random:
button_style += 'display: none;'
def prev_next_button(is_prev):
return E.div(