Skip to content

Commit 4bd07c0

Browse files
authored
set hard limit of visible document pills (#235)
1 parent 259a81b commit 4bd07c0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Diff for: ragna/deploy/_ui/central_view.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,10 @@ def header(self):
588588
):
589589
doc_names = [d["name"] for d in self.current_chat["metadata"]["documents"]]
590590

591-
for doc_name in doc_names:
591+
# FIXME: Instead of setting a hard limit of 20 documents here, this should
592+
# scale automatically with the width of page
593+
# See https://github.com/Quansight/ragna/issues/224
594+
for doc_name in doc_names[:20]:
592595
pill = pn.pane.HTML(
593596
f"""<div class="chat_document_pill">{doc_name}</div>""",
594597
stylesheets=[

0 commit comments

Comments
 (0)