UNPKG

1.38 kBTypeScriptView Raw
1import { ISignal } from '@phosphor/signaling';
2import { Panel } from './panel';
3import { StackedLayout } from './stackedlayout';
4import { Widget } from './widget';
5/**
6 * A panel where visible widgets are stacked atop one another.
7 *
8 * #### Notes
9 * This class provides a convenience wrapper around a [[StackedLayout]].
10 */
11export declare class StackedPanel extends Panel {
12 /**
13 * Construct a new stacked panel.
14 *
15 * @param options - The options for initializing the panel.
16 */
17 constructor(options?: StackedPanel.IOptions);
18 /**
19 * A signal emitted when a widget is removed from a stacked panel.
20 */
21 readonly widgetRemoved: ISignal<this, Widget>;
22 /**
23 * A message handler invoked on a `'child-added'` message.
24 */
25 protected onChildAdded(msg: Widget.ChildMessage): void;
26 /**
27 * A message handler invoked on a `'child-removed'` message.
28 */
29 protected onChildRemoved(msg: Widget.ChildMessage): void;
30 private _widgetRemoved;
31}
32/**
33 * The namespace for the `StackedPanel` class statics.
34 */
35export declare namespace StackedPanel {
36 /**
37 * An options object for creating a stacked panel.
38 */
39 interface IOptions {
40 /**
41 * The stacked layout to use for the stacked panel.
42 *
43 * The default is a new `StackedLayout`.
44 */
45 layout?: StackedLayout;
46 }
47}