Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion js/content/html-doc.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,13 @@ var readAloudDoc = new function() {
}

function addMissingPunctuation(text) {
return text.replace(/(\w)(\s*?\r?\n)/g, "$1.$2");
text = removeReferences(text);
return text.replace(/(\w)(\s*?\r?\n)/g, "$1. $2");
}

// drop references[1] such as those.
function removeReferences(text){
return text.replace(/\[[0-9]+\]/g, '');
}

function findHeadingsFor(block, prevBlock) {
Expand Down