TinyBase logoTinyBase

LinkedRowsProps

LinkedRowsProps props are used for components that refer to a single Relationship in a Relationships object, and where you want to render a linked list of Rows starting from a first Row, such as the LinkedRowsView component.

{
  relationshipId: Id;
  firstRowId: Id;
  relationships?: RelationshipsOrRelationshipsId;
  rowComponent?: ComponentType<RowProps>;
  getRowComponentProps?: (rowId: Id) => ExtraProps;
  separator?: ReactElement | string;
  debugIds?: boolean;
}
TypeDescription
relationshipIdId

The Id of the Relationship in the Relationships object.

firstRowIdId

The Id of the first Row in the linked list Relationship.

relationships?RelationshipsOrRelationshipsId

The Relationships object to be accessed: omit for the default context Relationships object, provide an Id for a named context Relationships object, or provide an explicit reference.

rowComponent?ComponentType<RowProps>

A component for rendering each (remote, local, or linked) Row in the Relationship.

getRowComponentProps?(rowId: Id) => ExtraProps

A function for generating extra props for each Row component based on its Id.

separator?ReactElement | string

A component or string to separate each Row component.

debugIds?boolean

Whether the component should also render the Id of the Row in the Relationship, and its descendent objects, to assist with debugging.