Skip to content

Commit

Permalink
fix(gmap-vue): fix fields error on autocomplete component
Browse files Browse the repository at this point in the history
Solve #118
  • Loading branch information
diegoazh committed Feb 11, 2022
1 parent 26e43f7 commit a6b8712
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions packages/documentation/docs/guide/autocomplete.md
Expand Up @@ -73,7 +73,7 @@ export default {
options: {
type: Object,
},
fields: {
setFieldsTo: {
required: false,
type: Array,
default: null,
Expand Down Expand Up @@ -126,8 +126,8 @@ export default {
bindProps(this, this.$autocomplete, autocompleteMappedProps);
if (this.fields) {
this.$autocomplete.setFields(this.fields);
if (this.setFieldsTo) {
this.$autocomplete.setFields(this.setFieldsTo);
}
this.$autocomplete.addListener('place_changed', () => {
Expand Down
6 changes: 3 additions & 3 deletions packages/gmap-vue/src/components/autocomplete-input.vue
Expand Up @@ -103,7 +103,7 @@ export default {
* @see [setFields](https://developers.google.com/maps/documentation/javascript/reference/places-widget#Autocomplete.setFields)
* @see [PlaceResult](https://developers.google.com/maps/documentation/javascript/reference/places-service#PlaceResult)
*/
fields: {
setFieldsTo: {
required: false,
type: Array,
default: null,
Expand Down Expand Up @@ -167,8 +167,8 @@ export default {
bindProps(this, this.$autocomplete, autocompleteMappedProps);
if (this.fields) {
this.$autocomplete.setFields(this.fields);
if (this.setFieldsTo) {
this.$autocomplete.setFields(this.setFieldsTo);
}
// Not using `bindEvents` because we also want
Expand Down

0 comments on commit a6b8712

Please sign in to comment.