Browse Source

fix: scroll to add edit if present

Signed-off-by: mertmit <mertmit99@gmail.com>
pull/6638/head
mertmit 1 year ago
parent
commit
3e62477a36
  1. 3
      packages/nc-gui/components/smartsheet/grid/Table.vue

3
packages/nc-gui/components/smartsheet/grid/Table.vue

@ -414,7 +414,8 @@ const closeAddColumnDropdown = (scrollToLastCol = false) => {
preloadColumn.value = {}
if (scrollToLastCol) {
setTimeout(() => {
const lastAddNewRowHeader = tableHeadEl.value?.querySelector('th:last-child')
const lastAddNewRowHeader =
tableHeadEl.value?.querySelector('.nc-grid-add-edit-column') ?? tableHeadEl.value?.querySelector('th:last-child')
if (lastAddNewRowHeader) {
lastAddNewRowHeader.scrollIntoView({ behavior: 'smooth' })
}

Loading…
Cancel
Save