【发布时间】:2018-04-04 22:12:09
【问题描述】:
我以前有这个,效果很好:
<div className="right mr3 relative center" style={{ marginTop: -300, zIndex: 2 }}>
现在我需要将整个类和内联样式作为道具传递,
tooltipClassName={"right mr3 relative center" style={{ marginTop: -300, zIndex: 2 }}}
然后像这样调用那个类<div className={tooltipClassName}>
也许我需要使用字符串插值或传递另一个道具作为样式,但我不知道。
【问题讨论】: