Skip to content

Commit

Permalink
feat(gmap-vue): upgrade markerclustererplus
Browse files Browse the repository at this point in the history
Upgrade to @google/markerclustererplus 5.1.0 and add clusterClass prop
  • Loading branch information
antoinematyja committed Oct 30, 2020
1 parent 04939da commit e64eafa
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 23 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
</div>

<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.6.11/vue.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/markerclustererplus/2.1.4/markerclusterer.js"></script>
<script src="https://unpkg.com/@google/markerclustererplus@5.1.0/dist/markerclustererplus.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gmap-vue@1.2.2/dist/gmap-vue.min.js"></script>

<script>
Expand Down
13 changes: 0 additions & 13 deletions packages/documentation/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/gmap-vue/examples/basic-marker-clusterer.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</div>

<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.6.11/vue.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/markerclustererplus/2.1.4/markerclusterer.js"></script>
<script src="https://unpkg.com/@google/markerclustererplus@5.1.0/dist/markerclustererplus.min.js"></script>
<script src="gmap-vue.js"></script>

<script>
Expand Down
10 changes: 5 additions & 5 deletions packages/gmap-vue/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/gmap-vue/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
"homepage": "https://github.com/diegoazh/gmap-vue#readme",
"dependencies": {
"marker-clusterer-plus": "^2.1.4"
"@google/markerclustererplus": "^5.1.0"
},
"peerDependencies": {
"vue": "^2.6.11"
Expand Down
6 changes: 5 additions & 1 deletion packages/gmap-vue/src/components/cluster.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
List of properties from
https://github.com/googlemaps/v3-utility-library/blob/master/markerclustererplus/src/markerclusterer.js
* */
import MarkerClusterer from 'marker-clusterer-plus';
import MarkerClusterer from '@google/markerclustererplus';
import mapElementFactory from '../factories/map-element';

const props = {
Expand Down Expand Up @@ -55,6 +55,10 @@ const props = {
type: Number,
twoWay: false,
},
clusterClass: {
type: String,
twoWay: false
},
styles: {
type: Array,
twoWay: false,
Expand Down
2 changes: 1 addition & 1 deletion packages/gmap-vue/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const webConfig = {
...config,
externals: {
vue: 'Vue',
'marker-clusterer-plus': 'MarkerClusterer'
'@google/markerclustererplus': 'MarkerClusterer'
},
output: {
path: path.resolve(__dirname, 'dist'),
Expand Down

0 comments on commit e64eafa

Please sign in to comment.