diff --git a/packages/nc-gui/components/smartsheet/Kanban.vue b/packages/nc-gui/components/smartsheet/Kanban.vue index 1151eacf48..ea3beaab5e 100644 --- a/packages/nc-gui/components/smartsheet/Kanban.vue +++ b/packages/nc-gui/components/smartsheet/Kanban.vue @@ -144,6 +144,21 @@ async function onMove(event: any, stackKey: string) { } } +const kanbanListScrollHandler = async (e: any) => { + if (e.target.scrollTop + e.target.clientHeight >= e.target.scrollHeight) { + const stackId = e.target.getAttribute('data-id') + // TODO: load 25 more records + console.log(stackId) + } +} + +const kanbanListRef = (kanbanListElement: HTMLElement) => { + if (kanbanListElement) { + kanbanListElement.removeEventListener('scroll', kanbanListScrollHandler) + kanbanListElement.addEventListener('scroll', kanbanListScrollHandler) + } +} + openNewRecordFormHook?.on(async () => { const newRow = await addEmptyRow() expandForm(newRow) @@ -178,7 +193,7 @@ openNewRecordFormHook?.on(async () => {
{{ stack.title }}
-
+