Skip to content

Commit

Permalink
Merge pull request #32 from derBertW/withStyleName
Browse files Browse the repository at this point in the history
added withStyleName methods to layout, row and column (resolves #30)
  • Loading branch information
JarekToro committed Feb 14, 2017
2 parents c5bc07d + 7a4c9c7 commit ded7893
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,11 @@ public ResponsiveColumn withComponent(Component component, ColumnComponentAlignm
return this;
}

public ResponsiveColumn withStyleName(String styleName) {
addStyleName(styleName);
return this;
}

@Deprecated
public ResponsiveColumn withRightAlignedComponent(Component component) {
setAlignment(ColumnComponentAlignment.RIGHT);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ public void setScrollable(boolean scrollable) {
removeStyleName(CSS_CONTAINER_SCROLLABLE);
}
}

public ResponsiveLayout withStyleName(String styleName) {
addStyleName(styleName);
return this;
}

/**
* Adds the {@code ResponsiveRow} provided as a component.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -390,5 +390,9 @@ public ResponsiveRow withHorizontalSpacing(SpacingSize size, boolean spacing) {
return this;
}

public ResponsiveRow withStyleName(String styleName) {
addStyleName(styleName);
return this;
}

}
}

0 comments on commit ded7893

Please sign in to comment.