diglabby / mapa

Repository for Mapa project
GNU Affero General Public License v3.0
15 stars 21 forks source link

Try to save new entry without any required fields - form is not scrolled to top, so user can't see validation message #97

Open antos-k opened 4 years ago

antos-k commented 4 years ago
  1. Open map
  2. Press 'Add new entry' button
  3. Leave any required field empty
  4. Go to the bottom of item creation form
  5. Press 'Save'

Result: Form is not scrolled to top, so we can't see 'Something is missing, please check below.' message - user can to not understand, why nothing happens when he press Save. Expected result: Form is scrolled to the first validation message (so, user can see it and correct the reason)

wellemut commented 4 years ago

The Team in Munic is doing a big refactoring till end of September. this bug should be solved afterwards, because it might be solved during refactoring.

rizomaa commented 4 years ago

@antos-k could you show a screenshot for this bug?

PolinaSam commented 4 years ago

this bug hasn't been solved yet.

k-gorod commented 4 years ago

I cant imagine how to work with that naming methodology. image Would you like to tell me, how can i work with elements? But for now, i did that: <NavButton keyName = "save" classname = "pure-u-1-2" onClick = { () => { this.props.handleSubmit(); document.getElementsByClassName('pure-form')[0].scrollIntoView({block: "start", behavior: "smooth"}); }} icon = "save" text = { t("save") } />

https://youtu.be/hZ4JUPD3Aoo Is that action what we looking for?

rizomaa commented 4 years ago

@k-gorod yes, you are in a right direction please make a pull request to understand your whole solution.

k-gorod commented 4 years ago

Im noticed that some of elements have names. I used it to check them values. PR created

k-gorod commented 4 years ago

PR: https://github.com/diglabby/mapa/pull/349

rizomaa commented 4 years ago

@k-gorod дзякуй за ПР, у бліжэйшы час праглядзім

rizomaa commented 4 years ago

былі думы наконт таго, ці ёсць якая лібы для больш прыгожага рашэння, але акей, архітэктурна нейтральна там усё прымаю. будзем тэставаць)