diff --git a/static/js/apiDialog.js b/static/js/apiDialog.js index 50d2755b..9d32f86c 100644 --- a/static/js/apiDialog.js +++ b/static/js/apiDialog.js @@ -132,14 +132,14 @@ pandora.ui.apiDialog = function() { source: string.replace( /\n(?=(takes \{|returns \{|note: |see: ))/g, '\n\n' ).replace( - /(takes|returns|note|see)(?=( \{|: ))/g, 'BOLD$1BOLD' + /(takes|returns|notes|see)(?=( \{|: ))/g, 'BOLD$1BOLD' ).replace( /`/g, 'BOLD' ) }) .css({backgroundColor: 'rgba(0, 0, 0, 0)'}), parts, parts_, - str = ',' + separator = ',' + ' '; ['Keyword', 'Method', 'Property'].forEach(function(type) { $doc.find('.Ox' + type).removeClass('Ox' + type); @@ -160,11 +160,12 @@ pandora.ui.apiDialog = function() { } parts = $doc.html().split('see'); if (parts.length == 2) { - parts[1] = parts[1].replace(/\n\s+?/, '').split(str).map( + parts[1] = parts[1].replace(/\n\s+?/, '').split(separator).map( function(action) { - return '' + action + ''; + return '' + + action + ''; } - ).join(str); + ).join(separator); $doc.html(parts.join('see')); } pandora.createLinks($doc);