operational-ui icon indicating copy to clipboard operation
operational-ui copied to clipboard

Add breadcrumb to Page

Open TejasQ opened this issue 5 years ago • 2 comments

So I'm wondering if it makes sense to add Breadcrumbs inside page such that when Page is given a breadcrumb prop, it uses Breadcrumbs and Breadcrumb internally like so:

<Page
  breadcrumb={
    [
      { label: "Start", to: "/" },
      { label: "Here", to: "/here" }
    ]
  }
/>

The drawback I see is that it couples Breadcrumbs and Page and makes Page a bit more complex and fundamentally disrupts a nice composition model in userland.

That said, something like this:

image

isn't really attainable in userland without adding this prop to Page and significant UI/CSS hackery. Instead, one would end up with something like this out of the box:

image

So the question finally is: should we add this prop or not?

TejasQ avatar Jul 17 '19 13:07 TejasQ

image

TejasQ avatar Jul 17 '19 13:07 TejasQ

Great. Let's do it.

TejasQ avatar Jul 17 '19 13:07 TejasQ