Skip to content
This repository has been archived by the owner on Oct 20, 2023. It is now read-only.

Cannot click on html tags within select items #14

Closed
samupl opened this issue Oct 9, 2017 · 5 comments
Closed

Cannot click on html tags within select items #14

samupl opened this issue Oct 9, 2017 · 5 comments

Comments

@samupl
Copy link

samupl commented Oct 9, 2017

When including HTML tags into the select items of the dropdown, a user is unable to select said item if he doesn't click on a text element that's a direct child of the select option.

Plunkr to reproduce: http://plnkr.co/edit/EmAzuCFJ1Iwcl47JOOzg?p=preview

In the plunkr above, if you click on the "Test" text, the selection works fine. If you click on the "Some other text" <small> element, the whole selectMatch callback doesn't get called. This worked in ng2-select.

img

@psilospore psilospore added the bug label Oct 19, 2017
@psilospore
Copy link
Owner

Hey @samupl thanks for submitting this bug! I'm not sure if I will ever get the chance to look at this anything soon. I am willing to accept any PRs to fix this though.

@samupl
Copy link
Author

samupl commented Nov 3, 2017

Could you give me some insight on how to build & run the app that's inside demo/? I can't find any instruction on this, and unfortunatelly npm link doesn't want to work on my setup.

Update: I actually managed to find instruction in package.json, although I also can't get it working. If you could help me setup a local development environment, I'll be more than happy to try to fix this issue: https://pastebin.com/4AfccQHB

@psilospore
Copy link
Owner

I've never gotten aot to work. Instead I use npm run startNoAot for local development. Thanks for looking into this!

@samupl
Copy link
Author

samupl commented Nov 6, 2017

Thanks. Weirdly though, I can't reproduce the problem when running local development instance. So perhaps this is related to AOT? I'm not sure if I can disable AOT on plunkr though.

@psilospore
Copy link
Owner

I could maybe have a look Saturday. I haven't used Angular for a while though, and I don't know what AOT really does.

One thing you could do is try to build locally without AOT then test on your app doing this http://podefr.tumblr.com/post/30488475488/locally-test-your-npm-modules-without-publishing
I believe you want to do something like this

npm run build
cd build
npm pack

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants