odoo/odoo#204738

Created by fw-bot
Merged at 880b5873c8105c18436c36de5aa290fb58ca60d8

Statuses:

label
odoo-dev:saas-18.1-17.0-fix-form-snippet-issues-aans-427483-fw
head
4e1ee8861e6b9fcfdba077d50c253ba8b03013a0
merged
7 months ago by Website, Serge Bayet (seba)
odoo/odoo
17.0 #179858
saas-17.4 #204625
18.0 #204657
saas-18.1 #204738
saas-18.2 #204752
saas-18.3
saas-18.4
19.0
master #204781

[FW][FIX] website: Fix form snippet field options and styling loss on undo

In a form snippet, enabling the "Description" option for a field and then undoing this action caused the field to lose its styling and available customization options.

Steps to reproduce:
- Enter Edit mode.
- Add a Form snippet.
- Select any field (e.g., "Your Name").
- Enable the "Description" option from the customization panel.
- Undo the action (Ctrl+Z).

This results in the field losing its padding and the "Description" and other options being removed.

Cause:
A redundant line of code was adding an extra step in the mutation history. When undoing, this extra step caused the removal of essential classes from the field, leading to the loss of styling and options.

Fix:
Removed the redundant line to ensure undoing the action correctly restores the previous state without affecting the field’s styling or customization options.

task-4013551

Forward-Port-Of: #179858