Skip to content

Commit 3f4b0ef

Browse files
Arthur GambyArthur Gamby
authored andcommitted
docs(chore): Hide auto-generated errors category
1 parent 8cfea05 commit 3f4b0ef

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"className": "hidden-sidebar"
3+
}

src/theme/DocCardList/index.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,13 @@ export default function DocCardList(props: Props): JSX.Element {
1919
}
2020
const [filteredItems, setFilteredItems] = useState<any>(filterDocCardListItems(items));
2121
useEffect(() => {
22-
setFilteredItems(filteredItems.filter((e: any) => e?.href?.slice(0, -1) !== location.pathname));
22+
setFilteredItems(
23+
filteredItems.filter((e: any) => {
24+
if (e?.href?.slice(0, -1) === location.pathname) return false;
25+
if (e?.className === "hidden-sidebar") return false;
26+
return true;
27+
})
28+
);
2329
}, [items]);
2430
return (
2531
<section className={clsx("row", className)}>

0 commit comments

Comments
 (0)