Skip to content

Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.

fix: modified row page cover (#6373)

Kilu.He1100c8b7e16f
diff --git a/frontend/appflowy_web_app/src/components/database/components/header/DatabaseRowHeader.tsx b/frontend/appflowy_web_app/src/components/database/components/header/DatabaseRowHeader.tsx
index a70ff414fd..853eacf435 100644
--- a/frontend/appflowy_web_app/src/components/database/components/header/DatabaseRowHeader.tsx
+++ b/frontend/appflowy_web_app/src/components/database/components/header/DatabaseRowHeader.tsx
@@ -9,7 +9,7 @@ function DatabaseRowHeader ({ rowId, appendBreadcrumb }: { rowId: string; append
const ref = React.useRef<HTMLDivElement>(null);
const [offsetLeft, setOffsetLeft] = React.useState(0);
- const [width, setWidth] = React.useState(0);
+ const [width, setWidth] = React.useState<number | undefined>(undefined);
const meta = useRowMetaSelector(rowId);
const cover = meta?.cover;
@@ -42,7 +42,7 @@ function DatabaseRowHeader ({ rowId, appendBreadcrumb }: { rowId: string; append
if (!el) return;
- const container = getScrollParent(el);
+ const container = document.querySelector('.appflowy-scroll-container') || getScrollParent(el);
if (!container) return;