Content Filter Rimini provides client-side filtering, searching, grouping, and pagination for archive-style content. It is designed to work with any content collection — not just posts — and requires only HTML data attributes to configure.

Unlike a traditional WordPress query, filtering happens entirely in the browser after the page loads. This makes filtering extremely fast and allows users to combine multiple filters without reloading the page.
Addition Load More Button
If you are using the Per Page functionality, add this load more component.
{"type":"block","gutenbergBlock":{"blockName":"etch/component","attrs":{"ref":149466,"attributes":{"targetId":"news"}},"innerBlocks":[],"innerHTML":"\n\n","innerContent":["\n","\n"]},"timestamp":"2026-07-13T15:17:20.419Z","styles":{"p6fugpp":{"type":"class","selector":".center--all","collection":"default","css":"margin-inline: auto;\n display: flex;\n flex-direction: row;\n justify-content: center;\n text-align: center","readonly":false},"h56jpkh":{"type":"class","selector":".load-more-wrapper","collection":"default","css":"[data-af-load-more][hidden],\n & .archive-filter__load-more-button[hidden] {\n display: none !important;\n }","readonly":false}},"components":{"149466":{"id":149466,"legacyId":"","name":"Load More for Filters","key":"LoadMoreForFilters","blocks":[{"blockName":"etch/element","attrs":{"metadata":{"name":"load more"},"tag":"div","attributes":{"data-af-load-more":"{props.targetId}","class":"center--all load-more-wrapper"},"styles":["p6fugpp","h56jpkh"]},"innerBlocks":[],"innerHTML":"\n\n","innerContent":["\n","\n"]}],"properties":[{"name":"Target ID","key":"targetId","keyTouched":false,"type":{"primitive":"string"},"default":"articles"}],"description":""}},"version":2.1}If you are using ACSS, you can add the following to the global CSS to use the built-in button styles (primary added as an example).
.archive-filter__load-more-button{
@include btn('primary')
}Features
- Multi-field filtering
- Instant search
- Optional filter chips
- URL history support
- Client-side pagination
- Load More functionality
- Nested grouping (Year → Month → etc.)
- Automatic result counts
- Reading time buckets
- Accessible keyboard navigation
- Screen reader announcements
- Accordion integration
- Multiple independent filter instances on the same page
How It Works
The component consists of three primary pieces:
- Filter Controller
- Results Loop
- Optional Load More / Empty State
All three communicate using a shared Controller ID.
Example:
Controller ID = articlesEvery related element references this same ID.
data-af-controller="articles"
data-af-list="articles"
data-af-controls="articles"
data-af-count="articles"
data-af-empty="articles"This allows multiple independent filter systems to exist on the same page.
Here is the configuration for this site.
<ul data-af-list="articles" class="wpgb-content-1 pattern-card__listing" >
{#loop patterns as p}
<li
data-af-item="" /* lets the filter know this i an item */
data-title="{p.title}" /* sets the title for the search */
data-year="{p.date.format('Y')}" /* Year filter */
data-genre="{p.[genre].pluck('name').join(',')}" /* genre taxonomy filter */
data-type="{p.[pattern-type].pluck('name').join(',')}" /* type taxonomy filter */
class="ef-lib-item">Component Structure
Typical page structure:
Archive Filters
↓
Controls
↓
Results Loop
↓
Load More
↓
Empty State
Required Controller
The controller initializes the entire filter system.
Example:
<div
data-af-controller="articles"
data-af-fields="kind,year,reading-time">
</div>Filter Fields
The Fields property specifies which values should be filterable.
Example
kind,year,reading-time
Every field listed here must exist on every loop item.
Loop Parent (UL)
The parent container needs the following CSS to hide filter content and to provide group styles:
& [data-af-item][hidden],
& [data-af-group][hidden] {
display: none !important;
}
.archive-filter__group--level-1 {
position: relative;
}
.archive-filter__group-items--level-1 {
gap: calc(var(--grid-gap) / 2);
}
& .archive-filter__group-header--secondary {
display: flex;
flex-direction: row;
align-items: center;
}
& .archive-filter__group-count--level-2 {
text-wrap: nowrap;
}
& .archive-filter__group-heading--secondary {
inline-size: 100%;
min-inline-size: 0;
display: flex;
align-items: center;
gap: 1rem;
font-size: var(--text-m);
&::after {
content: '';
flex: 1;
block-size: 2px;
margin-inline: 2rem;
background-color: color-mix(in oklch, var(--primary) 20%, transparent);
}
}
& .archive-filter__group-count--level-1 {
font-size: var(--text-xs);
text-transform: uppercase;
letter-spacing: 0.1em;
opacity: 0.8;
}
& .archive-filter__group-header--level-1 {
display: grid;
grid-template-columns: 1fr auto;
align-items: center;
gap: var(--card-gap);
padding-block: var(--space-s);
& .archive-filter__group-count {
text-transform: uppercase;
font-size: var(--text-s);
opacity: 0.6;
}
& .archive-filter__group-heading--level-1 {
font-size: calc(var(--h1-to-h3) * 1.25);
font-family: var(--serif);
font-weight: 300;
display: flex;
align-items: center;
gap: 1rem;
max-inline-size: 100%;
&::after {
content: '';
flex: 1;
block-size: 2px;
margin-inline: 2rem;
background-color: color-mix(in oklch, var(--primary) 20%, transparent);
}
}
}
CSSLoop Item Requirements
Every item in the results loop must include:
data-af-item
Example
<article
data-af-item
data-kind="Accessibility"
data-year="2026"
data-month="July"
data-reading-time="4">The component reads these attributes to determine whether the item should be displayed.
Supported Data Attributes
Title
Used by Search.
data-title="Building Better Components"
Kind
Example
data-kind="Tutorial"
Multiple values
data-kind="Tutorial,Accessibility"
Year
data-year="2026"
Month
data-month="July"Used for secondary grouping.
Reading Time
Provide the numeric reading time.
data-reading-time="6"The component automatically converts this into:
0–3 minutes → Short
4–7 minutes → Medium
8+ minutes → Long
Users never see the numeric value.
Multiple Values
Fields may contain comma-separated values.
Example
data-kind="Tutorial,Accessibility"
Selecting either value will match the item.
Search
Search looks at
- data-title
- visible text inside the item
No additional configuration is required.
URL History
When enabled,
Show Search
URL Historythe current filters are written into the URL.
Example
?af_articles_kind=Accessibilityor
?af_articles_search=etchRefreshing or sharing the URL restores the filters automatically.
Grouping
Grouping creates nested archive sections.
Example
2026
July
Article
June
Article
2025
December
Primary grouping is required.
Secondary and tertiary grouping are optional.
Date Sorting
When grouping by
- Year
- Month
The component automatically sorts chronologically instead of alphabetically.
Descending:
2026
2025
2024
Ascending:
2022
2023
2024
Months are also sorted correctly.
January
February
...
December
Result Counts
The component can display
58 Results
or
22 of 58 Results
depending on whether filters are active.
Group headings can also display counts.
Example
2026 (18)
Filter Chips
When enabled, active filters appear as removable chips.
Example
Accessibility ×
2026 ×
Medium ×
Clear All
Each chip removes only its own filter.
Pagination
When grouping is disabled, pagination becomes available.
Options
10
20
50
100
AllThe user selects how many results are initially shown.
Load More
Instead of pagination links, additional results can be revealed.
Example
Load More (25)
The number indicates how many items remain hidden.
Once all items are visible the button automatically hides.
Empty State
If no items match,
No matching articles found.
the empty state becomes visible automatically.
Multiple Filter Components
Multiple controllers can exist on one page.
Example
articles
plugins
patterns
videos
Each controller operates independently.
Accordion Integration
The filter component can integrate with the FW Accordion component.
Add
data-af-heading="articles"
to the accordion wrapper.
The filter automatically adds
data-af-filters-active="true"
whenever filters are active.
Example CSS
[data-af-heading][data-af-filters-active='true'] {
.fw-accordion__title::after {
content: " (Applied)";
}
}This visually indicates that filters are active without modifying the accordion markup.
Accessibility
The component includes:
- Keyboard accessible buttons
- aria-pressed states
- Live result announcements
- Accessible search
- Accessible filter chips
- Accessible group headings
- Proper heading hierarchy
- Region announcements
- Screen-reader friendly Load More button
Complete Example
<article
data-af-item
data-title="Building Better Components"
data-kind="Tutorial,Accessibility"
data-year="2026"
data-month="July"
data-reading-time="6">
</article>Required Data Attributes
| Attribute | Required | Purpose |
|---|---|---|
| data-af-item | ✔ | Marks a filterable item |
| data-title | Recommended | Used by Search |
| data-kind | Optional | Filter field |
| data-year | Optional | Filter or grouping |
| data-month | Optional | Secondary grouping |
| data-reading-time | Optional | Reading Time filter |
Required Matching
Every field listed in
data-af-fields
must exist on every loop item.
Example
Controller
data-af-fields="kind,year"
Loop Item
<article
data-af-item
data-kind="Tutorial"
data-year="2026">If a field is missing, that item cannot be filtered correctly.
Best Practices
- Use descriptive field names.
- Keep field values consistent.
- Prefer comma-separated values for multi-select fields.
- Always include
data-title. - Use URL History for archive pages.
- Use grouping for chronological archives.
- Use pagination only when grouping is disabled.
- Use filter chips so users can easily remove active filters.
- Pair the component with the Accordion integration to provide a clear visual indication when filters are active.