Skip to content

Commit

Permalink
Merge pull request #5754 from nextcloud-libraries/fix/intersection-ob…
Browse files Browse the repository at this point in the history
…server

fix(NcReferenceWidget): pass elements to intersection observer
  • Loading branch information
DorraJaouad authored Jul 2, 2024
2 parents 5be7317 + 1894fa6 commit 62b8b36
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/NcRichText/NcReferenceWidget.vue
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ export default {
const widgetRoot = ref()
const { width } = useElementSize(widgetRoot)
useIntersectionObserver(widgetRoot, () => {
useIntersectionObserver(widgetRoot, ([entry]) => {
nextTick(() => {
isVisible.value = widgetRoot.value?.isIntersecting ?? false
isVisible.value = entry.isIntersecting
})
})
Expand Down

0 comments on commit 62b8b36

Please sign in to comment.