The Brands Filter is a Gutenberg block or shortcode that shows a complete list with all brands and gives you the possibility to filter them by name.
Following you find the options of Gutenberg block.
- Title: you can enter a custom title before this block
- Paginate items: choose whether to paginate the items or not
- Items per page: if you paginate items, you can choose how many items per page to show
- Show only brands of the current category: enable this option to dinamically show only the brands of the current category. This option is useful if you are displaying this block on a category page or on a filtered page.
- Enter the list of category slugs (separated with a comma) to show. Leave empty to show all categories. This option overrides the previous option.
- Enter the list of brand slugs (separated with a comma) to show. Leave empty to show all brands.
- Enter the parent brand ID to show. All the sub-brands will be displayed. Leave empty to show all brands.
- Order by – choose here how to sort the displayed brands:
- Term ID
- Order – if any order option has been selected, choose whether to sort them:
- Show filters: choose whether to show or not letter filters just below the title.
- Show reset button: this will display a reset button, to quicky reset the filter.
- Show all filters or just filters with content (that include at least one brand).
- Show items count for each brand: this allows you to show a counter with the total number of products in each brand.
- Hide brands with no products: choose whether or not to hide brands that do not include any product.
- Shortcode style:
- Big header
- Small header
- Highlight color selector (available only for the Hightlight style and if the Show items count is enabled): this is the accent color of the counter items.
The same options are available in the shortcode as attributes. Below you find all the attributes and their accepted values.
- ‘title’: shortcode title
- ‘pagination’: [yes / no] enable/disable brand pagination
- ‘per_page’: [int] brands shown at a time per page
- ‘autosense_category’: [yes / no] if set to ‘yes’ it only shows the brands of the current category.
- ‘category’: [ids / all] it shows one or more product categories; you can specify more than one category slug and separate them using commas (10,20,12) or select them all by specifying the value ‘all’ for the attribute.
- ‘show_filter’: [yes / no] it allows brand filter
- ‘show_reset’: [yes / no] it allows filter reset
- ‘show_all_letters’: [yes / no] it shows all letters to filter brands by name
- ‘show_count’: [yes / no] show the amount of products associated to each brand
- ‘hide_empty’: [yes / no] it hides brands that have no products associated
- ‘style’: [default / big-header / small-header / shadow / boxed / highlight] style to assign to the shortcode
- ‘highlight_color’: code for the colour to assign to the text in the shortcode (available only if ‘highlited’ style is selected)
[yith_wcbr_brand_filter title="Brand Filter (default style)" pagination="no" show_filter="yes" show_reset="yes" show_all_letters="yes" show_count="yes" hide_empty="yes" style="default" highlight_color="#ffd900"]