From 9a3d76a356646ff3bec77e3b4fd01753aa52c861 Mon Sep 17 00:00:00 2001 From: DrMint Date: Fri, 15 Jul 2022 14:34:25 +0200 Subject: [PATCH] Fixed combine related contents --- src/pages/contents/index.tsx | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/src/pages/contents/index.tsx b/src/pages/contents/index.tsx index 13f0ed4..a2d616e 100644 --- a/src/pages/contents/index.tsx +++ b/src/pages/contents/index.tsx @@ -61,9 +61,12 @@ const Contents = ({ toggleState: toggleKeepInfoVisible, setState: setKeepInfoVisible, } = useBoolean(DEFAULT_FILTERS_STATE.keepInfoVisible); - const [combineRelatedContent, setCombineRelatedContent] = useState( - DEFAULT_FILTERS_STATE.combineRelatedContent - ); + + const { + state: combineRelatedContent, + toggleState: toggleCombineRelatedContent, + setState: setCombineRelatedContent, + } = useBoolean(DEFAULT_FILTERS_STATE.combineRelatedContent); const [searchName, setSearchName] = useState( DEFAULT_FILTERS_STATE.searchName ); @@ -174,7 +177,7 @@ const Contents = ({ input={ } /> @@ -208,9 +211,19 @@ const Contents = ({ groupingMethod, hoverable, keepInfoVisible, - langui, + langui.always_show_info, + langui.category, + langui.combine_related_contents, + langui.contents, + langui.contents_description, + langui.group_by, + langui.reset_all_filters, + langui.search_title, + langui.type, searchName, + setCombineRelatedContent, setKeepInfoVisible, + toggleCombineRelatedContent, toggleKeepInfoVisible, ] );