code: def _add_mid_measure_op(op, layer_str, config):
      """Updates ``layer_str`` with ``op`` operation when ``op`` is a
      ``qml.measurements.MidMeasureMP``."""
      layer_str = _add_mid_measure_grouping_symbols(
          op, layer_str, config
      )
      label = op.label(
          decimals=config.decimals, cache=config.cache
      ).replace("\n", "")
  
      for w in op.wires:
          layer_str[config.wire_map[w]] += label
  
      return layer_str
  
file_path: pennylane/pennylane/drawer/tape_text.py
imports: from dataclasses import dataclass
  from typing import Optional
  import pennylane
  from pennylane.measurements import Expectation, Probability, Sample, Variance, State, Counts, MidMeasureMP
  from .drawable_layers import drawable_layers
  from .utils import convert_wire_order, unwrap_controls, cwire_connections, default_bit_map
label_desc: Use image node_id 5 for calling a global function with example usage: _add_mid_measure_op(op, layer_str, config) and returns: layer_str