code: def _table_item_out(
      formatted_item,
      data_item,
      cols,
      col_info,
      detail,
      detail_cb,
      indent,
      max_col_width,
      err,
      file,
      style_kw,
  ):
      indent_padding = " " * indent
      click.echo(indent_padding, file=file, nl=False, err=err)
      line_pos = indent
      for i, col in enumerate(cols):
          val = formatted_item[col]
          last_col = i == len(cols) - 1
          val = (
              _pad_col_val(val, col, col_info) if not last_col else val
          )
          val_display_len = len(ansi_util.strip_ansi_format(val))
          line_pos = line_pos + val_display_len
          if max_col_width is not None:
              display_val = val[: -(line_pos - max_col_width)]
          else:
              display_val = val
          if max_col_width is not None and line_pos > max_col_width:
              click.echo(
                  style(display_val, **style_kw),
                  file=file,
                  nl=False,
                  err=err,
              )
              break
          click.echo(
              style(val, **style_kw), file=file, nl=False, err=err
          )
      click.echo(file=file, err=err)
      terminal_width = shutil.get_terminal_size()[0]
      if detail_cb:
          detail_cb(data_item)
      else:
          for key in detail or []:
              click.echo(indent_padding, file=file, nl=False, err=err)
              formatted = _format_detail_val(
                  formatted_item[key], indent, terminal_width
              )
              click.echo(
                  style(f"  {key}:{formatted}", **style_kw),
                  file=file,
                  err=err,
              )
  
imports: import functools
  import logging
  import os
  import sys
  import shutil
  import typing
  import click
  from guild import ansi_util
  from guild import config
label_desc: Use image node_id 18 for calling a global function with example usage: _table_item_out(formatted_item, data_item, cols, col_info, detail, detail_cb, indent, max_col_width, err, file, style_kw) without return types