Configuration Tango Table Widget

The widget’s configuration schema is defined in src/index.ts. Options and defaults:

  • Title:

    • Key: title

    • Type: string

    • Purpose: Optional heading displayed above the table.

    • Default: "" (hidden)

  • Font size:

    • Key: fontSize

    • Type: string

    • Purpose: Shared table font size applied to headers and body cells.

    • Default: "0.8em"

  • Tango attributes:

    • Key: attributes

    • Type: Array<{ endpoint: TANGO_DB, attribute: string }>

    • Purpose: List of fully-qualified Tango attribute names to display in the table, each with an optional Tango DB selector.

    • Default: [{"endpoint":"","attribute":"low-mccs/tile/s8-1-tpm01/state"},{"endpoint":"","attribute":"low-mccs/spsstation/s8-1/state"},{"endpoint":"","attribute":"low-mccs/smartbox/s8-1-sb01/state"}]

  • Use live data (subscribe):

    • Key: useLiveData

    • Type: boolean

    • Purpose: When true, use GraphQL subscriptions for live updates. When false, poll via query.

    • Default: true

  • Use enum labels:

    • Key: useEnumLabels

    • Type: boolean

    • Purpose: When true, render integer values as their corresponding enum labels if available.

    • Default: true

  • Show value units:

    • Key: showUnits

    • Type: boolean

    • Purpose: When true, display the engineering units associated with each attribute.

    • Default: true

  • Time column format:

    • Key: timeColumnFormat

    • Type: string (dropdown)

    • Purpose: Select a common display format for time values.

    • Allowed values: "{24h}", "{time}", "{timefull}", "{iso}"

    • Default: "{24h}"

  • Hidden table columns:

    • Key: hiddenColumns

    • Type: string[]

    • Purpose: Hide selected columns from the table layout.

    • Allowed values: "time", "device", "attribute", "value", "units"

    • Default: []

  • Column widths:

    • Key: columnWidths

    • Type: Record<string, number>

    • Purpose: Persisted per-column widths in pixels, managed automatically when resizing headers.

    • Default: {}

Behavior notes:

  • Column auto-fit is driven by the host layout width exposed through the SDK, so the table uses the available space before overflowing horizontally.

  • Auto-fit uses the available layout width without enforcing visible label minimums.

  • Column widths, column order, and sort state are persisted through the shared widget config persistence hook.