Filtrify

用HTML5和jQuery实现的漂亮的高级标签过滤器。(Beautiful advanced tag filtering with HTML5 and jQuery. )

Github stars Tracking Chart

Filtrify是高级标签过滤插件,灵感来自于 Chosen 多重选择功能和Orman Clark的垂直导航菜单

高级,因为您可以在标签中搜索标签,并通过不同类别的多个标签过滤项目,并获取有关包含相关标签的项目数量的实时反馈。
Filtrify利用新的HTML5“数据”属性来存储元数据。

怎样做?

所有你需要做的是为列表中的每个项目包含相应的标签(元数据)的“数据”属性。 如果您有多个类别的标签,请将它们包含在另一个“数据”属性中。 您可以根据需要添加多个类别的标签。
然后,Filtrify将通过您包含在项目中的所有数据属性,它将创建一个搜索菜单,其中提供了与您提供的不同类别(数据属性)一样多的字段。 菜单中的每个字段标签都会触发一个“弹出”过滤面板,并发生所有的魔术。

插件简化很简单,你只需要传递一个“containerID”和一个“placeHolderID”,它是要放置菜单的元素的ID。

Overview

Name With Ownerluis-almeida/filtrify
Primary LanguageJavaScript
Program languageJavaScript (Language Count: 1)
Platform
License:Other
Release Count0
Created At2012-03-19 23:16:23
Pushed At2020-10-07 17:09:23
Last Commit At2013-04-21 17:03:06
Stargazers Count641
Watchers Count40
Fork Count113
Commits Count31
Has Issues Enabled
Issues Count64
Issue Open Count48
Pull Requests Count0
Pull Requests Open Count4
Pull Requests Close Count3
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private

filtrify.js

What?

Filtrify is an advanced tag filtering plugin, inspired by Chosen multiple select feature and Orman Clark’s Vertical Navigation Menu.
Advanced because you can search tags within tags and filter items by multiple tags from different categories and get a live feedback on the number of items containing related tags.

How?

Filtrify makes use of the new HTML5 "data" attribute to store the metadata.
All you have to do is include a "data" attribute for each item in your list with the respective tags (metadata). If you have more than one category of tags, include them in another "data" attribute. You can add as much categories of tags as you need.
Filtrify will then go through all the data attributes you included in your items and it will create a search menu with as many fields as the different number of categories (data-attributes) you provided. Each field label in the menu fires a "popup" filtering panel and there's where all the magic happens.
The plugin instanciation is very simple, you just have to pass a "containerID" and a "placeHolderID" which is the ID of the element where you want to place the menu.

Visit filtrify's project page to read the documentation.

Demos

Browser compatibility (tested):

IE7 (buggy)
IE8+, Chrome, Firefox, Opera and Safari (current versions)

Release log:

#####v0.2 (04.04.2012)

  • Isotope integration demo added
  • Bug fix: search icon disappearance issue in the "jPages" demo

#####v0.1.1 (01.04.2012)

  • Bug fix: 1px jump when toggling the filter

#####v0.1 (22.03.2012)

  • First release
To the top