Is there a way to pass custom <icon />
component inside smart select’s options instead of default <i class="icon" />
?
I’m aware that with data-option-icon
attribute I can pass a custom class name, but since I’m not using icon fonts, is there a workaround for components?
It seems that everything inside <option></option>
is formatted before render and only the text remains.
EXAMPLES
What is working:
<select><option value="home" data-option-icon="wi-home">Home</option</select>
What i need (ideally):
<select><option value="home"><icon ico="google" /><div>Home</div></option></select>
Or at least:
<select><option value="home"><div class="item-media"><icon ico="google" /></div><div class="item-inner"><div class="item-title">Home</div></div></option></select>