Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
[@express-document-sdk](../overview.md) / AddOnData

# Class: AddOnData

AddOnData class provides APIs to read, write, remove private metadata to a Node.
This metadata is accessible only to the add-on that has set it.



- `ProxyLiveObject`


## Accessors

### remainingQuota
Expand All @@ -21,6 +25,7 @@ The object contains the following properties:
- sizeInBytes: The remaining quota size in bytes (maximum 3KB).
- numKeys: The remaining quota for the number of keys (maximum 20 keys).


##### numKeys

• **numKeys**: `number`
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
[@express-document-sdk](../overview.md) / ArtboardList

# Class: ArtboardList

ArtboardList represents an ordered list of ArtboardNodes arranged in a timeline sequence, where they are called "scenes."
All items in the list are children of a single [PageNode](PageNode.md).
ArtboardList represents an ordered list of ArtboardNodes, which are the children of one [PageNode](PageNode.md). If multiple
artboards are present, each represents a keyframe "scene" in the page's animation timeline.

ArtboardList also provides APIs for adding/removing artboards from the page. ArtboardList is never empty: it is illegal to
remove the last remaining artboard from the list.

## Extends

- [`RestrictedItemList`](RestrictedItemList.md)<[`ArtboardNode`](ArtboardNode.md)\>

- [`RestrictedItemList`](RestrictedItemList.md)<[`ArtboardNode`](ArtboardNode.md)\>


## Accessors

Expand Down
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
[@express-document-sdk](../overview.md) / ArtboardNode

# Class: ArtboardNode

An ArtboardNode represents an artboard object in the scenegraph. All user visual content must be contained on an artboard.
Artboards are always contained on a [PageNode](PageNode.md); when a page contains multiple artboards, the artboards represent
"scenes" in a linear timeline sequence.
An ArtboardNode represents the topmost container of visual content within a [PageNode](PageNode.md). When a page contains
multiple artboards, each represents a keyframe "scene" in the page's animation timeline.

