Minor collapsing button improvements~

th-downstream
kibigo! 7 years ago committed by beatrix-bitrot
parent 744917179b
commit 58cdc55bd5

@ -70,7 +70,7 @@ export default class IconButton extends React.PureComponent {
} }
return ( return (
<Motion defaultStyle={{ rotate: this.props.active ? (this.props.flip ? -180 : -360) : 0 }} style={{ rotate: this.props.animate ? spring(this.props.active ? (this.props.flip ? -180 : -360) : 0, { stiffness: 120, damping: 7 }) : 0 }}> <Motion defaultStyle={{ rotate: this.props.active ? (this.props.flip ? -180 : -360) : 0 }} style={{ rotate: this.props.animate ? spring(this.props.active ? (this.props.flip ? -180 : -360) : 0, { stiffness: this.props.flip ? 60 : 120, damping: 7 }) : 0 }}>
{({ rotate }) => {({ rotate }) =>
<button <button
aria-label={this.props.title} aria-label={this.props.title}

@ -238,7 +238,7 @@ export default class Status extends ImmutablePureComponent {
animate flip animate flip
active={isCollapsed} active={isCollapsed}
title={isCollapsed ? intl.formatMessage(messages.uncollapse) : intl.formatMessage(messages.collapse)} title={isCollapsed ? intl.formatMessage(messages.uncollapse) : intl.formatMessage(messages.collapse)}
icon='angle-double-down' icon='angle-double-up'
onClick={this.handleCollapsedClick} onClick={this.handleCollapsedClick}
/> />

Loading…
Cancel
Save