Step Icons
Almost all available step components contain a place that shows an icon. The icon of a step depends on the componentType
and the type
fields.
const step = {
componentType: 'task',
type: 'someType',
// ...
};
To provide an icon to a step component you need to set the iconUrlProvider
property in the steps
configuration. The provider is a function that returns an icon URL. Your function can return null
if you don't want to provide an icon for a step.
const configuration = {
steps: {
iconUrlProvider: (componentType: string, type: string) => {
if (componentType === 'task') {
switch (type) {
case 'someType':
return `task-someType.svg`;
case 'anotherType':
return `task-anotherType.svg`;
}
}
}
return null;
},
},
};