Skip to content

Commit ebefcc8

Browse files
authored
Merge pull request #2458 from appirio-tech/feature/v2-4-5-part4
Feature/v2 4 5 part4
2 parents 9e64a70 + 4e3304f commit ebefcc8

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/projects/detail/components/PhaseCard/PhaseCard.jsx

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import PT from 'prop-types'
88
import { connect } from 'react-redux'
99
import MediaQuery from 'react-responsive'
1010
import cn from 'classnames'
11+
import TextTruncate from 'react-text-truncate'
1112

1213
import {
1314
PHASE_STATUS,
@@ -108,7 +109,14 @@ class PhaseCard extends React.Component {
108109
<ProjectTypeIcon type={attr.icon} />
109110
</div>
110111
<div styleName="project-title-container">
111-
<h4 styleName="project-title">{attr.title}</h4>
112+
<h4 styleName="project-title">
113+
<TextTruncate
114+
containerClassName="project-description"
115+
line={!matches ? 2 : 5}
116+
truncateText="..."
117+
text={attr.title}
118+
/>
119+
</h4>
112120
{phaseEditable && !this.state.isEditting && (<a styleName="edit-btn" onClick={this.toggleEditView} />
113121
)}
114122
</div>

0 commit comments

Comments
 (0)