Skip to content

Conversation

@frabbit
Copy link
Contributor

@frabbit frabbit commented Aug 30, 2019

This PR is currently blocked by lightelligence-io/styles#19 and a subsequent npm release.

@frabbit frabbit changed the title feat: new grid [wip] feat: new grid Aug 30, 2019
@frabbit frabbit changed the title [wip] feat: new grid [blocked] feat: new grid Aug 30, 2019
@frabbit frabbit changed the title [blocked] feat: new grid feat: new grid Sep 3, 2019
@frabbit
Copy link
Contributor Author

frabbit commented Sep 3, 2019

This PR is currently blocked by lightelligence-io/styles#19 and a subsequent npm release.

it's ready to test now.

Copy link
Contributor

@jkettmann jkettmann left a comment

Choose a reason for hiding this comment

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

Additionally to the comments, I left in the code I also don't really see a difference between the three examples in the docs. Is there a way to make it easier to see?

* available for each row. Valid values are 1-12, "auto" or an object
* definining the size for each breakpoint individually like `{ xs: 12, sm: 6, md: 4, lg: 3 }`.
*/
size: oneOfType([number, string, shape({})]),
Copy link
Contributor

Choose a reason for hiding this comment

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

I would rather have explicit props xs={12} sm={6}.... This way we would also be able to replace the logic above by a simple array of class names similar to this

[
  xs && olt.V2GridItemXs12,
  ...
]

Material UI and Bootstrap React do it this way

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think the argument in the previous version was that breakpoints could be customized. But i guess that's a flawed argument because it's currently not really customizable. I will adjust this.

* available for each row. Valid values are 1-12 or an object
* definining the column offset for each breakpoint individually like `{ xs: 1, sm: 2, md: 3, lg: 4 }`.
*/
offset: oneOfType([number, shape({})]),
Copy link
Contributor

Choose a reason for hiding this comment

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

Here the same as the size prop

Copy link
Contributor Author

Choose a reason for hiding this comment

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

should we call this offsetXs, offsetSm etc. ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

and sizeXs, sizeXS or just xs?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

or better leave it as it is ;).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@JonathanStoye what's your opinion here?

Copy link
Contributor

Choose a reason for hiding this comment

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

I like offsetXs, offsetSm the most I guess. It is very expressive.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@JonathanStoye @jkettmann ok, i will change that, but keep in mind that everyone who has to upgrade from v1 to v2 will hate us a bit here ;).

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess I will be one of those people :-)

@frabbit frabbit requested a review from jkettmann September 10, 2019 15:31
@blumendorf blumendorf merged commit 4a655fa into feat_design-system-2 Sep 13, 2019
@blumendorf blumendorf deleted the feat_new-grid branch September 13, 2019 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants