Skip to content
This repository was archived by the owner on Apr 16, 2020. It is now read-only.

Conversation

mwakerman
Copy link

I replaced my previous new tab extension (https://chrome.google.com/webstore/detail/planet-view/hhhgdbldiopbpblfcohjaeinjjciplho) with this one but missed the globe feature. This is just a first cut and I'm happy to add an enable/disable setting but I saw you wrote on another PR that you were worried about the settings getting too big. I chose the colours from the Mapbox colour pallete but I'd also be interested in colouring the globe based on the map colours which you've also talked about doing in another PR.

…borders are not shown (also white) and pings are Mapbox blue.

Added the drag planetaryjs plugin so the globe can be rotated.
@mwakerman
Copy link
Author

After intense consultation with my housemates, we decided on a different colour scheme.

@bsudekum
Copy link
Owner

Hey thanks for putting this together @mwakerman. I have a couple pieces of feedback for you.

  • This introduces many new dependencies. Could this be implemented with fewer? One that I see that could go right away is topojson. Why not just store the globe as geojson?
  • New dependencies should be installed via npm install and required and bundle in the bundle.js. When you're done making changes, run npm run build and commit changes to the bundle.js
  • 👍 on changing the color. The green was bit much.
  • One of maptab's strengths is it's simplicity, this PR adds a bit of visual noise. I think this should be an option with the default off.
  • Could this be accomplished using the mapbox static api? Example:
    • maybe

@mwakerman
Copy link
Author

So I had thought about doing an overlayed image like that above but on purely subjective grounds decided to implement the globe instead. If you (or someone else) wants an image instead then some of my impl is probably re-usable but I personally prefer the globe.

Regarding your dependency suggestiions, completely agree and will bring them in, trim them and browserify them into the bundle.js. Unfortunately Planetaryjs is not npm, I've contacted the owner to see if he want's to publish/is ok with me publishing it and will bring it in this way eventually.

I beleive that the TopoJson library converts the world-110m.json file to GeoJSON for use with D3 which is doing the heavy lifting underneath Planetaryjs. For what it's worth, TopoJson allows for much smaller data files (http://stackoverflow.com/questions/14740705/difference-between-geojson-and-topojson) and is probably the smaller choice here given that the TopoJson library is 6KB and the world-110m.json file is 87KB (if file size is your concern).

I'll also add a checkbox to the settings modal for hiding and showing the globe.

@mwakerman
Copy link
Author

Apologies for the months of radio silence. I've made the changes you suggested, namely putting the globe behind a setting (with it off as default) as well as sourcing dependencies from npm and rebuilding the bundle.js.

@mwakerman
Copy link
Author

Any chance this will ever be merged? If not, we can close.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants