【发布时间】:2021-06-14 21:07:02
【问题描述】:
我想要做的是框内的背景颜色保持着色 0.5 秒然后消失。比如当你点击YouTube评论警报时,框内的背景颜色消失了。
第一次渲染时
0.5秒后背景色就这样消失了
这是我的代码
const Container = styled.View`
border-bottom-color: lightblue;
`;
const CommentContainer = styled.View`
`;
const SecondCommentCon = styled.View`
`;
const UnserName = styled.Text`
`;
const Label = styled.Text`
`;
const TodoList = ({}) => {
return (
<Container>
<CommentContainer>
<SecondCommentCon>
<UnserName>{yes?.[0]?.User?.nickname}</UnserName>
<Label>{yes?.[0]?.content}</Label>
</SecondCommentCon>
</CommentContainer>
</Container>
)
我应该添加什么代码??
【问题讨论】:
-
你试过我发布的答案了吗?考虑提供一些反馈,谢谢!
-
@axtck 对作品中的迟到反馈感到抱歉!谢谢!!!!
-
很高兴为您提供帮助!祝你好运
标签: javascript css reactjs react-native styled-components