srigar / multiselect-react-dropdown

React multiselect dropdown with search and various options
https://10xn41w767.codesandbox.io/
MIT License
200 stars 113 forks source link

Bundled css is causing empty content when defining customArrow #234

Open olaplassen opened 1 year ago

olaplassen commented 1 year ago

Hi, I am defining a custom arrow but getting and white outline box above the arrow icon. (See attacthed screenshot) It looks like it comes from some bundled css definition. See screenshot below.

.icon_down_dir:before {
    content: "\e803";
}

Defined custom arrow as follow:

showArrow={true}
customArrow={<img src={dropDownIcon} alt="" />}

Does anyone know if there is a workaround for this?

additional icon css
paniTani commented 1 year ago

Hi @olaplassen.

I added showArrow customArrow={true}

and then restyle content prop with proper image via content: url(...): e.g. .icon_down_dir::before { content: url("arrow.svg"); }

This approach works for me.