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

Embed an interactive map as html #327

Closed
macrigiuseppe opened this issue Jan 13, 2019 · 9 comments
Closed

Embed an interactive map as html #327

macrigiuseppe opened this issue Jan 13, 2019 · 9 comments
Assignees
Labels
enhancement An update of a existing feature feature A new feature rfc roadmap item Item that's on our current roadmap

Comments

@macrigiuseppe
Copy link
Collaborator

macrigiuseppe commented Jan 13, 2019

Is your feature request related to a problem? Please describe.
Currently there is now way to export an existing map as an html file

Describe the solution you'd like
As user I should be able to export the map from the export bar

Potential designs:

  • Independent options

screen shot 2019-01-13 at 12 59 57 pm

  • or we can combine "Export map url" and "Export map" into a single element.

screen shot 2019-01-13 at 1 42 28 pm

And in the export modal dialog we provide the following options:

  • Export map to an html file
  • Export to Cloud and generate permalink

Existing issues affected:
#301
#223 possible reference

Possible implementation

  • Convert the entire page into a string and save it as html file using html-screen-capture-js. Maybe using webworkers to speed up the process.
  • Static template:
    • Publish a build of kepler.gl to cdn
    • Generate a static html file we are going to use as the template, it should be automatically generated during deploy
    • Once users export a map, we can simply hydrate the template with data/configuration map

Considerations

  • Should we link js and css externally or keep them in line?
  • What happens if data is too big? Can we combine everything in one file or should we use an external file?
@macrigiuseppe macrigiuseppe added this to the Milestone (Jan 11, 2019) milestone Jan 13, 2019
@macrigiuseppe macrigiuseppe self-assigned this Jan 13, 2019
@macrigiuseppe macrigiuseppe added roadmap item Item that's on our current roadmap feature A new feature enhancement An update of a existing feature rfc labels Jan 13, 2019
@roqueleal
Copy link

roqueleal commented Jan 15, 2019

We hope soon you can develop the embeded module soon! Greetings excellent contributions

@macrigiuseppe
Copy link
Collaborator Author

reference: #331

@macrigiuseppe
Copy link
Collaborator Author

This is blocked by #332

@schnerd
Copy link
Collaborator

schnerd commented Feb 8, 2019

One consideration that I don't see listed in the issue: Versioning of builds published to the CDN.

If the static HTML people are using makes any assumptions about the kepler JS API (or CSS for that matter), then the builds published to the CDN should probably be versioned. Otherwise publishing a new Kepler build with backwards incompatible changes could break all these old static pages. If you make the bundled code a part of the published npm package, you could probably use unpkg as a free CDN for this.

@macrigiuseppe
Copy link
Collaborator Author

One consideration that I don't see listed in the issue: Versioning of builds published to the CDN.

If the static HTML people are using makes any assumptions about the kepler JS API (or CSS for that matter), then the builds published to the CDN should probably be versioned. Otherwise publishing a new Kepler build with backwards incompatible changes could break all these old static pages. If you make the bundled code a part of the published npm package, you could probably use unpkg as a free CDN for this.

@schnerd unpkg is exactly the strategy we have decided to pursuit .

@briantcl briantcl modified the milestones: Milestone (Jan 14, 2019), Feb 22, 2019 Sprint Feb 22, 2019
@briantcl
Copy link
Contributor

as discussed in the sprint meeting, we will also test it out by introducing this new feature in a medium ariticle as well. thanks!

@Jesterary
Copy link

How soon will this feature be available? It will be very helpful!

@macrigiuseppe
Copy link
Collaborator Author

macrigiuseppe commented Mar 3, 2019

How soon will this feature be available? It will be very helpful!

@Jesterary the necessary work for the functionality is tracked in here: #366

@briantcl briantcl removed this from the 02/25/2019 Sprint milestone Apr 5, 2019
@vulkenree
Copy link

can I easily embed kepler.gl to a dash app?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An update of a existing feature feature A new feature rfc roadmap item Item that's on our current roadmap
Projects
None yet
Development

No branches or pull requests

6 participants