To create a new artboard, see [ArtboardList.addArtboard](ArtboardList.md#addartboard).

Please note that creating and deleting an artboard in a single frame will crash the editor.

## Extends

- [`VisualNode`](VisualNode.md)
- [`VisualNode`](VisualNode.md)


## Implements

- `Readonly`<[`IRectangularNode`](../interfaces/IRectangularNode.md)\>
- [`ContainerNode`](../interfaces/ContainerNode.md)

- `Readonly`<[`IRectangularNode`](../interfaces/IRectangularNode.md)\>
- [`ContainerNode`](../interfaces/ContainerNode.md)


## Accessors

Expand All @@ -42,7 +41,7 @@ GroupNode also provide a mutable [ContainerNode.children](../interfaces/Containe
hold children in various discrete "slots"; this `allChildren` list includes *all* such children and reflects their
overall display z-order.

The children of an Artboard are always other Node classes (never the more minimal BaseNode).
The children of an Artboard are all subclasses of Node (not just the more minimal BaseNode or VisualNode).

#### Returns

Expand Down Expand Up @@ -83,7 +82,9 @@ Position of the node's centerpoint in its own local coordinate space, i.e. the c

• `get` **children**(): [`ItemList`](ItemList.md)<[`Node`](Node.md)\>

The node's children. Use the methods on this ItemList object to get, add, and remove children.
The artboards's regular children (does not include any "background layer" content if present; use [allChildren](ArtboardNode.md#allchildren)
for a read-only view that includes background content). Use the methods on this `children` ItemList object to get,
add, and remove regular children.

#### Returns

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[@express-document-sdk](../overview.md) / AvailableFont

# Class: AvailableFont

Font the current user has access or licensing permissions to create / edit content with.

## Extends

- [`BaseFont`](BaseFont.md)

- [`BaseFont`](BaseFont.md)


## Accessors

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
[@express-document-sdk](../overview.md) / BaseFont

# Class: `abstract` BaseFont

Represents a font that is able to be rendered within this document. However, the user may not have edit permissions for
all such fonts.



- `ProxyLiveObject`


## Extended by

- [`AvailableFont`](AvailableFont.md)
- [`UnavailableFont`](UnavailableFont.md)

- [`AvailableFont`](AvailableFont.md)
- [`UnavailableFont`](UnavailableFont.md)


## Accessors

Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,23 @@
[@express-document-sdk](../overview.md) / BaseNode

# Class: BaseNode

A "node" represents an object in the scenegraph, the document's visual content tree. This base class includes only the
most fundamental nonvisual properties that even nodes near the top of the document structure share (such as PageNode).
The more tangible visual content typically extends the richer Node class which extends BaseNode with additional
properties.



- `ProxyLiveObject`


## Extended by

- [`ExpressRootNode`](ExpressRootNode.md)
- [`PageNode`](PageNode.md)
- [`VisualNode`](VisualNode.md)

- [`ExpressRootNode`](ExpressRootNode.md)
- [`PageNode`](PageNode.md)
- [`VisualNode`](VisualNode.md)


## Accessors

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
[@express-document-sdk](../overview.md) / BitmapImage

# Class: BitmapImage

Represents a bitmap image resource. Use [Editor.loadBitmapImage](Editor.md#loadbitmapimage) to create a BitmapImage, and then [Editor.createImageContainer](Editor.md#createimagecontainer)
to display it in the document by creating a MediaContainerNode structure.



- `ProxyLiveObject`


## Accessors

### height
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
[@express-document-sdk](../overview.md) / ColorUtils

# Class: ColorUtils

Utility methods for working with color values.



- `ProxyLiveObject`


## Methods

### fromHex()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[@express-document-sdk](../overview.md) / ComplexShapeNode

# Class: ComplexShapeNode

A ComplexShapeNode is a complex prepackaged shape that appears as a leaf node in the UI, even if it is composed
of multiple separate paths.

## Extends

- [`FillableNode`](FillableNode.md)

- [`FillableNode`](FillableNode.md)


## Accessors

Expand Down Expand Up @@ -338,10 +338,6 @@ relative to one another (the target node need not be an ancestor of this node, n

• **cloneInPlace**(): [`ComplexShapeNode`](ComplexShapeNode.md)

<InlineAlert slots="text" variant="warning"/>

**IMPORTANT:** This is currently ***experimental only*** and should not be used in any add-ons you will be distributing until it has been declared stable. To use it, you will first need to set the `experimentalApis` flag to `true` in the [`requirements`](../../../manifest/index.md#requirements) section of the `manifest.json`.

Creates a copy of this node and its entire subtree of descendants.

The node must be attached to a page as the copy will be added as a sibling.
Expand Down Expand Up @@ -403,6 +399,8 @@ removal. No-op if node is already an orphan.

### rescaleProportionalToHeight()

`Experimental`

• **rescaleProportionalToHeight**(`height`): `void`

<InlineAlert slots="text" variant="warning"/>
Expand All @@ -428,6 +426,8 @@ preserve its existing aspect ratio. See [rescaleProportionalToWidth](Node.md#res

### rescaleProportionalToWidth()

`Experimental`

• **rescaleProportionalToWidth**(`width`): `void`

<InlineAlert slots="text" variant="warning"/>
Expand Down Expand Up @@ -460,6 +460,8 @@ a separate, persistent scale factor multiplier).

### resizeToCover()

`Experimental`

• **resizeToCover**(`width`, `height`): `void`

<InlineAlert slots="text" variant="warning"/>
Expand Down Expand Up @@ -493,6 +495,8 @@ resizeToFitWithin

### resizeToFitWithin()

`Experimental`

• **resizeToFitWithin**(`width`, `height`): `void`

<InlineAlert slots="text" variant="warning"/>
Expand Down Expand Up @@ -557,8 +561,7 @@ Point in this node's local coordinate space to align with `parentPoint`
#### Example

Center a rectangle within its parent artboard:

```js
```
rectangle.setPositionInParent(
{ x: artboard.width / 2, y: artboard.height / 2 },
{ x: rectangle.width / 2, y: rectangle.height / 2 }
Expand Down Expand Up @@ -597,7 +600,6 @@ Point to rotate around, in node's local coordinates.
#### Example

Rotate the rectangle 45 degrees clockwise around its centerpoint:

```js
```
rectangle.setRotationInParent(45, rectangle.centerPointLocal);
```
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
[@express-document-sdk](../overview.md) / Context

# Class: Context

Contains the user's current selection state, indicating the content they are focused on.



- `ProxyLiveObject`


## Accessors

### currentPage
Expand All @@ -15,6 +19,7 @@ Contains the user's current selection state, indicating the content they are foc
[`PageNode`](PageNode.md)

The currently viewed page.
To change the current page, call [Viewport.bringIntoView](Viewport.md#bringintoview) with an artboard or other content on that page.

---

Expand Down Expand Up @@ -60,6 +65,7 @@ Only node(s) that meet the following criteria can be selected:
- A node cannot be selected if its ancestor is also selected (descendants are filtered out).
- Locked nodes are filtered out (but will still be included in selectionIncludingNonEditable).


#### Parameters

• **nodes**: `undefined` \| [`Node`](Node.md) \| readonly [`Node`](Node.md)[]
Expand All @@ -68,7 +74,8 @@ Only node(s) that meet the following criteria can be selected:

readonly [`Node`](Node.md)[]

the current selection. Nodes that are locked or otherwise non-editable are never included in the selection.
the current selection. Nodes that are locked or otherwise non-editable are never included in the regular
selection (see [selectionIncludingNonEditable](Context.md#selectionincludingnoneditable) to get any locked nodes the user may have clicked).

---

Expand All @@ -80,7 +87,7 @@ the current selection. Nodes that are locked or otherwise non-editable are never

readonly [`Node`](Node.md)[]

the current selection _and_ any locked nodes the user has attempted to select at the same time. This can
the current selection *and* any locked nodes the user has attempted to select at the same time. This can
happen for example if the user clicks on a locked node or if the user drags a selection marquee that overlaps
locked nodes in addition to regular unlocked nodes.

Expand Down
Loading