From eb4f23d627d066994483ea06476859b0c100a58d Mon Sep 17 00:00:00 2001 From: Kuba Orlik Date: Sun, 28 Jul 2024 15:14:19 +0200 Subject: [PATCH] Option to customize classes of the container in showFirstRow --- src/back/routes/common/show-first-row/show-first-row.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/back/routes/common/show-first-row/show-first-row.tsx b/src/back/routes/common/show-first-row/show-first-row.tsx index 616d486..688ae18 100644 --- a/src/back/routes/common/show-first-row/show-first-row.tsx +++ b/src/back/routes/common/show-first-row/show-first-row.tsx @@ -28,6 +28,7 @@ export async function showFirstRow({ {show_less_button} ), + classes = [], }: { items: FlatTemplatable[]; min_column_width_px?: number; @@ -39,6 +40,7 @@ export async function showFirstRow({ show_more_button: JSX.Element, show_less_button: JSX.Element ) => JSX.Element; + classes?: string[]; }): Promise { const id = showFirstRowIds.next().value; const checkbox_id = "show-first-row__checkbox--" + id; @@ -48,6 +50,7 @@ export async function showFirstRow({ "show-first-row", `show-first-row--id-${id}`, `show-first-row--items-count-${items.length}`, + ...classes, ]} style={`--min-column-width: ${min_column_width_px}px; --items-count: ${items.length}; --column-gap: ${column_gap_px}px`} >