Using chosen.js, how would I add images to the dropdown items?

前端 未结 2 2103
無奈伤痛
無奈伤痛 2021-02-09 09:25

Using chosen.js, how would I add images to the dropdown items?

2条回答
  •  余生分开走
    2021-02-09 10:12

    To complete Joseph (I can't add comment to his answer), the class has changed since an unknown version: Here's the correct css in v1.0.0:

    li.active-result {
        background: url('path/to/img.png') no-repeat 3px center;
        text-indent:2em;
    }
    

    Thx Joseph!

提交回复
热议问题