MCPcopy Create free account
hub / github.com/fontsource/fontsource / normalizeCollectionName

Function normalizeCollectionName

website/app/features/collections/model.ts:11–12  ·  view source on GitHub ↗
(name: string)

Source from the content-addressed store, hash-verified

9// Preserve the user's spelling for display while comparing equivalent input.
10const formatCollectionName = (name: string) => name.trim().normalize('NFC');
11const normalizeCollectionName = (name: string) =>
12 formatCollectionName(name).toLowerCase().normalize('NFC');
13
14// Collection limits are based on visible characters. Grapheme segmentation keeps
15// composed scripts and emoji from being penalized for their code point count.

Callers 6

getDuplicateNameFunction · 0.90
ManageCollectionsModalFunction · 0.90
AddToCollectionMenuFunction · 0.90
CollectionFilterFunction · 0.90
model.tsFile · 0.85

Calls 1

formatCollectionNameFunction · 0.85

Tested by

no test coverage detected