Interface Template<ItemType, Content, LinkContent>

interface Template<ItemType, Content = unknown, LinkContent = unknown> {
    conditions: TemplateCondition<ItemType>[];
    content: Content;
    fields?: string[];
    linkContent?: LinkContent;
    priority?: number;
}

Type Parameters

  • ItemType
  • Content = unknown
  • LinkContent = unknown

Properties

conditions: TemplateCondition<ItemType>[]

A list of conditions that must be fulfilled for this template to be selected.

content: Content

The stored content of the template.

fields?: string[]

A list of index fields that are necessary to render the template.

linkContent?: LinkContent

The link used when an item generated by this template is clicked in a card layout.

priority?: number

A value which the manager will use to determine which template to select when an item satisfies the conditions of more than one template. Templates with higher priority values will be selected over others. The minimum and default value is 0.