Skip to content

Commit

Permalink
feat(Progress): add single line progress handling and example (#1335)
Browse files Browse the repository at this point in the history
* feat(Progress): add single line progress handling and example

* feat(Progress): handle empty string title as well in addition to null title

* fix(Progress): fix title default

* fix(Progress): remove extra title assignment
  • Loading branch information
kmcfaul authored and tlabaj committed Feb 18, 2019
1 parent eecc4cf commit 592ffdb
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 60 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import ProgressWithoutMeasure from './examples/ProgressWithoutMeasure';
import SmallProgress from './examples/SmallProgress';
import ProgressWithDynamicDescription from './examples/ProgressWithDynamicDescription';
import LabeledProgress from './examples/LabeledProgress';
import SingleLineProgress from './examples/SingleLineProgress';

export default {
title: 'Progress',
Expand All @@ -34,6 +35,7 @@ export default {
{ component: ProgressFailure, title: 'Progress Failure' },
{ component: ProgressInsideSuccess, title: 'Progress Inside Success' },
{ component: ProgressOutsideFailure, title: 'Progress Outside Failure' },
{ component: SingleLineProgress, title: 'Progress on Single Line' },
{ component: ProgressWithoutMeasure, title: 'Progress Without Measure' },
{ component: ProgressFailureWithoutMeasure, title: 'Progress Failure Without Measure' },
{ component: ProgressWithDynamicDescription, title: 'Progress with Dynamic Description' }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ class Progress extends Component {
getModifier(styles, variant, ''),
getModifier(styles, measureLocation, ''),
getModifier(styles, measureLocation === ProgressMeasureLocation.inside ? ProgressSize.lg : size, ''),
!title && getModifier(styles, 'singleline', ''),
className
)}
id={this.id}
Expand Down
Loading

0 comments on commit 592ffdb

Please sign in to comment.