diff --git a/changelogs/unreleased/88276.json b/changelogs/unreleased/88276.json new file mode 100644 index 0000000000..9fac8c9f16 --- /dev/null +++ b/changelogs/unreleased/88276.json @@ -0,0 +1,5 @@ +{ + "title": "SearchTreeView: add possibility to have a fixed parent search bar", + "type": "feat", + "packages": "core" +} diff --git a/packages/core/src/components/templates/SearchTreeView/SearchTreeView.tsx b/packages/core/src/components/templates/SearchTreeView/SearchTreeView.tsx index fbc2e25ad5..cf64291809 100644 --- a/packages/core/src/components/templates/SearchTreeView/SearchTreeView.tsx +++ b/packages/core/src/components/templates/SearchTreeView/SearchTreeView.tsx @@ -51,6 +51,7 @@ interface SearchTreeViewProps { searchNavigate?: boolean; scanKeySearch?: string; isHideableSearch?: boolean; + isHideableParentSearch?: boolean; fixedItems?: any; topFixedItems?: any; chipComponent?: any; @@ -86,6 +87,7 @@ const SearchTreeView = ({ searchNavigate, scanKeySearch = null, isHideableSearch = false, + isHideableParentSearch = true, fixedItems, topFixedItems, chipComponent, @@ -215,12 +217,13 @@ const SearchTreeView = ({ topChildren={ <> {headerTopChildren} - {renderParentSearchBar()} + {isHideableParentSearch && renderParentSearchBar()} } fixedItems={ <> {topFixedItems} + {!isHideableParentSearch && renderParentSearchBar()} {!isHideableSearch && renderSearchBar()} {fixedItems}