index.js
function createTable (context) {
  var result = '"' + context.typeName + '" '
  result +=
    '[label=<<TABLE COLOR="' +
    context.color +
    '" BORDER="0" CELLBORDER="1" CELLSPACING="0">'
  result +=
    '<TR><TD PORT="__title"' +
    (this.theme.header.invert ? ' BGCOLOR="' + context.color + '"' : '') +
    '><FONT COLOR="' +
    (this.theme.header.invert ? 'WHITE' : context.color) +
    '">' +
    (_.isEmpty(context.stereotype) || context.stereotype === 'null'
      ? ''
      : '&laquo;' + context.stereotype + '&raquo;<BR/>') +
    '<B>' +
    context.typeName +
    '</B></FONT></TD></TR>'
  if (context.rows.length) {
    if (this.theme.field.hideSeperators) {
      result +=
        '<TR><TD><TABLE COLOR="' +
        context.color +
        '" BORDER="0" CELLBORDER="0" CELLSPACING="0">'
    }
    result += context.rows.map(row => {
      return (
        '<TR><TD ALIGN="' +
        this.theme.field.align +
        '" PORT="' +
        row.port +
        '"><FONT COLOR="' +
        context.color +
        '">' +
        row.text +
        '</FONT></TD></TR>'
      )
    })
    if (this.theme.field.hideSeperators) {
      result += '</TABLE></TD></TR>'
    }
  }
  result += '</TABLE>>];'
  return result
}
function createTable (context) {
  var result = '"' + context.typeName + '" '
  result +=
    '[label=<<TABLE COLOR="' +
    context.color +
    '" BORDER="0" CELLBORDER="1" CELLSPACING="0">'
  result +=
    '<TR><TD PORT="__title"' +
    (this.theme.header.invert ? ' BGCOLOR="' + context.color + '"' : '') +
    '><FONT COLOR="' +
    (this.theme.header.invert ? 'WHITE' : context.color) +
    '">' +
    (_.isEmpty(context.stereotype) || context.stereotype === 'null'
      ? ''
      : '&laquo;' + context.stereotype + '&raquo;<BR/>') +
    '<B>' +
    context.typeName +
    '</B></FONT></TD></TR>'
  if (context.rows.length) {
    if (this.theme.field.hideSeperators) {
      result +=
        '<TR><TD><TABLE COLOR="' +
        context.color +
        '" BORDER="0" CELLBORDER="0" CELLSPACING="0">'
    }
    result += context.rows.map(row => {
      return (
        '<TR><TD ALIGN="' +
        this.theme.field.align +
        '" PORT="' +
        row.port +
        '"><FONT COLOR="' +
        context.color +
        '">' +
        row.text +
        '</FONT></TD></TR>'
      )
    })
    if (this.theme.field.hideSeperators) {
      result += '</TABLE></TD></TR>'
    }
  }
  result += '</TABLE>>];'
  return result
}
function createTable ( context ) { var result = '"' + context . typeName + '" ' result += '[label=<<TABLE COLOR="' + context . color + '" BORDER="0" CELLBORDER="1" CELLSPACING="0">' result += '<TR><TD PORT="__title"' + ( this . theme . header . invert ? ' BGCOLOR="' + context . color + '"' : '' ) + '><FONT COLOR="' + ( this . theme . header . invert ? 'WHITE' : context . color ) + '">' + ( _ . isEmpty ( context . stereotype ) || context . stereotype === 'null' ? '' : '&laquo;' + context . stereotype + '&raquo;<BR/>' ) + '<B>' + context . typeName + '</B></FONT></TD></TR>' if ( context . rows . length ) { if ( this . theme . field . hideSeperators ) { result += '<TR><TD><TABLE COLOR="' + context . color + '" BORDER="0" CELLBORDER="0" CELLSPACING="0">' } result += context . rows . map ( row => { return ( '<TR><TD ALIGN="' + this . theme . field . align + '" PORT="' + row . port + '"><FONT COLOR="' + context . color + '">' + row . text + '</FONT></TD></TR>' ) } ) if ( this . theme . field . hideSeperators ) { result += '</TABLE></TD></TR>' } } result += '</TABLE>>];' return result }
For the given context, creates a table for the class with the typeName as the header, and rows as the fields
For the given context creates a table for the class with the typeName as the header and rows as the fields