Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

fix: fav reference style issue (#2476)

Peng Xiao752bc9ca0e3a
diff --git a/apps/web/src/components/pure/workspace-slider-bar/favorite/favorite-list.tsx b/apps/web/src/components/pure/workspace-slider-bar/favorite/favorite-list.tsx
index a8e7aeed5b..5c5a727690 100644
--- a/apps/web/src/components/pure/workspace-slider-bar/favorite/favorite-list.tsx
+++ b/apps/web/src/components/pure/workspace-slider-bar/favorite/favorite-list.tsx
@@ -59,17 +59,19 @@ function FavoriteMenuItem({
</MenuLinkItem>
{collapsible && (
<Collapsible.Content className={styles.collapsibleContent}>
- {referencesToShow.map(ref => {
- return (
- <FavoriteMenuItem
- key={ref}
- workspace={workspace}
- pageId={ref}
- metaMapping={metaMapping}
- parentIds={new Set([...parentIds, pageId])}
- />
- );
- })}
+ <div className={styles.collapsibleContentInner}>
+ {referencesToShow.map(ref => {
+ return (
+ <FavoriteMenuItem
+ key={ref}
+ workspace={workspace}
+ pageId={ref}
+ metaMapping={metaMapping}
+ parentIds={new Set([...parentIds, pageId])}
+ />
+ );
+ })}
+ </div>
</Collapsible.Content>
)}
</Collapsible.Root>
diff --git a/apps/web/src/components/pure/workspace-slider-bar/favorite/styles.css.ts b/apps/web/src/components/pure/workspace-slider-bar/favorite/styles.css.ts
index 4315cf7530..e8f8a176cd 100644
--- a/apps/web/src/components/pure/workspace-slider-bar/favorite/styles.css.ts
+++ b/apps/web/src/components/pure/workspace-slider-bar/favorite/styles.css.ts
@@ -49,3 +49,9 @@ export const collapsibleContent = style({
},
},
});
+
+export const collapsibleContentInner = style({
+ display: 'flex',
+ flexDirection: 'column',
+ gap: '4px',
+});