It would be great if you could utilize the @layout_mode function in a context procedure template.
I have two deletion tasks assigned to two different roles, and I tried to hide the tasks if the layout mode is set to 'add.' However, it appears that this function is not available in a context procedure.
Great idea!