@@ -60,6 +60,8 @@ const OptionList: React.ForwardRefRenderFunction<RefOptionListProps, {}> = (_, r
6060    listHeight, 
6161    listItemHeight, 
6262    optionRender, 
63+     classNames : contextClassNames , 
64+     styles : contextStyles , 
6365  }  =  React . useContext ( SelectContext ) ; 
6466
6567  const  itemPrefixCls  =  `${ prefixCls }  ; 
@@ -327,6 +329,8 @@ const OptionList: React.ForwardRefRenderFunction<RefOptionListProps, {}> = (_, r
327329        direction = { direction } 
328330        innerProps = { virtual  ? null  : a11yProps } 
329331        showScrollBar = { showScrollBar } 
332+         className = { contextClassNames ?. list } 
333+         style = { contextStyles ?. list } 
330334      > 
331335        { ( item ,  itemIndex )  =>  { 
332336          const  {  group,  groupOption,  data,  label,  value }  =  item ; 
@@ -355,12 +359,18 @@ const OptionList: React.ForwardRefRenderFunction<RefOptionListProps, {}> = (_, r
355359          const  mergedDisabled  =  disabled  ||  ( ! selected  &&  overMaxCount ) ; 
356360
357361          const  optionPrefixCls  =  `${ itemPrefixCls }  ; 
358-           const  optionClassName  =  classNames ( itemPrefixCls ,  optionPrefixCls ,  className ,  { 
359-             [ `${ optionPrefixCls }  ] : groupOption , 
360-             [ `${ optionPrefixCls }  ] : activeIndex  ===  itemIndex  &&  ! mergedDisabled , 
361-             [ `${ optionPrefixCls }  ] : mergedDisabled , 
362-             [ `${ optionPrefixCls }  ] : selected , 
363-           } ) ; 
362+           const  optionClassName  =  classNames ( 
363+             itemPrefixCls , 
364+             optionPrefixCls , 
365+             className , 
366+             contextClassNames ?. listItem , 
367+             { 
368+               [ `${ optionPrefixCls }  ] : groupOption , 
369+               [ `${ optionPrefixCls }  ] : activeIndex  ===  itemIndex  &&  ! mergedDisabled , 
370+               [ `${ optionPrefixCls }  ] : mergedDisabled , 
371+               [ `${ optionPrefixCls }  ] : selected , 
372+             } , 
373+           ) ; 
364374
365375          const  mergedLabel  =  getLabel ( item ) ; 
366376
@@ -393,7 +403,7 @@ const OptionList: React.ForwardRefRenderFunction<RefOptionListProps, {}> = (_, r
393403                  onSelectValue ( value ) ; 
394404                } 
395405              } } 
396-               style = { style } 
406+               style = { {  ... contextStyles ?. listItem ,  ... style   } } 
397407            > 
398408              < div  className = { `${ optionPrefixCls }  } > 
399409                { typeof  optionRender  ===  'function' 
0 commit comments