fix: show correct software names (close #30)
This commit is contained in:
parent
055bec56c7
commit
b164984abb
@ -38,7 +38,29 @@ const instance = props.instance ?? {
|
||||
softwareName: Instance.softwareName || "Firefish",
|
||||
};
|
||||
|
||||
const capitalize = (s: string) => s && s[0].toUpperCase() + s.slice(1);
|
||||
const commonNames = new Map<string, string>([
|
||||
["birdsitelive", "BirdsiteLIVE"],
|
||||
["bookwyrm", "BookWyrm"],
|
||||
["foundkey", "FoundKey"],
|
||||
["gnusocial", "GNU Social"],
|
||||
["gotosocial", "GoToSocial"],
|
||||
["microblogpub", "microblog.pub"],
|
||||
["nextcloud social", "Nextcloud Social"],
|
||||
["peertube", "PeerTube"],
|
||||
["snac", "snac"],
|
||||
["snac2", "snac2"],
|
||||
["takahe", "Takahē"],
|
||||
["wafrn", "WAFRN"],
|
||||
["wordpress", "WordPress"],
|
||||
["writefreely", "WriteFreely"],
|
||||
["wxwclub", "wxwClub"],
|
||||
]);
|
||||
|
||||
const capitalize = (s: string) => {
|
||||
if (s == null) return "Unknown";
|
||||
if (commonNames.has(s)) return commonNames.get(s);
|
||||
return s[0].toUpperCase() + s.slice(1);
|
||||
};
|
||||
|
||||
const computedStyle = getComputedStyle(document.documentElement);
|
||||
const themeColor =
|
||||
|
Loading…
Reference in New Issue
Block a user