Skip to content

Commit fba56eb

Browse files
committed
Fix: restore help text and fix indentation
1 parent 12450c1 commit fba56eb

3 files changed

Lines changed: 25 additions & 24 deletions

File tree

development/components/form/types-reference/email-type.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ Symfony native EmailType extended with IDNConverter (InternationalizedDomainName
2020

2121
```php
2222
$builder->add('email', EmailType::class, [
23-
'label' => $this->trans('Email address', [], 'Admin.Global'),
24-
'constraints' => [
25-
$this->getNotBlankConstraint(),
26-
$this->getLengthConstraint(EmployeeEmail::MAX_LENGTH),
27-
new Email([
28-
'message' => $this->trans('This field is invalid', [], 'Admin.Notifications.Error'),
29-
]),
30-
],
31-
])
23+
'label' => $this->trans('Email address', [], 'Admin.Global'),
24+
'constraints' => [
25+
$this->getNotBlankConstraint(),
26+
$this->getLengthConstraint(EmployeeEmail::MAX_LENGTH),
27+
new Email([
28+
'message' => $this->trans('This field is invalid', [], 'Admin.Notifications.Error'),
29+
]),
30+
],
31+
])
3232
```
3333

3434
## Preview example

development/components/form/types-reference/entity-search-input-type.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ $builder
4141
'label' => false,
4242
'remote_url' => $this->router->generate('admin_categories_get_ajax_categories', ['query' => '__QUERY__']),
4343
'placeholder' => $this->trans('To which category should the page redirect?', 'Admin.Catalog.Help'),
44+
'help' => $this->trans('By default, the closest active parent category will be used if no category is selected.', 'Admin.Catalog.Help'),
4445
'filtered_identities' => [$options['id_category'], $this->homeCategoryId],
4546
]);
4647
```

development/components/form/types-reference/icon-button-type.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,23 @@ A form button with material icon.
2121
- [FooterType](https://github.com/PrestaShop/PrestaShop/blob/9.1.0/src/PrestaShopBundle/Form/Admin/Sell/Product/FooterType.php#L102-L116)
2222

2323
```php
24-
$builder
25-
->add('actions', ButtonCollectionType::class, [
26-
'buttons' => [
27-
'catalog' => [
28-
'type' => IconButtonType::class,
29-
'options' => [
30-
'label' => $this->trans('Go to catalog', 'Admin.Catalog.Feature'),
31-
'type' => 'link',
32-
'icon' => 'arrow_back_ios',
33-
'attr' => [
34-
'class' => 'btn-outline-secondary go-to-catalog-button',
35-
'href' => $this->router->generate('admin_products_index', ['offset' => 'last', 'limit' => 'last']),
36-
],
37-
],
24+
$builder
25+
->add('actions', ButtonCollectionType::class, [
26+
'buttons' => [
27+
'catalog' => [
28+
'type' => IconButtonType::class,
29+
'options' => [
30+
'label' => $this->trans('Go to catalog', 'Admin.Catalog.Feature'),
31+
'type' => 'link',
32+
'icon' => 'arrow_back_ios',
33+
'attr' => [
34+
'class' => 'btn-outline-secondary go-to-catalog-button',
35+
'href' => $this->router->generate('admin_products_index', ['offset' => 'last', 'limit' => 'last']),
3836
],
3937
],
40-
])
38+
],
39+
],
40+
])
4141
```
4242

4343
## Preview example

0 commit comments

Comments
 (0)