Hey, weāve built a plugin that if a certain attribute of a field has been modified we show a prompt and then based on that promptās decision we send a message into slack. Everything is fine except we get a little toast in the bottom right hand saying that itās taking too long. While this is fine for engineers - our editors will likely get spooked by this, and itās kind of untrue - as the editor is processing the prompt.

The specific hook is onBeforeItemUpsert and here is an example of my code (some nested code removed for brevity and sensitive info).
connect({
renderConfigScreen(ctx) {
return render(<ConfigScreen ctx={ctx} />)
},
// creation and update of records
onBeforeItemUpsert(item, ctx) {
return masterMessager(item, ctx, 'created or saved')
},
// delete of records
onBeforeItemsDestroy(items, ctx) {
return masterMessageLooper(items, ctx, 'Deleted')
},
// Publishing records
onBeforeItemsPublish(items, ctx) {
return masterMessageLooper(items, ctx, 'Published')
},
// Unpublish Publishing records
onBeforeItemsUnpublish(items, ctx) {
return masterMessageLooper(items, ctx, 'Unpublished')
},
})
export async function masterMessager(
item: ItemUpdateSchema | ItemCreateSchema,
ctx: OnBootPropertiesAndMethods,
actionTaken: string,
) {
// some code removed
const confirmation = await ctx.openConfirm({
title: `some title`,
content: `some message`,
cancel: { label: 'Cancel', value: false },
choices: [{ label: 'Yes, Save', value: true }],
})
if (!confirmation) {
return false
}
// some other code removed...
return true
}
If any more info is required please let me know. Thanks!

