Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement generic fallbacks #3

Open
ecton opened this issue Jan 17, 2024 · 1 comment
Open

Implement generic fallbacks #3

ecton opened this issue Jan 17, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@ecton
Copy link
Member

ecton commented Jan 17, 2024

Currently to_nominal falls back to Decimal, but ideally we could have a tiered fallback system. When implementing #2, many systems specify a fallback outside of a given range.

It seems like we should restrict counter systems to their CSS ranges and support the same fallback mechanisms.

@ecton ecton added the bug Something isn't working label Jan 18, 2024
@ecton
Copy link
Member Author

ecton commented Jan 18, 2024

I just noticed that fallbacks are implemented incorrectly compared to the browser. I caused the base digit to repeat, using decimal for digits afterwards. It turns out I should have just started at the current decimal value once the set runs out -- e.g., for earthly branch, the first cjk-decimal should be 13.

ecton added a commit that referenced this issue Jan 19, 2024
Refs #3

This isn't a full fallback system, as really we should have a Range on
NominalSystem for that. This implementation hopefully can be compatible
with general nominal system fallback handling.
@ecton ecton added enhancement New feature or request and removed bug Something isn't working labels Jan 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant