code: def _create_heading_proto(
      tag: HeadingProtoTag,
      body: SupportsStr,
      anchor: Anchor = None,
      help: Optional[str] = None,
      divider: Divider = False,
  ) -> HeadingProto:
      proto = HeadingProto()
      proto.tag = tag.value
      proto.body = clean_text(body)
      if divider:
          proto.divider = HeadingMixin._handle_divider_color(divider)
      if anchor is not None:
          if anchor is False:
              proto.hide_anchor = True
          elif isinstance(anchor, str):
              proto.anchor = anchor
          elif anchor is True:  # type: ignore
              raise StreamlitAPIException(
                  "Anchor parameter has invalid value: %s. "
                  "Supported values: None, any string or False" % anchor
              )
          else:
              raise StreamlitAPIException(
                  "Anchor parameter has invalid type: %s. "
                  "Supported values: None, any string or False"
                  % type(anchor).__name__
              )
  
      if help:
          proto.help = help
      return proto
  
file_path: streamlit/lib/streamlit/elements/heading.py
imports: from enum import Enum
  from typing import TYPE_CHECKING, Optional, Union, cast
  from typing_extensions import Literal
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.Heading_pb2 import Heading
  from streamlit.runtime.metrics_util import gather_metrics
  from streamlit.string_util import clean_text
  from streamlit.type_util import SupportsStr
label_desc: Use image node_id 6 for calling the HeadingMixin obj's underlying member method code with example usage: obj._create_heading_proto(tag, body, anchor, help, divider) and returns: proto