rangy icon indicating copy to clipboard operation
rangy copied to clipboard

TextRange module's findText fix for text with non-breaking space.

Open rajanikanth05 opened this issue 9 years ago • 1 comments

Added fix to the TextRange module's findText method to search and match the text when the text in the document contains non-breaking space ( ). For example, if the document has html "test match with findText", innerText would return "test match with findText". Even though the space looks normal whitespace between "test match", this is decoded character value of  . When we search for "test match", textRange.findText wouldn't find match. According to the documentation, search should be performed on the visible text of the document but not on the decoded characters. Hence I made this change.

rajanikanth05 avatar Sep 07 '16 15:09 rajanikanth05

merged PR here: https://github.com/pburrows/rangy-updated/commit/854b8ad22663de453c414c89ed1eb936a8a3663b

pburrows avatar Jan 02 '19 14:01 pburrows