{
  "name": "tree-view",
  "componentName": "TreeView",
  "displayName": "TreeView",
  "regions": [],
  "functions": [],
  "properties": [
    {
      "name": "ariaDescribedby",
      "type": "string",
      "optional": true,
      "description": "Sets the `aria-describedby` property on the tree view.",
      "formattedType": "string"
    },
    {
      "name": "ariaLabel",
      "type": "string",
      "optional": true,
      "description": "Provides an `aria-label` to the tree view that screen readers can read (for accessibility).\nDon't use `ariaLabel` and `ariaLabelledby` at the same time.",
      "formattedType": "string"
    },
    {
      "name": "ariaLabelledby",
      "type": "string",
      "optional": true,
      "description": "Sets the `aria-labelledby` property on the tree view.\nIf there's a visible label element that you can reference, use this instead of `ariaLabel`.\nDon't use `ariaLabel` and `ariaLabelledby` at the same time.",
      "formattedType": "string"
    },
    {
      "name": "connectorLines",
      "type": "string",
      "inlineType": {
        "name": "TreeViewProps.ConnectorLinesVariant",
        "type": "union",
        "values": [
          "none",
          "vertical"
        ]
      },
      "optional": true,
      "description": "Shows connector lines highlighting hierarchy between parent and child items.",
      "defaultValue": "'none'",
      "formattedType": "string"
    },
    {
      "name": "expandedItems",
      "type": "ReadonlyArray<string>",
      "optional": true,
      "description": "Provides the IDs of the expanded tree view items. It controls whether an item is expanded or collapsed.",
      "formattedType": "ReadonlyArray<string>"
    },
    {
      "name": "getItemChildren",
      "type": "(item: T, index: number) => ReadonlyArray<T>",
      "inlineType": {
        "name": "(item: T, index: number) => ReadonlyArray<T>",
        "type": "function",
        "returnType": "ReadonlyArray<T>",
        "parameters": [
          {
            "name": "item",
            "type": "T"
          },
          {
            "name": "index",
            "type": "number"
          }
        ]
      },
      "optional": false,
      "description": "Specifies the nested items that are displayed when a tree view item gets expanded.",
      "formattedType": " (\n  item: T,\n  index: number\n) => ReadonlyArray<T>"
    },
    {
      "name": "getItemId",
      "type": "(item: T, index: number) => string",
      "inlineType": {
        "name": "(item: T, index: number) => string",
        "type": "function",
        "returnType": "string",
        "parameters": [
          {
            "name": "item",
            "type": "T"
          },
          {
            "name": "index",
            "type": "number"
          }
        ]
      },
      "optional": false,
      "description": "Provides a unique identifier for each tree view item.",
      "formattedType": " (item: T, index: number) => string"
    },
    {
      "name": "i18nStrings",
      "type": "TreeViewProps.I18nStrings<T>",
      "inlineType": {
        "name": "TreeViewProps.I18nStrings<T>",
        "type": "object",
        "properties": [
          {
            "name": "collapseButtonLabel",
            "optional": true,
            "type": "((item: T) => string)",
            "inlineType": {
              "name": "(item: T) => string",
              "type": "function",
              "returnType": "string",
              "parameters": [
                {
                  "name": "item",
                  "type": "T"
                }
              ]
            }
          },
          {
            "name": "expandButtonLabel",
            "optional": true,
            "type": "((item: T) => string)",
            "inlineType": {
              "name": "(item: T) => string",
              "type": "function",
              "returnType": "string",
              "parameters": [
                {
                  "name": "item",
                  "type": "T"
                }
              ]
            }
          }
        ]
      },
      "optional": true,
      "description": "An object containing all the necessary localized strings required by the component.",
      "i18nTag": true,
      "formattedType": "TreeViewProps.I18nStrings<T> {\n  collapseButtonLabel?: (item: T) => string\n  expandButtonLabel?: (item: T) => string\n}"
    },
    {
      "name": "items",
      "type": "ReadonlyArray<T>",
      "optional": false,
      "description": "Specifies the top-level items to display in the tree view. Use `getItemChildren` to provide nested items.",
      "formattedType": "ReadonlyArray<T>"
    },
    {
      "name": "renderItem",
      "type": "(item: T, index: number) => TreeViewProps.TreeItem",
      "inlineType": {
        "name": "(item: T, index: number) => TreeViewProps.TreeItem",
        "type": "function",
        "returnType": "TreeViewProps.TreeItem",
        "parameters": [
          {
            "name": "item",
            "type": "T"
          },
          {
            "name": "index",
            "type": "number"
          }
        ]
      },
      "optional": false,
      "description": "Use this property to map your data to tree view items. This property must return an object with the following properties:\n* `content` (ReactNode) - The content of the item.\n* `icon` (ReactNode) - (Optional) The icon of the item.\n* `secondaryContent` (ReactNode) - (Optional) Secondary content of the item, such as a description of the item.\n* `actions` (ReactNode) - (Optional) Actions related to the item. Use [button](/components/button/?tabId=playground&example=inline-icon-button) with inline-icon or inline-link variants. For items with multiple actions, use [button dropdown](/components/button-dropdown/?tabId=playground&example=inline-icon-button-dropdown) with the inline-icon variant.\n* `announcementLabel` (string) - (Optional) An announcement label for the item, used for labeling the toggle button. By default, the `content` is used. Make sure to provide the `announcementLabel` if `content` is not a string.",
      "formattedType": " (\n  item: T,\n  index: number\n) => TreeViewProps.TreeItem"
    }
  ],
  "events": [
    {
      "name": "onItemToggle",
      "description": "Called when an item expands or collapses.",
      "cancelable": false,
      "detailType": "TreeViewProps.ItemToggleDetail<T>",
      "detailInlineType": {
        "name": "TreeViewProps.ItemToggleDetail<T>",
        "type": "object",
        "properties": [
          {
            "name": "expanded",
            "optional": false,
            "type": "boolean"
          },
          {
            "name": "id",
            "optional": false,
            "type": "string"
          },
          {
            "name": "item",
            "optional": false,
            "type": "NonNullable<T>",
            "inlineType": {
              "name": "NonNullable<T>",
              "type": "union",
              "values": [
                "T",
                "{}"
              ]
            }
          }
        ]
      },
      "formattedDetailType": "TreeViewProps.ItemToggleDetail<T> {\n  expanded: boolean\n  id: string\n  item: NonNullable<T>\n}"
    }
  ],
  "path": "/components/tree-view"
}