Dear support,
With the react wrapper, is there a way to enable/disable features progammatically? With large schedule, we wish to provide the ability for our users to disable/enable features through our UI. More specially we wish to disable/enable timeRange and labels features.So far the only trick that we found is to add a boolean in the eventModel and then use it in the renderers of the label to return the label or "". But with this approach our scheduler is still much slower than with the labelsFeature disabled from the start. And we must update each event. Can you please advise if there is a better approach?
{
labelLayoutMode: "default",
left: {
renderer: ({ eventRecord, domConfig }) => {
if (eventRecord.displayAirports) {
return renderLeftLabel(eventRecord, domConfig, refScheduler?.current?.instance);
} else {
return "";
}
},
},
right: {
renderer: ({ eventRecord, domConfig }) => {
if (eventRecord.displayAirports) {
return renderRightLabel(eventRecord, domConfig, refScheduler?.current?.instance);
} else {
return "";
}
},
},
};