ausocean / openfish

OpenFish is an open-source system written in GoLang for classifying marine species. Tasks involve importing video or image data, classifying and annotating data (both manually and automatically), searching, and more. It is expected that OpenFish will use utilize computer vision and machine learning techniques.
https://ausocean.github.io/openfish/
Other
6 stars 0 forks source link

Add location picker form element #111

Closed scott97 closed 7 months ago

scott97 commented 7 months ago

The location picker form element is useful for getting a lat-long from the user. I plan on using it for picking the location of a capture source. You can paste lat long coordinates or click on the map to set the location. To get the selected location you can use the same code you would for an ordinary form input.

// Use this as your form submit handler
submit(e: SubmitEvent) {
    e.preventDefault()

    const formdata = new FormData(e.target as HTMLFormElement)
    console.log(formdata.get('location'))
}

Screencast from 2024-04-17 09-56-41.webm