Boxinterface
An object describing a workspace box
Properties (16)
| Property | Type | Default | Required | Description |
|---|---|---|---|---|
| allowDrop⚓︎ | boolean | x | x | Indicates if dropping windows inside this box is allowed |
| children⚓︎ | WorkspaceElement[] | x | A collection containing the immediate children of this box |
|
| frame⚓︎ | Frame | x | An object representing the frame containing this box |
|
| frameId⚓︎ | string | x | The unique string identifier of the frame containing this box |
|
| height⚓︎ | number | x | x | Returns the current height of the box, can be undefined if the API is used with old versions of Enterprise or Core |
| id⚓︎ | string | x | An unique string identifier of this box |
|
| isMaximized⚓︎ | boolean | x | x | Returns whether or not the box is maximized |
| maxHeight⚓︎ | number | x | x | Returns the maximum height of the box, calculated by the size constraints of the elements inside it |
| maxWidth⚓︎ | number | x | x | Returns the maximum width of the box, calculated by the size constraints of the elements inside it |
| minHeight⚓︎ | number | x | x | Returns the minimum height of the box, calculated by the size constraints of the elements inside it |
| minWidth⚓︎ | number | x | x | Returns the minimum width of the box, calculated by the size constraints of the elements inside it |
| parent⚓︎ | Workspace | WorkspaceBox | x | An object representing this box's parent |
|
| positionIndex⚓︎ | number | x | An number representing the positing of this box relative to it's siblings |
|
| width⚓︎ | number | x | x | Returns the current width of the box, can be undefined if the API is used with old versions of Enterprise or Core |
| workspace⚓︎ | Workspace | x | An object representing the workspace containing this box |
|
| workspaceId⚓︎ | string | x | The unique string identifier of the workspace containing this box |
8 Methods
addColumn()⚓︎
(definition?: BoxDefinition | BoxBuilder) => Promise<Column>
Adds a new column box to this box.
Parameters (1)
| Name | Type | Required | Description |
|---|---|---|---|
| definition⚓︎ | BoxDefinition | BoxBuilder | x | An object describing the type of the requested builder, alongside other settings. |
addGroup()⚓︎
(definition?: BoxDefinition | BoxBuilder) => Promise<Group>
Adds a new group box to this box.
Parameters (1)
| Name | Type | Required | Description |
|---|---|---|---|
| definition⚓︎ | BoxDefinition | BoxBuilder | x | An object describing the type of the requested builder, alongside other settings. |
addRow()⚓︎
(definition?: BoxDefinition | BoxBuilder) => Promise<Row>
Adds a new row box to this box.
Parameters (1)
| Name | Type | Required | Description |
|---|---|---|---|
| definition⚓︎ | BoxDefinition | BoxBuilder | x | An object describing the type of the requested builder, alongside other settings. |
addWindow()⚓︎
(definition: WorkspaceWindowDefinition) => Promise<WorkspaceWindow>
Opens a new window inside this box and loads it's content.
Parameters (1)
| Name | Type | Required | Description |
|---|---|---|---|
| definition⚓︎ | WorkspaceWindowDefinition | An object describing the requested window. |
removeChild()⚓︎
(predicate: (child: WorkspaceElement) => boolean) => Promise<void>
Removes the first immediate child of this box which satisfies the predicate.
Parameters (1)
| Name | Type | Required | Description |
|---|---|---|---|
| predicate⚓︎ | (child: WorkspaceElement) => boolean | A filtering function (predicate) called for immediate child of this box. |