Use padding rather than margins for highlights/bookmarks panels

At least in the case of highlights without this change, the bottom
padding was not visible when the panel is smaller than a full screen
This commit is contained in:
Kovid Goyal 2021-08-20 06:47:50 +05:30
parent 31569649a1
commit 9ac68112b1
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 2 additions and 2 deletions

View File

@ -58,7 +58,7 @@ def new_bookmark(container_id, annotations_manager, data, onclick, ev):
def create_bookmarks_panel(annotations_manager, data, book, container, onclick):
set_css(container, display='flex', flex_direction='column')
container.appendChild(E.div(style='margin: 1rem'))
container.appendChild(E.div(style='padding: 1rem'))
container = container.lastChild
container_id = ensure_id(container)
button = create_button(_('New bookmark'), 'plus', new_bookmark.bind(None, container_id, annotations_manager, data, onclick))

View File

@ -909,7 +909,7 @@ def create_highlights_panel(annotations_manager, hide_panel, book, container, on
_('Export'), 'cloud-download', show_export_dialog.bind(None, annotations_manager), _('Export all or selected highlights'),
class_='ac-button')
c = E.div(
style='margin: 1rem',
style='padding: 1rem',
id=get_container_id(),
E.div(
style='display: flex; flex-wrap: wrap; margin-top: -1ex; align-items: center',