Newer
Older
percord / src / util / util / InvisibleCharacters.ts
/*
	Spacebar: A FOSS re-implementation and extension of the Discord.com backend.
	Copyright (C) 2023 Spacebar and Spacebar Contributors
	
	This program is free software: you can redistribute it and/or modify
	it under the terms of the GNU Affero General Public License as published
	by the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.
	
	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU Affero General Public License for more details.
	
	You should have received a copy of the GNU Affero General Public License
	along with this program.  If not, see <https://www.gnu.org/licenses/>.
*/

// List from https://invisible-characters.com/
export const InvisibleCharacters = [
    "\u{9}", //Tab
    "\u{c}", //Form feed
    //'\u{20}',			//Space	//categories can have spaces in them
    "\u{ad}", //Soft hyphen
    //"\u{34f}", //Combining grapheme joiner
    "\u{61c}", //Arabic letter mark
    "\u{115f}", //Hangul choseong filler
    "\u{1160}", //Hangul jungseong filler
    "\u{17b4}", //Khmer vowel inherent AQ
    "\u{17b5}", //Khmer vowel inherent AA
    "\u{180e}", //Mongolian vowel separator
    "\u{2000}", //En quad
    "\u{2001}", //Em quad
    "\u{2002}", //En space
    "\u{2003}", //Em space
    "\u{2004}", //Three-per-em space
    "\u{2005}", //Four-per-em space
    "\u{2006}", //Six-per-em space
    "\u{2007}", //Figure space
    "\u{2008}", //Punctuation space
    "\u{2009}", //Thin space
    "\u{200a}", //Hair space
    "\u{200b}", //Zero width space
    "\u{200c}", //Zero width non-joiner
    //"\u{200d}", //Zero width joiner
    "\u{200e}", //Left-to-right mark
    "\u{200f}", //Right-to-left mark
    "\u{202f}", //Narrow no-break space
    "\u{205f}", //Medium mathematical space
    //"\u{2060}", //Word joiner -- WJ is required in some languages that don't use spaces to split words
    "\u{2061}", //Function application
    "\u{2062}", //Invisible times
    "\u{2063}", //Invisible separator
    "\u{2064}", //Invisible plus
    "\u{206a}", //Inhibit symmetric swapping
    "\u{206b}", //Activate symmetric swapping
    "\u{206c}", //Inhibit arabic form shaping
    "\u{206d}", //Activate arabic form shaping
    "\u{206e}", //National digit shapes
    "\u{206f}", //Nominal digit shapes
    "\u{3000}", //Ideographic space
    "\u{2800}", //Braille pattern blank
    "\u{3164}", //Hangul filler
    "\u{feff}", //Zero width no-break space
    "\u{ffa0}", //Haldwidth hangul filler
    "\u{1d159}", //Musical symbol null notehead
    "\u{1d173}", //Musical symbol begin beam
    "\u{1d174}", //Musical symbol end beam
    "\u{1d175}", //Musical symbol begin tie
    "\u{1d176}", //Musical symbol end tie
    "\u{1d177}", //Musical symbol begin slur
    "\u{1d178}", //Musical symbol end slur
    "\u{1d179}", //Musical symbol begin phrase
    "\u{1d17a}", //Musical symbol end phrase
];