-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-organise pattern library #309
Comments
This point will be easy to address once we migrate to Fractal (see issue #264 / PR #262), since we can give such components a custom preview template that shows all possible states. Alternatively we can do them as "variants" with a collated preview. |
I've given it a bit of thought, and here's my proposal for an updated structure:
Introducing a new top-level and the dividing existing stuff into it aims to address a number of issues we currently have:
Overall, I think something like this structure would be big improvement over what we currently have. It'll be quite easy to implement in Fractal too, since that lets us have as many levels of navigation as we want. There'll be a few items that might feel a tad odd. For instance buttons will come under elements and not components - people familair with other design systems might find that a bit unintuitive. But, I think people actually using or working on Gravity will quickly get used to that. Besides, it's certainly no worse than it is today. :-) |
Given the lack of objections and counter-proposals, I'll make a start at implementing my proposed re-org in a PR. It'll probably take a while, so please be patient. Will report progress back here once there's something to see... |
Is your feature request related to a problem? Please describe.
Currently, the way patterns are organised in our online pattern library is a bot messy:
This causes a number of issues:
Describe the solution you'd like
We should:
Additional context
This came out of a chat with @dw-buildit today, while trying to decide where best to put a
.grav-o-two-column
class. Layout primitives like that don't fit well under atoms since they layout a set of other things, so they are inevitably applied to some kind of container. And yet, it's mot clear if they should be considered molecules or organisms, since we don't (and can't) know how complex the things being laid out will be.I'd argue utility classes have similar challenges. Really, objects and utilities are not components at all, so perhaps they should exist outsode of the Atomic Design categories.
Dan also, rightly IMHO, pointed out that our "atoms" section is confusing. It is a combination of plain HTML elements (some of which have or imply some kind of composition - e.g.
<table>
or<ul>
- and thus don't really feel like indivisible atoms) and Gravity-specific components like "nav link" or "pull quote". What we both felt might be a good solution is to divide them. "Atoms" could be reserved for the Gravity specific things only and plain HTML elements go somewhere else.Reviewing older issues, I see that @ThePeach suggested more or less the same a year ago in #106.
The text was updated successfully, but these errors were encountered: