add formatter

This commit is contained in:
Hare Sudhan 2024-02-24 22:59:51 -05:00
parent c4e7c41a6e
commit ce30989adc
693 changed files with 51226 additions and 26671 deletions

View file

@ -23,10 +23,9 @@ export const ALPHABET_OPTIONS = [
{
name: "IPv6",
value: "0-9A-Za-z!#$%&()*+\\-;<=>?@^_`{|}~",
}
},
];
/**
* Returns the name of the alphabet, when given the alphabet.
*
@ -37,7 +36,7 @@ export function alphabetName(alphabet) {
alphabet = escape(alphabet);
let name;
ALPHABET_OPTIONS.forEach(function(a) {
ALPHABET_OPTIONS.forEach(function (a) {
const expanded = Utils.expandAlphRange(a.value).join("");
if (alphabet === escape(expanded)) name = a.name;
});