Back to Grapesjs

Sector

docs/api/sector.md

0.22.161.6 KB
Original Source
<!-- Generated by documentation.js. Update this documentation by updating the source code. -->

Sector

Properties

  • id String Sector id, eg. typography
  • name String Sector name, eg. Typography
  • open Boolean? Indicates the open state.
  • properties Array<Object>? Indicate an array of Property definitions.

getId

Get sector id.

Returns String

getName

Get sector name.

Returns String

setName

Update sector name.

Parameters

  • value String New sector name

isOpen

Check if the sector is open

Returns Boolean

setOpen

Update Sector open state

Parameters

isVisible

Check if the sector is visible

Returns Boolean

getProperties

Get sector properties.

Parameters

  • opts Object Options (optional, default {})

    • opts.withValue Boolean Get only properties with value (optional, default false)
    • opts.withParentValue Boolean Get only properties with parent value (optional, default false)

Returns Array<Property>