未验证 提交 2c3794e2 编写于 作者: M Maxime Beauchemin 提交者: GitHub

[design] use angle icons instead of carets for expandable panels (#6564)

* [design] use angle icons instead of carets for expandable panels

Also moving to the right to conform to the material design specs

* Fix cypress test
上级 a0b2f2ca
......@@ -208,6 +208,7 @@ describe('Advanced analytics', () => {
cy.get('span')
.contains('Advanced Analytics')
.parent()
.siblings()
.first()
.click();
......
......@@ -31,21 +31,21 @@ export default class ControlPanelSection extends React.Component {
return (
label &&
<div>
<span>
<span onClick={this.toggleExpand.bind(this)}>{label}</span>
{' '}
{description && <InfoTooltipWithTrigger label={label} tooltip={description} />}
{hasErrors &&
<InfoTooltipWithTrigger
label="validation-errors"
bsStyle="danger"
tooltip="This section contains validation errors"
/>}
</span>
<i
className={`text-primary expander fa fa-caret-${this.state.expanded ? 'down' : 'right'}`}
className={`float-right fa-lg text-primary expander fa fa-angle-${this.state.expanded ? 'up' : 'down'}`}
onClick={this.toggleExpand.bind(this)}
/>
{' '}
<span onClick={this.toggleExpand.bind(this)}>{label}</span>
{' '}
{description && <InfoTooltipWithTrigger label={label} tooltip={description} />}
{hasErrors &&
<InfoTooltipWithTrigger
label="validation-errors"
bsStyle="danger"
tooltip="This section contains validation errors"
/>
}
</div>);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册