lib/gcli/languages/command.js
function() {
    var input = this.terminal.getInputState();
    var start = input.cursor.start;
    var index = this.terminal.getChoiceIndex();

    return this.requisition.getStateData(start, index).then(function(data) {
      // Calculate the statusMarkup required to show wavy lines underneath the
      // input text (like that of an inline spell-checker) which used by the
      // template process for completer.html
      // i.e. s/space/&nbsp/g in the string (for HTML display) and status to an
      // appropriate class name (i.e. lower cased, prefixed with gcli-in-)
      data.statusMarkup.forEach(function(member) {
        member.string = member.string.replace(/ /g, '\u00a0'); // i.e. &nbsp;
        member.className = 'gcli-in-' + member.status.toString().toLowerCase();
      }, this);

      return data;
    });
  }
function() {
    var input = this.terminal.getInputState();
    var start = input.cursor.start;
    var index = this.terminal.getChoiceIndex();

    return this.requisition.getStateData(start, index).then(function(data) {
      // Calculate the statusMarkup required to show wavy lines underneath the
      // input text (like that of an inline spell-checker) which used by the
      // template process for completer.html
      // i.e. s/space/&nbsp/g in the string (for HTML display) and status to an
      // appropriate class name (i.e. lower cased, prefixed with gcli-in-)
      data.statusMarkup.forEach(function(member) {
        member.string = member.string.replace(/ /g, '\u00a0'); // i.e. &nbsp;
        member.className = 'gcli-in-' + member.status.toString().toLowerCase();
      }, this);

      return data;
    });
  }
function ( ) { var input = this . terminal . getInputState ( ) ; var start = input . cursor . start ; var index = this . terminal . getChoiceIndex ( ) ; return this . requisition . getStateData ( start , index ) . then ( function ( data ) { // Calculate the statusMarkup required to show wavy lines underneath the // input text (like that of an inline spell-checker) which used by the // template process for completer.html // i.e. s/space/&nbsp/g in the string (for HTML display) and status to an // appropriate class name (i.e. lower cased, prefixed with gcli-in-) data . statusMarkup . forEach ( function ( member ) { member . string = member . string . replace ( / / g , '\u00a0' ) ; // i.e. &nbsp; member . className = 'gcli-in-' + member . status . toString ( ) . toLowerCase ( ) ; } , this ) ; return data ; } ) ; }
Calculate the properties required by the template process for completer.html
Calculate the properties required by the template process for completer . html