Facet Collapse Extension
This extension makes the search facets collapsible. This includes facets for the dataset and organization pages.
Requirements
- JQuery and Bootstrap (included by default in CKAN)
- CKAN 2.10 or 2.11
Features
- Collapsible facets on search pages
- Four available default states:
collapse - Collapse all (default)
expand-first - Collapse all but first
expand-navs - Collapse empty
expand-all - Collapse none
- Administrator interface configuration
- CSS classes for custom styling:
expanded
collapsed
nothing-to-reveal (when no facets match the search)
Installation
git clone https://github.com/okfn/ckanext-facetcollapse.git
cd ckanext-facetcollapse
python setup.py develop
Configuration
ckan.plugins = facetcollapse
# Set default state for facets
ckanext.facetcollpase.default = collapse # Options: collapse, expand-first, expand-navs, expand-all
Settings can also be modified via the CKAN Administrator Interface under Customizing Look and Feel.
Note
Developed by Open Knowledge Foundation. Actively maintained with support for CKAN 2.10 and 2.11.