event.type detection