Docs Components Primitives

ResizablePanel

React example follows below.
ts
const resizablePanelFixture = {
id: "resizable-panel",
label: "Preview",
body: "A padded pane body, with an optional mono eyebrow label above it.",
} satisfies {
id: string;
label: string;
body: string;
};
import { ResizablePanel } from "@grassroot/ui-react";
export default function ResizablePanelDemo() {
return (
<div>
<ResizablePanel label={resizablePanelFixture.label}>
{resizablePanelFixture.body}
</ResizablePanel>
</div>
);
}
ts
<script setup lang="ts">
const resizablePanelFixture = {
id: "resizable-panel",
label: "Preview",
body: "A padded pane body, with an optional mono eyebrow label above it.",
} satisfies {
id: string;
label: string;
body: string;
};
import { ResizablePanel } from "@grassroot/ui-vue";
</script>
<template>
<div>
<ResizablePanel :label="resizablePanelFixture.label">{{
resizablePanelFixture.body
}}</ResizablePanel>
</div>
</template>
ts
import { Component } from "@angular/core";
const resizablePanelFixture = {
id: "resizable-panel",
label: "Preview",
body: "A padded pane body, with an optional mono eyebrow label above it.",
} satisfies {
id: string;
label: string;
body: string;
};
import { GrassrootResizablePanel } from "@grassroot/ui-angular";
@Component({
selector: "app-resizable-panel-demo",
standalone: true,
imports: [GrassrootResizablePanel],
template: `
<div>
<grassroot-resizable-panel [label]="fixture.label">{{
fixture.body
}}</grassroot-resizable-panel>
</div>
`,
})
export class ResizablePanelDemoComponent {
protected readonly fixture = resizablePanelFixture;
}
export default ResizablePanelDemoComponent;
ts
<script lang="ts">
import { ResizablePanel } from "@grassroot/ui-svelte";
const resizablePanelFixture = {
id: "resizable-panel",
label: "Preview",
body: "A padded pane body, with an optional mono eyebrow label above it.",
} satisfies {
id: string;
label: string;
body: string;
};
</script>
<div>
<ResizablePanel label={resizablePanelFixture.label}>{resizablePanelFixture.body}</ResizablePanel>
</div>
ts
/** @jsxImportSource solid-js */
const resizablePanelFixture = {
id: "resizable-panel",
label: "Preview",
body: "A padded pane body, with an optional mono eyebrow label above it.",
} satisfies {
id: string;
label: string;
body: string;
};
import { ResizablePanel } from "@grassroot/ui-solid";
export default function ResizablePanelDemo() {
return (
<div>
<ResizablePanel label={resizablePanelFixture.label}>
{resizablePanelFixture.body}
</ResizablePanel>
</div>
);
}

Installation

API Reference

Import

import { ResizablePanel } from "@grassroot/ui-react";

Props

Prop
Type
Default
Requirement
Description
label
string | undefined
optional
Mono uppercase eyebrow shown above the content.
Prop
label
Type
string | undefined
Default
Requirement
optional
Description
Mono uppercase eyebrow shown above the content.

Content regions

  • children

Native attributes

Standard DOM and ARIA attributes not listed above spread onto the root element.

Import

import { ResizablePanel } from "@grassroot/ui-vue";

Props

Prop
Type
Default
Requirement
label
string | undefined
optional
Prop
label
Type
string | undefined
Default
Requirement
optional

Content regions

  • default

Import

import { Component } from "@angular/core";
import { GrassrootResizablePanel } from "@grassroot/ui-angular";

Props

Prop
Type
Default
Requirement
label
string
optional
Prop
label
Type
string
Default
Requirement
optional

Content regions

  • default

Import

import { ResizablePanel } from "@grassroot/ui-svelte";

Props

Prop
Type
Default
Requirement
label
string
optional
className
string
optional
Prop
label
Type
string
Default
Requirement
optional
Prop
className
Type
string
Default
Requirement
optional

Content regions

  • children

Import

import { ResizablePanel } from "@grassroot/ui-solid";

Props

Prop
Type
Default
Requirement
label
string
optional
className
string
optional
Prop
label
Type
string
Default
Requirement
optional
Prop
className
Type
string
Default
Requirement
optional

Content regions

  • children

Native attributes

Standard DOM and ARIA attributes not listed above spread onto the root element.