docstr: Draw information of field value distribution for text type to the
  report.
  
  Args:
      notes(str): Explain the block
      field_name (str): data field name
      field_distribution (:dict of :dict):
          -key: label_name
          -value: TextStats
code: def draw_text_field_distribution(
      self,
      notes: str,
      *,
      field_name: str,
      field_distribution: Dict[str, TextStats],
  ):
      """
      Draw information of field value distribution for text type to the
      report.
  
      Args:
          notes(str): Explain the block
          field_name (str): data field name
          field_distribution (:dict of :dict):
              -key: label_name
              -value: TextStats
      """
      from xai.graphs import graph_generator
  
      # -- Draw Content --
      self.html.article[-1].items.append(
          self.html.add_paragraph(text=notes)
      )
      for idx, (label_name, text_stats) in enumerate(
          field_distribution.items()
      ):
          tfidf = text_stats.tfidf
          pattern_stats = text_stats.pattern_stats
  
          title = "Distribution for %s" % label_name
          self.html.article[-1].items.append(
              self.html.add_header(text=title, heading="h5")
          )
          figure_path = "%s/%s_%s_field_distribution.png" % (
              self.figure_path,
              field_name,
              label_name,
          )
          figure_path = graph_generator.WordCloudGraph(
              figure_path=figure_path, data=tfidf, title=title
          ).draw()
          table_header = ["Placeholder", "Percentage(%)"]
          table_values = []
          for w, v in pattern_stats.items():
              table_values.append([w, "%.2f%%" % (v * 100)])
  
          if len(table_values) == 0:
              self.html.article[-1].items.append(
                  self.html.add_image(src=figure_path, alt=title)
              )
          else:
              self.html.article[-1].items.append(
                  self.html.add_table_image_group(
                      header=table_header,
                      data=table_values,
                      src=figure_path,
                      alt=title,
                  )
              )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import copy
  import os
  import tempfile
  import warnings
  import shutil
  from typing import Tuple, Dict, List
  import numpy
  from xai import MODE
  from xai.data.explorer import CategoricalStats, NumericalStats, TextStats, DatetimeStats
  from xai.formatter.contents import Header, Title, SectionTitle
  from xai.formatter.hypertext_markup.publisher import CustomHtml, Div
  from xai.formatter.report.section import OverviewSection, DetailSection
  from xai.formatter.writer import Writer
label_desc: Use image node_id 23 for calling the HtmlWriter obj's underlying member method code with example usage: obj.draw_text_field_distribution(notes) without return types