Skip to content

Commit

Permalink
[jarun#607] fixed bookmark details overflow (bukuserver)
Browse files Browse the repository at this point in the history
  • Loading branch information
LeXofLeviafan committed Nov 27, 2022
1 parent 65192b5 commit 5c7bbf7
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
11 changes: 11 additions & 0 deletions bukuserver/static/bukuserver/css/bookmark.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/* preventing layout overflow in tables */
table tr td:not(:first-child) {
overflow-wrap: anywhere;
}

/* wider modals for wide data */
@media (min-width: 768px) {
.modal-dialog {
width: min(1000px, 80%);
}
}
3 changes: 2 additions & 1 deletion bukuserver/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ def _list_entry(self, context: Any, model: Namespace, name: str) -> Markup:
edit_modal_template = "bukuserver/bookmark_edit_modal.html"
edit_template = "bukuserver/bookmark_edit.html"
named_filter_urls = True
extra_css = ['/static/bukuserver/css/bookmark.css']

def __init__(self, *args, **kwargs):
self.bukudb: buku.BukuDb = args[0]
Expand Down Expand Up @@ -271,7 +272,7 @@ def get_one(self, id):
value = value[1:]
if value.endswith(","):
value = value[:-1]
setattr(bm_sns, field.name.lower(), value)
setattr(bm_sns, field.name.lower(), value.replace(',', ', '))
else:
setattr(bm_sns, field.name.lower(), bookmark[field.value])
return bm_sns
Expand Down

0 comments on commit 5c7bbf7

Please sign in to comment.