Skip to content

Layout API for all UI components #18

@adamkudrna

Description

@adamkudrna

As of now, adding an outer spacing to a component is done with utility classes like this:

<div className="mb-3">
  <Component />
</div>

This makes source code and DOM needlessly complex. It would be nice if we could do something like this:

<Component mb={3} />

This kind of “layout API” would be present in all UI components.


ℹ️ We don't want to make it possible to modify inner component styles so only outer CSS properties would be part in such API: margin (all directions), maybe flex child properties (align-self, justify-self).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    📋 Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions