Giter Site home page Giter Site logo

Comments (8)

adolmajian avatar adolmajian commented on July 18, 2024 1

Was anyone able to solve this? Binding the map to a container?

from mapbox.

dagatsoin avatar dagatsoin commented on July 18, 2024

#29 do this, but only for iOS for now. I am currently converting it to Android, release in the two next weeks.

from mapbox.

JoellyR avatar JoellyR commented on July 18, 2024

Hi, I am trying to use the solution from #29. I added the "div" element the show method... But it doesnt seem to change anything... I pulled using

cplugin add https://github.com/Telerik-Verified-Plugins/Mapbox --variable ACCESS_TOKEN=sk.eyJ1Ijoiam9lbGx5ciIsImEiOiJjaXY4aTl0NTAwMDk0MzBzOTUyanRzNmpjIn0.4tDzPE9VwqhxTI7iM3_3oA

Maybe that branch doesn't have #29 's changes?

here is the code i tried.

Mapbox.show({
          div: 'map_canvas',
          style: 'emerald', // light|dark|emerald|satellite|streets , default 'streets'
          margins: {
            left: 0, // default 0
            right: 0, // default 0
            top: 316, // default 0
            bottom: 50 // default 0
          },
          center: { // optional, without a default
            lat: 52.3702160,
            lng: 4.8951680
          },
          zoomLevel: 12, // 0 (the entire world) to 20, default 10
          showUserLocation: true, // your app will ask permission to the user, default false
          hideAttribution: false, // default false, Mapbox requires this default if you're on a free plan
          hideLogo: false, // default false, Mapbox requires this default if you're on a free plan
          hideCompass: false, // default false
          disableRotation: false, // default false
          disableScroll: false, // default false
          disableZoom: false, // default false
          disablePitch: false, // disable the two-finger perspective gesture, default false
          markers: [
            {
              lat: 52.3732160,
              lng: 4.8941680,
              title: 'Nice location',
              subtitle: 'Really really nice location'
            }
          ]
        },

        // optional success callback
        function(msg) {
          console.log("Success :) " + JSON.stringify(msg));
        },

        // optional error callback
        function(msg) {
          alert("Error :( " + JSON.stringify(msg));
        }
);

html

<section layout="row"  flex>
            <!-- Container #4 -->
            <md-card style="width:100%" flex>
                <md-card-content layout="column" layout-wrap class="no-padding" flex>
                    <div id='map_canvas' class="child-flexwrapper" flex="100"></div>
                </md-card-content>
            </md-card
</section>

from mapbox.

dagatsoin avatar dagatsoin commented on July 18, 2024

Do you develop for Android or iOS? I am supporting only Android for now.

from mapbox.

yipcma avatar yipcma commented on July 18, 2024

I'm interested as well in binding the map to a container.

from mapbox.

janedzumerko avatar janedzumerko commented on July 18, 2024

@salman-ghauri Did you solve this issue? I have the same one now.

from mapbox.

cusspvz avatar cusspvz commented on July 18, 2024

@dagatsoin is looking for iOS support.

If any of you guys has some spare time and iOS development skills, could you guys give us a hand?

from mapbox.

ansarikhurshid786 avatar ansarikhurshid786 commented on July 18, 2024

I am also looking add map to specific id.

from mapbox.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.