Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add citation marks around CSS selectors #62

Closed
d-tamm opened this issue Jun 17, 2021 · 1 comment
Closed

Add citation marks around CSS selectors #62

d-tamm opened this issue Jun 17, 2021 · 1 comment

Comments

@d-tamm
Copy link

d-tamm commented Jun 17, 2021

In tagging.js on line 617, there should be citation marks around the CSS selector like this:
$tag = self.$elem.find( "input[value='" + text + "']" ).parent();
rather than:
$tag = self.$elem.find( "input[value=" + text + "]" ).parent();

As it is now, the selector will fail finding tags e.g. containing a fullstop or an at (@).

Error messages from a simple usage example:

$("#tagBox").tagging("remove", "tag.1");
Uncaught Error: Syntax error, unrecognized expression: input[value=tag.1]
    jQuery 5
    remove tagging.js:617
    tagging tagging.js:806
    jQuery 2
    tagging tagging.js:786
    <anonymous> debugger eval code:1

Maybe there is even some more work to do to make it function correctly even with tags containing citation marks.
Otherwise, thank you for this great project!

@d-tamm
Copy link
Author

d-tamm commented Jun 17, 2021

Ah, now I found the pull request #54 which addresses this issue. :)

@d-tamm d-tamm closed this as completed Jun 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant