def _add_entry(self, title: str | None, text: str, loc: str) -> None:
        """A simple wrapper to add an entry, dropping bad characters."""
        text = text.replace('\u00a0', ' ')
        text = re.sub(r'[ \t\n\r\f\v]+', ' ', text.strip())

        self._entries.append({'title': title, 'text': text, 'location': loc})
A simple wrapper to add an entry, dropping bad characters.
mkdocs/contrib/search/search_index.py