Widget Core Function

The Table Widget is very versatile and acts as a kind of container for sub-widgets. It can include Input, Computed, Lookup, Hidden, or LinkRow column types. You can create tables by:
  • Computing each column
  • Asking the user for data entry or data selection
  • Setting labels and text outputs
The table widget is similar to Excel tables - you can have cells for data entry, formulas, dropdowns, etc. The key difference is that you create different modes of “column” creation rather than individual “cell” creation.

UI Experience

Interactive

Users can input data, expand rows, and interact with different column types

Informational

Display computed results and organized data in tabular format

Data Organization and Manipulation

  • Primary widget for creating tables
  • Each column can be set as a sub-widget
  • Sub-widgets have most but not all capabilities of standalone widgets
Watch the How-to Videos:

Cell Checks

To add cell checks, use JSON form in the cellCheck field:
[
  {
    "result": "",
    "condition": ""
  }
]

Example Cell Check

This example from the cfsSteelMemberAS4600-2018 template adds a cell check in the third cell where users can only input negative values for negative moment: Cell Check Example

Example Code

{
  "type": "sheetTemplateWidgets",
  "attributes": {
    "type": "table",
    "referenceId": "",
    "label": "",
    "symbol": "",
    "expand": false,
    "tableLength": "",
    "defaultValue": [],
    "visibleIf": "",
    "export": false,
    "dataColumns": [],
    "references": "",
    "description": "",
    "authorNotes": ""
  }
}

Parameters

type
string
required
Must be “table” - defines the widget type
label
string
required
The name of the widget
symbol
string (KaTeX)
required
Symbol for the widget displayed in KaTeX format
expand
boolean
default:"false"
required
Whether the table will be expandable by user input. At least one column must be "type": "input", and this may NOT be true if tableLength is defined
tableLength
string (equation)
An equation that must resolve to an integer, defining the number of rows to display. Most useful if your table has all "type": "computed" columns
defaultValue
matrix
Array of default values for initial display in the table
visibleIf
string (equation)
default:"true"
An equation that must result in true/false and can hide the widget if certain conditions are met. If visibleIf==false, any fields referencing this table will error
export
boolean
default:"false"
Whether to export the widget value for use elsewhere in the platform, such as in load linking
dataColumns
Table Column Object
required
Defines all columns in the table, which may consist of several types of columns
referenceId
string
required
Unique reference ID of the widget
description
string
Description of the table (not currently displayed, but will be)
references
string
required
Relevant code or standard reference for the table
authorNotes
string
Internal development notes; never displayed publicly
referenceImage
string (image dataURI)
Any image specifically relevant to the widget

Examples from Current Calculators

Reference IDsCalculator Link
computed (s_t-)CFS Steel Member AS4600-2018

Important Notes

The table widget resolves to a matrix of values that can be subset, mutated, or exported for various computations.

Best Practices

  • Use appropriate column types for your data needs
  • Consider using tableLength for computed-only tables
  • Implement cell checks to validate user input
  • Use expand functionality when users need to add variable numbers of entries
  • Always provide meaningful labels and references