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

[BUG] Layer Attribution Option #545

Open
wildintellect opened this issue Jun 13, 2024 · 6 comments
Open

[BUG] Layer Attribution Option #545

wildintellect opened this issue Jun 13, 2024 · 6 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@wildintellect
Copy link

wildintellect commented Jun 13, 2024

Context

What results were you expecting?

Some external layers require attribution as part of their licensing and terms of use. Many mapping libraries implement this as an attribution key on a layer definition that becomes a rendered over the map static text (sometimes HTML is supported).

BaseMap Layers might already have this specified in their style json, but will likely come up with many layer types particularly BitMapTileLayer where an external XYZ tile service is used.
https://maplibre.org/maplibre-style-spec/sources/#attribution
https://maplibre.org/maplibre-gl-js/docs/API/classes/AttributionControl/

This may not be a critical feature for users viewing their own notebooks, but will be an issue as they shared rendered notebooks or export images.

@wildintellect wildintellect added bug Something isn't working enhancement New feature or request labels Jun 13, 2024
@kylebarron
Copy link
Member

This is somewhat related to ideas I've had about letting users add to the underlying Maplibre map, e.g. through custom basemap styles #494. But there's also a question of how tied Lonboard should be to Maplibre. It makes some things like this simpler but also makes other things harder, because tying us to maplibre ties us to Web Mercator

@vgeorge vgeorge mentioned this issue Jul 1, 2024
vgeorge added a commit that referenced this issue Jul 4, 2024
This adds a `custom_attribution` property to the `Map` class and fix
Maplibre CSS by adding an import. Contributes to:

- #436
- #545
@vgeorge
Copy link
Member

vgeorge commented Jul 4, 2024

In #561, we fixed the styles for the MapLibre attribution control and added the custom_attribution parameter to the Map class to allow passing a custom attribution. However, we still need to:

@prusswan
Copy link

This is somewhat related to ideas I've had about letting users add to the underlying Maplibre map, e.g. through custom basemap styles #494. But there's also a question of how tied Lonboard should be to Maplibre. It makes some things like this simpler but also makes other things harder, because tying us to maplibre ties us to Web Mercator

Which other projections do you plan on supporting that is not web mercator? If you are considering broader support in the form of WMTS, there is OWSLib (not sure how well it will work with an interactive plot). On the JS front, OpenLayers has comprehensive WMTS support but it is probably easier to add Lonboard functionality to OpenLayers than the other way around.

@kylebarron
Copy link
Member

deck.gl can render cartesian coordinates, so in principle we can render data in any coordinate system. We'll only be able to provide basemap data via Maplibre in Web Mercator, because Maplibre only supports Web Mercator. But we could have some minimal context information (country boundaries?) in other projections, to render under the data to give some context.

I've never used OpenLayers and I don't see us integrating with it.

@prusswan
Copy link

deck.gl can render cartesian coordinates, so in principle we can render data in any coordinate system. We'll only be able to provide basemap data via Maplibre in Web Mercator, because Maplibre only supports Web Mercator.

For data in non-standard projections that need a basemap overlay, you can consider supporting WMS data layers (which supports fetching dynamic tiles by bounding box and crs). This is not very different from the current BitmapTileLayer which works for XYZ tilesets (which could be generalized into WMTS but that is substantially more work).

@kylebarron
Copy link
Member

I think in the near term, if we supported non-web mercator we wouldn't try to support basemaps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants