Home Work
SaaS developmentAI developmentAPI developmentMobile app developmentGoogle Ads managementHeadless ShopifyLaravel developmentNext.js developmentReact developmentTypeScript engineeringUI/UX designSEO & AEOEcommerce development
AI solutionsB2B platformsE-commerceHospitalityLead generationLogisticsEducationProcess automationSaaS platformsStartup MVPReal estateHealthcare
LegalHealthcareReal estateFinanceHospitality
The HagueRotterdamAmsterdamUtrechtEindhovenAlmereBredaArnhemNijmegenTilburgEnschedeGroningenLeidenDelftZoetermeerDen Bosch
Studio
AboutProcessLabBlogContact

Filterchips met popover New

Filter bar for property listings: each chip opens a popover with multiple choices and counts per option, active chips turn dark with their own clear button, plus "Clear all", an active filter count, a result count and an empty state with one way out. Narrow screens get a single "Filters (3)" button. Popover API with CSS anchor positioning (fallback: JS positioning, and a class toggle with Esc and outside click without the popover API).

0 woningen

Geen filters actief

    How to use it

    1. Paste the HTML where the forms & inputs should appear.
    2. Add the CSS to your stylesheet. All classes are prefixed, so nothing clashes with your own styles.
    3. Add the JavaScript and call init() with the element that contains the HTML.
    <!-- Filterchips met popover · NedDev · eigen werk. -->
    <div class="jouw-container">
    <div class="fcp"><div class="fcp__in">
    <div class="fcp__bar">
    <div class="fcp__chips" role="group" aria-label="Filters">
    <span class="fcp__cw" data-g="plaats"><button type="button" class="fcp__chip" popovertarget="fcp-p-plaats"><span class="fcp__cl">Plaats</span><svg viewBox="0 0 10 6" aria-hidden="true"><path d="M1 1l4 4 4-4"/></svg></button><button type="button" class="fcp__x" aria-label="Wis filter Plaats" hidden><svg viewBox="0 0 10 10" aria-hidden="true"><path d="M2 2l6 6M8 2L2 8"/></svg></button></span>
    <span class="fcp__cw" data-g="type"><button type="button" class="fcp__chip" popovertarget="fcp-p-type"><span class="fcp__cl">Type</span><svg viewBox="0 0 10 6" aria-hidden="true"><path d="M1 1l4 4 4-4"/></svg></button><button type="button" class="fcp__x" aria-label="Wis filter Type" hidden><svg viewBox="0 0 10 10" aria-hidden="true"><path d="M2 2l6 6M8 2L2 8"/></svg></button></span>
    <span class="fcp__cw" data-g="prijs"><button type="button" class="fcp__chip" popovertarget="fcp-p-prijs"><span class="fcp__cl">Prijs</span><svg viewBox="0 0 10 6" aria-hidden="true"><path d="M1 1l4 4 4-4"/></svg></button><button type="button" class="fcp__x" aria-label="Wis filter Prijs" hidden><svg viewBox="0 0 10 10" aria-hidden="true"><path d="M2 2l6 6M8 2L2 8"/></svg></button></span>
    <span class="fcp__cw" data-g="extra"><button type="button" class="fcp__chip" popovertarget="fcp-p-extra"><span class="fcp__cl">Extra</span><svg viewBox="0 0 10 6" aria-hidden="true"><path d="M1 1l4 4 4-4"/></svg></button><button type="button" class="fcp__x" aria-label="Wis filter Extra" hidden><svg viewBox="0 0 10 10" aria-hidden="true"><path d="M2 2l6 6M8 2L2 8"/></svg></button></span>
    </div>
    <button type="button" class="fcp__mob" popovertarget="fcp-p-all">Filters<span class="fcp__mn"></span></button>
    </div>
    <div class="fcp__sum"><p class="fcp__res" aria-live="polite"><b>0</b> woningen</p><p class="fcp__act"><span class="fcp__ac">Geen filters actief</span><button type="button" class="fcp__clear" hidden>Wis alles</button></p></div>
    <ul class="fcp__list"></ul>
    <div class="fcp__empty" hidden><p><b>Geen woningen met deze filters.</b> Haal een filter weg of begin opnieuw.</p><button type="button" class="fcp__clear2">Wis alle filters</button></div>
    <div class="fcp__pop" id="fcp-p-plaats" popover data-g="plaats" role="dialog" aria-label="Filter op plaats"></div>
    <div class="fcp__pop" id="fcp-p-type" popover data-g="type" role="dialog" aria-label="Filter op type woning"></div>
    <div class="fcp__pop" id="fcp-p-prijs" popover data-g="prijs" role="dialog" aria-label="Filter op prijs"></div>
    <div class="fcp__pop" id="fcp-p-extra" popover data-g="extra" role="dialog" aria-label="Filter op extra's"></div>
    <div class="fcp__pop fcp__pop--all" id="fcp-p-all" popover data-g="all" role="dialog" aria-label="Alle filters"></div>
    </div></div>
    </div>

    More forms & inputs

    Seen something you like?

    Add it to your selection and send it over. We build your site around it, in your brand.

    Get in touch →