Skip to content

Allow custom widths for PageLayout.Pane #3419

@iansan5653

Description

@iansan5653

PageLayout.Pane only allows three values for the width prop: "small" | "medium" | "large". The real default values of these keywords can be found here:

const defaultPaneWidth = {small: 256, medium: 296, large: 320}

These are fine when the pane is used for a vertical menu like it usually is, but there are other use-cases as well. For example, you might want to have a details/preview pane that takes up a third or more of the screen width by default. This should ideally be much wider than 320px. In this case, it would be very useful to be able to set a custom width.

For a resizable pane, we also need to be able to set minimum and maximum widths:

width={{
  min: '400px',
  default: '550px',
  max: '700px'
}}

Metadata

Metadata

Assignees

Labels

component: SplitPageLayoutIssues related to the PageLayout and SplitPageLayout componentsenhancementNew feature or requestreact

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions