Oksydan / falcon

Prestashop starter theme that provides great development experience.
GNU General Public License v3.0
257 stars 61 forks source link

🐛 [BUG] - address-form.tpl needs validation class #419

Open Shoprunners opened 3 months ago

Shoprunners commented 3 months ago

Description

The address-form.tpl 's form should have the "needs-validation" class. With this class, the trim function for address fields will be called.

Node.js version

v14

php version

v8.1

OS and it's version

ALL

Browsers

No response

Required module/theme

theme

Reproduction steps

1. Add an address in the frontend
2. Add a "space" to a name / street field at the end
3. Save
4. Validation error will occur.

With the class, the "on blur" -> trim() will be called, like in the personal information form.

Logs

No response

Oksydan commented 2 months ago

Hi @Shoprunners,

thank you for creating an issue. I am adding this to roadmap.

maofree commented 2 months ago

Hi this fix is necessary into two files

checkout/_partials/steps/addresses.tpl replacing this line

to
and into customer/_partials/address-form.tpl using this line
bye