Code Monkey home page Code Monkey logo

tagsort's People

Contributors

beerendlauwers avatar cvipul avatar wchaering avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tagsort's Issues

Add a license

Would be good to add a LICENSE.md to this project.

Latest Version - Regex && Filtering?

Hi,

Just substituted the latest version into a working solution and now the tags get split all over the place even when setting tagDelimiter correctly, the filtering filters but removes the sorting for subsequent clicks.

However, reverting to

var elementTags = tagsData.match(/,\s+/) ? tagsData.split(', ') : tagsData.split(',');

fixes the tagging but it's still broken on second or third clicks...

tagDelimiter reference

Line 35:
var tagDelimiter = tagSortEngine.options.tagsDelimiter;

Needs to be:
var tagDelimiter = tagSortEngine.options.tagDelimiter;

The option is not tagsDelimiter it's tagDelimiter

Single tags don't work

data-item-tags="2017"

If the data-item-tags attribute only contains a single tag, then the script fails:

Uncaught TypeError: r.match is not a function
    at HTMLDivElement.<anonymous> (tagsort.min.js:1)
    at Function.each (jquery.min.js:2)
    at n.fn.init.each (jquery.min.js:2)
    at Object.generateTags (tagsort.min.js:1)
    at Object.inititalize (tagsort.min.js:1)
    at n.fn.init.e.fn.tagSort (tagsort.min.js:1)
    at HTMLDocument.<anonymous> (elliotlab.js:83)
    at i (jquery.min.js:2)
    at Object.fireWith [as resolveWith] (jquery.min.js:2)
    at Function.ready (jquery.min.js:2)

Is it possible for single tags to be accommodated?

Default Filter

Hello,
is it possible to create a start filter?
So that you only see the items of a specific "data-item-tag" at the beginning and not all entries?

Refreshing tag list when using dynamic item-to-filter

Hello,
I'm using tagsort and it works great.
I'm using it on a dynamic list of element: the list grows when adding item dymically.

  1. When adding items, they may come with new tags.
    So I was wondering if it would be possible to add the new tags to tags-container (i.e. refresh the list of tags). I'm currently doing it the hard way (empty tags-container and restart tagSort).
    It is not efficient, and I'm loosing what was selected.
    Do you see a alternative work around/solution?
  2. Is it possible to sort the tags (alphabetical order, for exemple.)

Many thanks.

P.

Sort tag list

I would love it, if there was an option to sort the tags list (itemTagsView) alphabetically (or maybe make it the default?).

Something nice to have would be a way specify pinned tags (I use a hidden dummy element that carries all tags that should be at the start of the list, and put it in front of all real items). But I don't really imagine a practical user interface for that. This one is really just an idea, whereas the sorting seems very important to me.

Applying Active Class to Reset

Hello there! Right now, I have my reset element set as:
<span class="tag-reset tagsort-active">All</span>

Is there a way to re-apply the tagsort-active class after other tags have been selected and the user goes back to All?

Thank you!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.