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

perf: Add basemaps from Carto #1107

Merged
merged 3 commits into from
Sep 28, 2021
Merged

perf: Add basemaps from Carto #1107

merged 3 commits into from
Sep 28, 2021

Conversation

marySalvi
Copy link
Contributor

@marySalvi marySalvi requested a review from manthey September 23, 2021 20:21
@manthey
Copy link
Contributor

manthey commented Sep 23, 2021

Since we switch to semantic-release, can you prefix the name of the PR with perf: -- this will make a point release when the branch is merged,

One of our examples shows off the list of defined tilesets (see examples/measure/index.pug). Can you add these to it?

Perhaps as a separate PR, we could add preferred human-readable labels to these definitions and then populate the example from the dictionary of values.

src/osmLayer.js Outdated
@@ -139,6 +142,18 @@ let StamenAttribution = 'Map tiles by <a href="http://stamen.com">Stamen ' +
* @type {object}
*/
osmLayer.tileSources = {
'darkMatter-with-labels': {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For consistency, should this be dark-matter-with-labels rather than camel case?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, yes it should.

@marySalvi
Copy link
Contributor Author

I can certainly add these to the example and make those changes.

@marySalvi
Copy link
Contributor Author

I added name to the tileSources definition and changed the example to load the tileSources dynamically. Let me know what you think.

@manthey
Copy link
Contributor

manthey commented Sep 27, 2021

Great.

@manthey manthey changed the title adds basemaps from Carto perf: Add basemaps from Carto Sep 27, 2021
src/osmLayer.js Outdated
'dark-matter-with-labels': {
url: ' https://{s}.basemaps.cartocdn.com/rastertiles/dark_all/{z}/{x}/{y}.png',
attribution: CartoAttribution,
name: 'Dark Matter With Labels',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My only recommendation is to prefix each of the Carto names with "Carto ".

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be all set now

@marySalvi marySalvi merged commit 657368c into master Sep 28, 2021
@github-actions
Copy link

🎉 This PR is included in version 1.4.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants