Skip to content

Commit 807d3e9

Browse files
authored
Merge pull request #134 from forced-request/fix-readme-table
Cleaned up the 'types' description and added 'supported types' table
2 parents 5d4afb9 + 677dddd commit 807d3e9

File tree

1 file changed

+12
-13
lines changed

1 file changed

+12
-13
lines changed

README.md

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -303,23 +303,22 @@ export class HomeComponent implements OnInit {
303303
| country | Input() | string | string[]; | - | can be used to restrict results to specific groups. Currently, you can use componentRestrictions to filter by up to 5 countries. Countries must be passed as as a two-character, ISO 3166-1 Alpha-2 compatible country code. Multiple countries must be passed as a list of country codes.
304304
| placeIdOnly | Input() | boolean | - | can be used to instruct the Autocomplete widget to retrieve only Place IDs. On calling getPlace() on the Autocomplete object, the PlaceResult made available will only have the place id, types and name properties set. You can use the returned place ID with calls to the Places, Geocoding, Directions or Distance Matrix services.
305305
| strictBounds | Input() | boolean | - | is a boolean specifying whether the API must return only those places that are strictly within the region defined by the given bounds. The API does not return results outside this region even if they match the user input.
306-
| types | Input() | string[] | - | An array of types specifies an explicit type or a type collection, as listed in the supported types below. If nothing is specified, all types are returned. In general only a single type is allowed. The exception is that you can safely mix the geocode and establishment types, but note that this will have the same effect as specifying no types. The supported types are:
307-
geocode instructs the Places service to return only geocoding results, rather than business results.
308-
address instructs the Places service to return only geocoding results with a precise address.
309-
establishment instructs the Places service to return only business results.
310-
the (regions) type collection instructs the Places service to return any result matching the following types:
311-
locality
312-
sublocality
313-
postal_code
314-
country
315-
administrative_area1
316-
administrative_area2
317-
the (cities) type collection instructs the Places service to return results that match either locality or administrative_area3.
306+
| types | Input() | string[] | - | An array of types specifies an explicit type or a type collection, as listed in the supported types below. If nothing is specified, all types are returned. In general only a single type is allowed. The exception is that you can safely mix the geocode and establishment types, but note that this will have the same effect as specifying no types. Supported types are listed below. |
318307
| type | Input() | string | - |
319308
| autoCompleteOptions | Input() | AutocompleteOptions | - | all above inputs in one object! The passed data to this object will be merged with the input if they exists
320309
| onChange | Output() | PlaceResult | string | null | - | event when the input form value changed
321310
| onAutocompleteSelected | Output() | PlaceResult | - | the event will be fired when a place has been selected via the google maps autocomplete component
322-
| onLocationSelected | Output() | Location | - | the event will be fired when a place has been selected via the google maps autocomplete component
311+
| onLocationSelected | Output() | Location | - | the event will be fired when a place has been selected via the google maps autocomplete component |
312+
313+
#### Supported Types
314+
315+
| type | description |
316+
| --- | --- |
317+
| geocode | instructs the Places service to return only geocoding results, rather than business results. |
318+
| address | instructs the Places service to return only geocoding results with a precise address. |
319+
| establishment | instructs the Places service to return only business results. |
320+
|regions | instructs the Places service to return any result matching the following types: locality, sublocality, postal_code, country, administrative_area1, administrative_area2 |
321+
| cities | instructs the Places service to return results that match either locality or administrative_area3. |
323322

324323

325324
### `mat-google-maps-autocomplete`

0 commit comments

Comments
 (0)