Coder Social home page Coder Social logo

txs1992 / fast-amap Goto Github PK

View Code? Open in Web Editor NEW
130.0 1.0 17.0 2.78 MB

🚀🚀🚀 一个基于 Vue 的高性能 高德地图 组件库,A High Performance AMap Component Library Based on Vue.

Home Page: https://txs1992.github.io/fast-amap/

License: MIT License

JavaScript 75.49% HTML 0.27% Vue 24.10% SCSS 0.14%
map-conponent amap amap-component vue vue-amap amapsdk

fast-amap's People

Contributors

dependabot[bot] avatar txs1992 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

fast-amap's Issues

关于FastInfoWindow默认显示的问题

大佬可以增加一个控制InfoWindow加载完成后默认显示或者默认不显示的控制项么。因为有些业务需求需要通过Marker点击后再出现InfoWindow。现目前本人的项目是通过v-if进行控制渲染,但使用该方法回导致一系列加载时机的问题,让其变得难以控制。望大佬增加一个控制选项配置,感谢大佬。
由于本人才疏学浅,只能跟上大佬的一点点思路,去跟了一下大佬的源码。发现是大佬创建实例后,默认调用了open函数

    handleOptionsChange() {
      this.getAMapPromise().then(() => {
        const map = this.getMapInstance(this.mid)
        const options = this.getInstanceOptions()
        if (!this.content && this.$el) {
          options.content = this.$el
        }
        const instance = this.createInstance(options)
        this.instance = instance
        instance.open(map, this.position)
      })
    },

fast-info-window 里面设置options不起作用

fast-info-window 里面设置options不起作用 里面设置的属性不起作用,并且不能动态的去替换 希望能有个例子

<fast-info-window
        is-cstom
        ref="infoWindow"
        mid="infoWindow"
        :offset="[-13, -30]"
        :position="[121.472644, 31.231049]"
        :default-open="false"
        :options="options"
      >
      </fast-info-window>

data里面

    options: {
        position: [123.472644, 31.231049],
        content: `<div>测试内容</div>`
      }

这样显示的是没内容的 如果把 :position="[121.472644, 31.231049]" 去掉 直接没东西了
也没办法根options里面的内容区动态的改变infowindow里面的东西 不知道是设计如此还是怎么回事

作者什么时候能兼容下2.0呢

新的一些属性没有,比如说AMap.Marker的opts.zooms 并且老的一些过期了的 比如说 AMap的animation属性 这都没有在文档中标注出来,一顿爬坑

center 无法动态改变

我用 AMap.Geolocation 插件 ip 定位后改变 center,但是地图不会动态改变 center。map 能否 watch center 动态改变?

想问下如何初始化时候引入地图的官方图层的

官方示例这样写的

 var layer = new AMap.TileLayer({
          zooms:[3,20],    //可见级别
          visible:true,    //是否可见
          opacity:1,       //透明度
          zIndex:0         //叠加层级
    })
    var map = new AMap.Map('container',{
          layers:[layer] //当只想显示标准图层时layers属性可缺省
    });


在vue中

 <fast-map
      :mid="12"
      ref="map"
      :zoom="15"
      :options="options"
      :center="center"
      :double-click-zoom="false"
      @click="handleClick"
      @complete="handleComplete"
      :layers="layers"
      @dragstart="handleMovestart"
      @resize="handleMapmove"
    >
data() {
    return {
      options: {
        height: 800,
        zooms: [3, 16]
      },
      center: [121.472644, 31.231049],

      layers: [new Amap.TileLayer.Satellite(), new Amap.TileLayer.RoadNet()]
    }
  }

我如何拿到这个Amap呢

zoom问题

当zoom改变时,再去设置zoom不起作用?

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.