Search code examples
cssreactjsfluentui-react

cannot figure out how to control width of react-northstar Dropdown


I uploaded a sample to my github here: https://github.com/gyrevik/dropdown-width/blob/master/src/App.js

Where I'm trying to control width like this:

  <Dropdown
    styles={{width: '25px'}}
    items={inputItems}
    placeholder="Select your hero"
    checkable
    getA11ySelectionMessage={{
      onAdd: item => `${item} has been selected.`,
    }}
  />

and deployed to vercel here: https://dropdown-width.vercel.app/

I haven't found a styling approach that works yet. Thanks in advance for looking at this!


Solution

  • It works with the fluid property.