Search code examples
htmlreactjschakra-ui

Chakra UI : How can i change the color of Divider?


I'm trying to change the color of divider while it is not changing

<Stack color={'white'} >
           <HStack>
               <Text>Email</Text>
                 <Tag
                   size={'sm'}
                   borderRadius='full'
                   variant='solid'
                   colorScheme='green'>
                    
                   <TagLabel>verified</TagLabel>
                   </Tag>
                 </HStack>
                  <Divider color={'red'} />
           </Stack>

Solution

  • Just try to add borderColor on divider.

    <Stack color={'white'} >
               <HStack>
                   <Text>Email</Text>
                     <Tag
                       size={'sm'}
                       borderRadius='full'
                       variant='solid'
                       colorScheme='green'>
                        
                       <TagLabel>verified</TagLabel>
                       </Tag>
                     </HStack>
                      <Divider borderColor={'red'} />
               </Stack>