Problem/Motivation

Facets 3 introduced facets_exposed_filters. For numeric exposed filters, there is currently no dedicated range-slider processor/widget integration that supports:

  • min/max range normalization for exposed input
  • range boundary calculation from facet results
  • Better Exposed Filters slider UI with optional snap-to-available-values
  • Solr-specific handling to avoid self-filtered min/max boundaries

Steps to reproduce

  1. Create a Search API view with a numeric exposed facet filter.
  2. Try to configure it as a range-slider-style exposed filter (BEF).
  3. Observe that there is no dedicated exposed-range-slider processor/widget flow in facets_exposed_filters.

Proposed resolution

  • Add new processor plugin: exposed_range_slider in facets_exposed_filters.
  • Add new BEF widget plugin: facets_exposed_range_slider.
  • Add dedicated JS behavior/library for exposed range sliders.
  • Extend config schema for processor + BEF widget settings.
  • Update hook implementation to:
    • store raw facet results for snap-value extraction
    • force OR operator for Solr when exposed range slider processor is enabled (to prevent self-filtered boundaries)
  • Adjust FacetsFilter active-item handling so exposed min/max survives pre-query normalization and rebuilds.

User interface changes

  • New processor option: Exposed range slider in facet filter extra options.
  • New BEF filter widget: Exposed facet range slider.
  • Optional BEF setting: Snap to available facet values.

API changes

  • New plugin ID: exposed_range_slider (facets processor).
  • New plugin ID: facets_exposed_range_slider (BEF filter widget).
  • New schema entries for these plugin configurations.

Release notes snippet

Facets exposed filters now support a dedicated numeric range slider integration (processor + BEF widget), including optional snap-to-values behavior and improved Solr boundary handling.

CommentFileSizeAuthor
#6 3589695-exposed-range-slider-6.patch46.83 KBjonasanne

Issue fork facets-3589695

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

danielehrenhofer created an issue. See original summary.

danielehrenhofer’s picture

danielehrenhofer’s picture

Status: Active » Needs review
danielehrenhofer’s picture

jonasanne’s picture

StatusFileSize
new46.83 KB

I rerolled the patch against 3.0.3 since the diff no longer applies.
I tested this, and it looks like it's working.