HOC SiteDocumentation

Accordion list

Decoration and visibility use Decoration & visibility (BlockShell).

Stacked sections. Each section has a title and a content slot. Click a title to select that section (move, duplicate, or delete it from the toolbar; the chevron opens and closes it). Double-click a title to edit the text. Size, weight, italic, align and color are stored on that section. Several sections can be open at once unless singleOpen is true. New sections added on the canvas start with a title like #1. Appearance props style the shared title chrome and open panel padding.

Fields

sections

Section list. title is simple text (icon and variable chips). Optional textAlign, italic, fontSize, fontWeight, and authored textColor style that section. content is a slot.

sections: [{ title: [{ if: "*", is: "#1" }], textAlign: [{ if: "*", is: "left" }], fontSize: [{ if: "*", is: 16 }], fontWeight: [{ if: "*", is: 400 }], content: [] }]

singleOpen

When true, opening one section closes the others. Default false.

singleOpen: [{ if: "*", is: false }]

appearance

dividerWidth

Section bottom divider width in px. CSS default 2 when unset; set 0 to remove. Independent of shell.border.

appearance: {
  dividerWidth: [{ if: "*", is: 0 }]
}

titlePaddingTop

Title trigger top padding in px. CSS default 16 when unset.

appearance: {
  titlePaddingTop: [{ if: "*", is: 16 }]
}

titlePaddingRight

Title trigger right padding in px. CSS default 20 when unset.

appearance: {
  titlePaddingRight: [{ if: "*", is: 20 }]
}

titlePaddingBottom

Title trigger bottom padding in px. CSS default 16 when unset.

appearance: {
  titlePaddingBottom: [{ if: "*", is: 16 }]
}

titlePaddingLeft

Title trigger left padding in px. CSS default 20 when unset.

appearance: {
  titlePaddingLeft: [{ if: "*", is: 20 }]
}

titleRadius

Title trigger border-radius in px. CSS default 0 when unset.

appearance: {
  titleRadius: [{ if: "*", is: 0 }]
}

titleBackgroundColor

Authored title trigger background. Hover uses { on: "hover" } (or sibling hover) like Button textColor; unset keeps transparent.

appearance: {
  titleBackgroundColor: [{ if: "*", is: "#f5f5f5" }, { if: [{ on: "hover" }], is: "#eeeeee" }]
}

titleLineHeight

Title line-height in px. Unset keeps the browser/default line-height.

appearance: {
  titleLineHeight: [{ if: "*", is: 24 }]
}

contentPaddingX

Open panel horizontal padding in px. CSS default 20 when unset.

appearance: {
  contentPaddingX: [{ if: "*", is: 20 }]
}

contentPaddingTop

Open panel top padding in px. CSS default 0 when open; closed stays 0.

appearance: {
  contentPaddingTop: [{ if: "*", is: 0 }]
}

contentPaddingBottom

Open panel bottom padding in px. CSS default 20 when open; closed stays 0.

appearance: {
  contentPaddingBottom: [{ if: "*", is: 20 }]
}

contentGap

Gap between panelInner children in px. CSS default 0 when unset.

appearance: {
  contentGap: [{ if: "*", is: 0 }]
}

Default props

{
  "shell": {
    "visibility": [
      {
        "if": "*",
        "is": true
      }
    ],
    "anchor": {
      "anchorId": [
        {
          "if": "*",
          "is": ""
        }
      ],
      "anchorKey": [
        {
          "if": "*",
          "is": ""
        }
      ]
    },
    "pointerEvents": [
      {
        "if": "*",
        "is": "auto"
      }
    ]
  }
}