Repository navigation
Description
Requestor
Problem Statement
EuiSearchBar renders its filters inside an EuiFilterGroup, but there is no way to set compressed on that group from the EuiSearchBar API. EuiFilterGroup already supports a compressed prop that reduces its height to match compressed form controls, but it is hardcoded without that prop in EuiSearchBarFilters. The search input (EuiFieldSearch) can be made compressed via box={{ compressed: true }}, but there is no equivalent for the filter buttons — and no single prop that makes the whole bar compact at once.
Proposed Solution
Add a top-level compressed prop to EuiSearchBarProps that drives both the search input and the filter group:
<EuiSearchBar filters={myFilters} compressed />Internally, this would forward compressed to EuiFieldSearch (via box) and to EuiFilterGroup (via EuiSearchBarFilters). A consumer who needs fine-grained control can still override via box={{ compressed: false }}.
Use Case
Any product that places EuiSearchBar with filters inside a toolbar or header area that uses compressed-size form controls. Today, consumers must pass box={{ compressed: true }} for the input and have no opt-in at all for the filter buttons, leaving them at full height with no workaround short of CSS overrides.
Value / Impact
- Enables visual consistency in dense or compact layouts with a single prop.
- Low-effort change:
EuiFilterGroupandEuiFieldSearchalready supportcompressed— it just needs to be exposed one level up and threaded through. - It is very unlikely a consumer would want the input compressed but not the filters, or vice versa, so a unified prop matches the real-world use case.
Urgency
Nice-to-have; no hard deadline. Currently blocked by a missing API, not missing functionality in the underlying components.
Do alternatives or workarounds exist?
Partially. box={{ compressed: true }} compresses the search input, but there is no equivalent for the filter group. CSS overrides targeting .euiFilterGroup are the only current option for the filters, which is not stable.
Related code or customizations
EuiFilterGroupalready acceptscompressed—filter_group.tsxEuiSearchBarFiltersrenders the group but exposes no way to configure it —search_filters.tsx
Activity
github-actions commentedon Jun 4, 2026
👋 Thank you for your suggestion or request! While the EUI team agrees that it's valid, it's unlikely that we will prioritize this issue on our roadmap. We'll leave the issue open if you or anyone else in the community wants to implement it by contributing to EUI. If not, this issue will auto close in one year.
[-]EuiSearchBar: add top-level prop for both the search input and filter group[/-][+][EuiSearchBar] Add top-level `compressed` prop, for both the search input and filter group[/+]MannXo commentedon Jun 5, 2026
Interested in working on this. Can I be assigned?
JasonStoltz commentedon Jun 17, 2026
@MannXo We will accepts PRs for anything labeled with
help wanted. We will not assign issues outside of Elastic. Feel free to contribute a PR. See contributing to EUI for more info.