> For the complete documentation index, see [llms.txt](https://design.mirakl.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://design.mirakl.com/design/patterns/forms/form-edition-mode.md).

# Form - Edition mode

An Edition form is when users edit an object/edit an element that already existed.

## Layout - Overview <a href="#id-604785" id="id-604785"></a>

### Page Title <a href="#id-31f410" id="id-31f410"></a>

<figure><img src="https://mirakl.zeroheight.com/uploads/I0DjB9Su8abz5cnY0W2GVg.svg" alt=""><figcaption><p>exemple of a page title</p></figcaption></figure>

* **Visibility:** The page title is always visible on a creation form.
* **Content:**  "Add *\[object name]*" or "Create **\[object name]**"&#x20;
* **Navigation:** Include a backlink for easy return to the previous page, unless this is the first page in the hierarchy.
  * **Backlink Content:** "Back to *\[landing page title]*", where *\[landing page title]* is the exact title of the return page.
* **Additional Information:** [Learn more about Page Titles and Backlinks](/design/components/navigation/page-title.md).

### Save Bar <a href="#id-120f27" id="id-120f27"></a>

<figure><img src="https://1297765105-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FMoZPkWOmnKvoMWGW4aeM%2Fuploads%2F93njCaXjNAdCFByOcJAi%2FSavebar%20Card.png?alt=media&amp;token=bb767cf9-b04e-43a0-9c35-ab6efe1785ce" alt="" width="548"><figcaption><p>Close-up on Save Bar</p></figcaption></figure>

<br>

* **Visibility:** The Save Bar remains hidden until one field in the form has been changed.&#x20;
* **Functionality:** Both '*Save*' and '*Cancel*' buttons are enabled when the Save Bar is visible.

{% hint style="info" %}
This behavior cannot be automated in ROMA. Designers must specify to developpers this behavior during handoff.
{% endhint %}

## Form submission <a href="#id-95884c" id="id-95884c"></a>

### Success behavior <a href="#id-06b627" id="id-06b627"></a>

*When the user successfully changes one or several inputs in the form.*

* Add a success [snackbar](/design/components/feedback/snackbar.md)
* The form stays in edition mode
* The user stays on the form page
* Follow the \[item] + past participate verb format.

{% hint style="info" %}
You do not need to add words such as "successfully" or "with success". [Learn more](/design/components/feedback/snackbar.md#0969f1)
{% endhint %}

<figure><img src="https://mirakl.zeroheight.com/uploads/OVpxkzhwOqWBe9994FRkxA.svg" alt="" width="375"><figcaption></figcaption></figure>

### &#x20;Discard edits

When the user clicks Discard or the backlink without saving form.

* **Form Pristine (unmodified)**: no modal + back to previous page
* **Form Dirty**: Confirm Modal + form goes back to the initial state (before changes) + user stays on form page

### Prevent changes while submission

Avoid custom behaviors: keep form creation consistent across all products.

## Take aways

{% hint style="success" %} <mark style="color:green;">**Do**</mark>

* Respect Layout guidelines
* Refer to [Error Management](/design/patterns/forms/error-management.md) page to guide users through the whole form experience
  {% endhint %}

{% hint style="danger" %} <mark style="color:red;">**Don't**</mark>

* Custom any behavior : form creation must remain consitent throught all products
* Show the Save Bar before any changes has been made
  {% endhint %}

<br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://design.mirakl.com/design/patterns/forms/form-edition-mode.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
