-
-
Notifications
You must be signed in to change notification settings - Fork 19
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
Show sponsor goal progress bar #347
Conversation
This comment has been minimized.
This comment has been minimized.
@tintou any thoughts on how a github token should be stored? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the UI parts of this look good to me! Localization, dark mode, etc all seems good
I think I'd like another opinion about if there's a better way to store a token 😅 But otherwise I'm happy with this 🎉
@danirabbit we have a problem with the type of currency, in your case that you live in the USA, the type of currency is the dollar, but for me that I live in Peru, it is the Sol, and it is giving me an incorrect value of the goal. I think the currency type should always be in dollars, because that is the currency github works with. |
Ah shit. Yeah we want to localize delimiters and like the placement of the currency symbol, but not the currency type itself haha. I'll investigate more how to use this library |
As far as I can see, the library only works taking into account the configured regional settings. |
Well there's that, and that's fine it can picked up by regular string translation. But we also need to localize the delimiters. In en_US there should be a |
Yeah, I don't love the idea of having a token here at all, even if it only has public read only access. The correct way to do this would probably be to have an endpoint on the website that fetches this data using a token we can keep secret and just returns the data publicly. |
Opened elementary/website#3690 to add an endpoint returning this info to the website. |
The new API endpoint is now available on the website: https://elementary.io/api/sponsors_goal |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's very cute, it works as expected, I'm happy with this. Nice work!
Fixed #329