-
-
Notifications
You must be signed in to change notification settings - Fork 393
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
Add links to tile provider authentication docs #914
base: main
Are you sure you want to change the base?
Conversation
Should there also be a "Stadia Maps Access Token" field? |
It's not required for most web browser uses; I'll add one either this weekend or Monday. I see I also missed updating(?) some tests. Will look at that too. |
@HarelM any blockers for this one? |
Yes, translation is now needed for text. |
Got side tracked on a few other projects, but got back to adding the token support in the latest edits. Thanks for letting me know about the translation @HarelM! I didn't know that was a thing 😅 I've also added a few lines explaining that to the README. |
Yes, translation was added very recently. |
Thanks! |
Wait, what about the translation of the text you added? |
Ack.
I'll address both momentarily. |
I think adding a description like other fields is a good idea. |
@@ -130,6 +130,12 @@ class ModalExportInternal extends React.Component<ModalExportInternalProps> { | |||
value={(this.props.mapStyle.metadata || {} as any)['maputnik:thunderforest_access_token']} | |||
onChange={this.changeMetadataProperty.bind(this, "maputnik:thunderforest_access_token")} | |||
/> | |||
<FieldString |
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.
I would recommend, instead of using the FieldString
to maybe use the react components that this filed is built from, this way you'd have more control, and there won't be a need to add something specific to Doc component, which is a genereal one.
This is just a though...
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.
In order to pass down t
you simply need to pass it down to the relevant component, but since doc is part of block which is part of fieldsstring (IIRC) you'll need to pass it down a lot of levels, which is not trivial (and hackish).
Another possibility is translating it in the upper part and passing it down.
You might be able to construct a React Element and pass it down instead of passing down only a string, but that will require some typings updates in order to achieve this, and thay might not be trivial as well.
Let me know if I can help in any way.
This probably confused some people in the past, since vector tiles won't even display an access denied image ;)
Before (no information on access keys and where to get them):
After (add links to providers + add a field for Stadia Maps):