Skip to content

feat(Col): add custom widths ability to Col#309

Merged
eddywashere merged 1 commit intoreactstrap:masterfrom
TheSharpieOne:feature/custom-columns
Jan 28, 2017
Merged

feat(Col): add custom widths ability to Col#309
eddywashere merged 1 commit intoreactstrap:masterfrom
TheSharpieOne:feature/custom-columns

Conversation

@TheSharpieOne
Copy link
Copy Markdown
Member

closes #297

@TheSharpieOne TheSharpieOne force-pushed the feature/custom-columns branch from 17500ae to b6e2bf9 Compare January 27, 2017 04:53
@TheSharpieOne TheSharpieOne force-pushed the feature/custom-columns branch from b6e2bf9 to a6cfcf1 Compare January 27, 2017 05:05
Comment thread src/__tests__/Col.spec.js
});

it('should allow custom columns to be defined with objects', () => {
const wrapper = shallow(<Col widths={['base', 'jumbo', 'wtf']} wtf={{ size: 1, push: 2, pull: 3, offset: 4 }} />);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😆 just happy to have tests for this

Comment thread src/Col.js
}

const isXs = colWidth === 'xs';
const isXs = !i;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

very clever!

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, but I probably should have just went with i === 0 or something to be more clear. That's my bad.

@eddywashere eddywashere merged commit 8487598 into reactstrap:master Jan 28, 2017
@TheSharpieOne TheSharpieOne deleted the feature/custom-columns branch January 31, 2017 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add props for custom widths

2 participants