HistoryEntryComponent
HistoryEntryComponent
This interface should be implemented by components intended to display a history entry in the Order or Customer history timeline. If the component needs access to the Order or Customer object itself, you should implement OrderHistoryEntryComponent or CustomerHistoryEntryComponent respectively.
Signature
interface HistoryEntryComponent {
entry: TimelineHistoryEntry;
getDisplayType: (entry: TimelineHistoryEntry) => TimelineDisplayType;
isFeatured: (entry: TimelineHistoryEntry) => boolean;
getName?: (entry: TimelineHistoryEntry) => string | undefined;
getIconShape?: (entry: TimelineHistoryEntry) => string | string[] | undefined;
}
entry
property
TimelineHistoryEntryThe HistoryEntry data.
getDisplayType
property
(entry: TimelineHistoryEntry) => TimelineDisplayTypeDefines whether this entry is highlighted with a "success", "error" etc. color.
isFeatured
property
(entry: TimelineHistoryEntry) => booleanFeatured entries are always expanded. Non-featured entries start of collapsed and can be clicked to expand.
getName
property
(entry: TimelineHistoryEntry) => string | undefinedReturns the name of the person who did this action. For example, it could be the Customer's name or "Administrator".
getIconShape
property
(entry: TimelineHistoryEntry) => string | string[] | undefinedOptional Clarity icon shape to display with the entry. Examples: 'note', ['success-standard', 'is-solid']