The jQuery plugin MixItUp implements animation filtering and sorting, and jquerymixitup

Source: Internet
Author: User

The jQuery plugin MixItUp implements animation filtering and sorting, and jquerymixitup

What is MixItUp?

MixItUp is a jQuery plug-in that provides animation filtering and sorting.
MixItUp is great, like managing portfolio, gallery and Blog content in any category or sort, and can also be used as a powerful tool, engage in application user interface and data visualization.
MixItUp works well with your existing HTML and CSS, making it an excellent choice for response layout.
Instead of using absolute positioning to control the layout, the MixItUp design works with the existing online stream layout. Do you want to use percentages, media queries, inline-block, or even curved boxes? No problem!

Page code

<div id="Container">   <div class="mix category-1" data-my-order="1"> ... </div>   <div class="mix category-1" data-my-order="2"> ... </div>   <div class="mix category-2" data-my-order="3"> ... </div>   <div class="mix category-2" data-my-order="4"> ... </div> </div> 

MixItUp elements in the target and class hybrid containers. CATEGORY filtering adds custom data attributes for class and sorting attributes.

Create your filter control:

class="filter" data-filter=".category-1">Category 1 class="filter" data-filter=".category-2">Category 2 

Filter occurs when the Filter button is clicked.

Create your sorting control:

class="sort" data-sort="my-order:asc">Ascending Order class="sort" data-sort="my-order:desc">Descending Order 

The sorting occurs when the sorting button is clicked.

CSS

#Container .mix{   display: none; } 

In the style of the project, set the target element to no display attribute. MixItUp only displays the filter elements that match the current filter element.

JS

The jQuery container is used on the MixItUp instance:

$(function(){   $('#Container').mixItUp();  }); 

Using the container ID, we can instantiate the MixItUp and jQuery methods. mixItUp ()

View DEMO download now

The above is all the content of this article. I hope you will like it.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.