function listitem(text) {
  if (inList()) {

    // capture value in trailing "text" - unescape makes regexp work
    var m = unescapeQuotes(text).match(/^(.*)\s+"([^"]*)"\s*$/);

    var txt = m ? escapeQuotes(m[1]) : text;
    var val = m ? escapeQuotes(m[2]) : text;

    return renderOption(txt, val);
  }
  return fallback.listitem.call(this, text);
}
// capture listitems for select, checklist, radiolist
capture listitems for select, checklist, radiolist
capture listitems for select checklist radiolist
function listitem(text) {
  if (inList()) {
    var m = unescapeQuotes(text).match(/^(.*)\s+"([^"]*)"\s*$/);
    var txt = m ? escapeQuotes(m[1]) : text;
    var val = m ? escapeQuotes(m[2]) : text;
    return renderOption(txt, val);
  }
  return fallback.listitem.call(this, text);
}
function listitem ( text ) { if ( inList ( ) ) { var m = unescapeQuotes ( text ) . match ( / ^(.*)\s+"([^"]*)"\s*$ / ) ; var txt = m ? escapeQuotes ( m [ 1 ] ) : text ; var val = m ? escapeQuotes ( m [ 2 ] ) : text ; return renderOption ( txt , val ) ; } return fallback . listitem . call ( this , text ) ; }
capture listitems for select, checklist, radiolist
capture listitems for select checklist radiolist
// capture value in trailing "text" - unescape makes regexp work