Javascript flex容器中的react-select

Javascript flex容器中的react-select,javascript,reactjs,flexbox,react-select,Javascript,Reactjs,Flexbox,React Select,如何使react select尊重flex布局?下面这些都不起作用 const Container = styled('div')` width: 100%; height: 100%; display: flex; flex-flow: row wrap; justify-content: space-around; align-items: baseline; `; const selectStyles = { input: base =>

如何使react select尊重flex布局?下面这些都不起作用

 const Container = styled('div')`
   width: 100%;
   height: 100%;
   display: flex;
   flex-flow: row wrap;
   justify-content: space-around;
   align-items: baseline;
 `;

const selectStyles = {
  input: base => ({
    minWidth: 200,
    flex: 1,

<Container>
<Select
  style={{ flex: 1 }}
  styles={selectStyles}
const Container=styled('div'))`
宽度:100%;
身高:100%;
显示器:flex;
柔性流:行换行;
证明内容:周围的空间;
调整项目:基线;
`;
const selectStyles={
输入:base=>({
最小宽度:200,
弹性:1,

要使您的
react选择
component flex,您需要在容器上应用
flex:1
道具,如下所示:

const styles = {
  container: base => ({
    ...base,
    flex: 1
  })
};

<Select styles={styles} />
const styles={
容器:基=>({
基础
弹性:1
})
};

React select似乎不支持样式,也许您需要使用getStyles道具