wadackel / react-stack-grid

Pinterest like layout components for React.js
https://wadackel.github.io/react-stack-grid/
MIT License
870 stars 77 forks source link

horizontal prop #27

Closed ilyalesik closed 7 years ago

ilyalesik commented 7 years ago

Related to https://github.com/tsuyoshiwada/react-stack-grid/issues/25

wadackel commented 7 years ago

Hi @ilyalesik. Thank you for contribute :+1: I confirmed that it is working.

It seems that a Lint error has occurred, please confirm with $ npm test and make correction :smiley:

ilyalesik commented 7 years ago

Hi, @tsuyoshiwada There is message 109:3 error Prop typeobjectis forbidden react/forbid-prop-types StackGrid.js: 109: style: PropTypes.object, I did not change this line in my pull-request.

This can be seen in the log https://travis-ci.org/tsuyoshiwada/react-stack-grid/jobs/275429565

wadackel commented 7 years ago

@ilyalesik I am sorry, I missed it ... :scream: There is an error similarly in master. Since I will fix it, there is no problem with PR! Thanks.

ilyalesik commented 7 years ago

Thanks!

wadackel commented 7 years ago

@ilyalesik Released as v0.5.0 :tada:

ilyalesik commented 7 years ago

That's great! I think in the future it will be possible to implement different distribution (order) of elements with 'strategy' pattern. There could be a parameter distribution for StackGrid component, function like this: ([{height, ...},...], maxColumn) => [{top, left, width, height},...] It would be two options "out of the box" - import {DefaultDistribution, HorizontalDistribution} from 'react-stack-grid'. This would allow developers to customize the order more flexibly.

wadackel commented 7 years ago

@ilyalesik It looks like a good idea! PR is always welcome :smile: