Flag sequences
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 53
- Forks
- 22
- PR merge metrics
- No merged PRs in 30d
Description
Unicode has two mechanisms for encoding regional flags
- A pair of regional indicators (https://unicode.org/reports/tr51/#Flags). Only a subset of these pairs, determined by the CLDR, are valid. Valid pairs can never become invalid, only deprecated, so there's backwards compatibility.
- Emoji tag sequences (https://unicode.org/reports/tr51/#valid-emoji-tag-sequences) for subregions. In principle this can be used for thousands of subregions, but due to lack of font support the only three marked as "recommended for general interchange" are the ones for the three countries making up the UK.
We should add support for these, for instance through flag.de, flag.gb, flag.un, flag.eu ((macro)regions) and flag.gb.eng (subregion). Only valid sequences should be accepted.
One question is whether support for other subregions than the UK ones should be added. I did find at least one font that supports more subregions (https://www.babelstone.co.uk/Fonts/Flags.html).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the issue's Unicode TR51 references and locating the existing flag notation and validation behavior in the repository. Define support for valid regional-indicator pairs and the recommended UK tag sequences, then resolve whether additional subregions belong in scope; done means invalid sequences are rejected and the listed examples are accepted.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- internationalization
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100