Can anyone tell me how I can create a drop-down list which contains radio buttons as its options in angularjs. I have rammaged the net and still didn't find any solutions. Wonder how no one found the need to do this. I'd be really glad if anyone could help me out here.
Asked
Active
Viewed 1,117 times
1
-
I think you can try to use `ui.bootstrap` dropdown with custom templates. You can put an entire HTML page in one of those, or your list of radio buttons. If you don't want `ui.bootstrap` just create a custom directive with the same idea – Aleksey Solovey Sep 14 '18 at 12:08
-
Thanks for the suggestion Aleksey, but I am relatively new to these stuffs. Would you mind if I asked you to kindly elaborate a bit? – Harshith Rai Sep 14 '18 at 12:13
-
it's not finished, but you can start with this example: [Plunker](https://plnkr.co/edit/UayfduPmUVfgAwgUKVjm?p=preview) (radio buttons are a bit complicated) – Aleksey Solovey Sep 14 '18 at 12:23
-
Dear Rai, it would be nice if you elaborate a bit on your question and post some code as well as describe problems you experience. It would increase probability of getting an answer. – Artem Sep 14 '18 at 12:24
-
yes Artem, I have just made an ordinary drop-down list using the `select`, and using `button type = radio` in the `option` part. But only the first one get gets displayed with the downward arrow, but it won't get clicked or expanded. – Harshith Rai Sep 17 '18 at 04:13