Skip to main content
customTrayButtons() Prebuilt Custom Returns all currently configured custom tray buttons. Each button is keyed by its button ID.

Return value

Returns a DailyCustomTrayButtons object — a map of button ID strings to DailyCustomTrayButton objects:
iconPath
string
URL of the button icon in light mode.
iconPathDarkMode
string
Optional. URL of the button icon in dark mode.
label
string
The button label shown in the tray.
tooltip
string
Tooltip text shown on hover.
visualState
string
Optional. The button’s current visual state: 'default', 'active', or 'disabled'.

Example

const buttons = call.customTrayButtons();

// Check a specific button's state
const raiseHand = buttons['raise-hand'];
if (raiseHand?.visualState === 'active') {
  console.log('Hand is raised');
}
// Example return value
{
  "customButtonOne": {
    "iconPath": "https://example.com/path/to/icon.svg",
    "iconPathDarkMode": "https://example.com/path/to/darkmode/icon.svg",
    "label": "My Custom Button",
    "tooltip": "My Custom Button Tooltip",
    "visualState": "default"
  },
  "customButtonTwo": {
    "iconPath": "https://example.com/path/to/icon.svg",
    "label": "Another Custom Button",
    "tooltip": "Another Custom Button Tooltip"
  }
}

See also