Connects a hylo-location-picker with a form.

At least on of the address input fields need to be set in order to see the address button. The input fields don't necessarily need to provide the exact data their names suggest. So can the house number be part of the street field already. The input fields are put together to an address string as follows:

<streetInput> <streetNrInput>, <zipInput> <cityInput>

If no streetInput and no streetNrInput is set, no comma is set. It is only important that all values result in a readable address.

If the first attempt does not result in a success and the streetNrInput field is set, a second attempt will made without the streetNrInput field.

Properties

cityInput: string | HTMLInputElement

An input field from which a part of the address is taken for the button locating action.

Can be a css query or a HTMLInputElement.

comma: boolean

As default, a dot is defined as decimal character. This property switches it to a comma.

latitudeInput: string | HTMLInputElement

An input field which value will be set by the component.

If not set, the component looks within its children elements for an input field with a "name" including the phrase "latitude".

If the input element has a value, the component sets its initial latitude property to this value.

Can be a css query or a HTMLInputElement.

longitudeInput: string | HTMLInputElement

An input field which value will be set by the component.

If not set, the component looks within its children elements for an input field with a "name" including the phrase "longitude".

If the input element has a value, the component sets its initial longitude property to this value.

Can be a css query or a HTMLInputElement.

streetInput: string | HTMLInputElement

An input field from which a part of the address is taken for the button locating action.

Can be a css query or a HTMLInputElement.

streetNrInput: string | HTMLInputElement

An input field from which a part of the address is taken for the button locating action.

Can be a css query or a HTMLInputElement.

textButtonSet: string = 'Adresse auf Karte übertragen'

The text of the address button.

textButtonUnset: string = 'Zurücksetzen'

The text of the reset button.

zipInput: string | HTMLInputElement

An input field from which a part of the address is taken for the button locating action.

Can be a css query or a HTMLInputElement.

zoom: number = 11

Initial zoom factor.

zoomLocation: number = 15

Zoom factor used when initial values for a location are present.

Methods

  • Returns the longitude and latitude input fields.

    Returns Promise<{
        latitude: HTMLInputElement;
        longitude: HTMLInputElement;
    }>

  • Resets the location longitude and latitude to the values of the longitude and latitude input fields respectively.

    Returns Promise<void>

Generated using TypeDoc