feat(api): add Dakao integration
This commit is contained in:
1 parent
9ebdc9b61f
commit
ba3894cba2
10 files changed
+1257
No files matched your search
@@ -0,0 +1,14 @@
|
||||
const ZERO_WIDTH_CHARACTERS = /[\u200B-\u200D\uFEFF]/g;
|
||||
|
||||
export function normalizeRiotIdPart(value: string): string {
|
||||
return value.replace(ZERO_WIDTH_CHARACTERS, '').trim().normalize('NFC');
|
||||
}
|
||||
|
||||
export function formatCodePoints(value: string): string {
|
||||
return Array.from(value)
|
||||
.map((char) => {
|
||||
const codePoint = char.codePointAt(0);
|
||||
return `U+${codePoint?.toString(16).toUpperCase().padStart(4, '0')}`;
|
||||
})
|
||||
.join(' ');
|
||||
}
|
||||
Reference in new issue
Block a user