11<?php
22
3+ /*
4+ * This file is part of the SymfonyCasts DynamicForms package.
5+ * Copyright (c) SymfonyCasts <https://symfonycasts.com/>
6+ * For the full copyright and license information, please view the LICENSE
7+ * file that was distributed with this source code.
8+ */
9+
310namespace Symfonycasts \DynamicForms \Tests \fixtures ;
411
512use Symfony \Component \Form \AbstractType ;
@@ -29,7 +36,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void
2936 ]);
3037
3138 // addDynamic(string $name, array $dependencies, callable $callback): self
32- $ builder ->addDependent ('mainFood ' , ['meal ' ], function (DependentField $ field , ?DynamicTestMeal $ meal ) {
39+ $ builder ->addDependent ('mainFood ' , ['meal ' ], function (DependentField $ field , ?DynamicTestMeal $ meal ) {
3340 $ field ->add (EnumType::class, [
3441 'class ' => DynamicTestFood::class,
3542 'placeholder ' => null === $ meal ? 'Select a meal first ' : sprintf ('What is for %s? ' , $ meal ->getReadable ()),
@@ -39,7 +46,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void
3946 ]);
4047 });
4148
42- $ builder ->addDependent ('pizzaSize ' , ['mainFood ' , 'upperCasePizzaSizes ' ], function (DependentField $ field , ?DynamicTestFood $ food , bool $ upperCasePizzaSizes ) {
49+ $ builder ->addDependent ('pizzaSize ' , ['mainFood ' , 'upperCasePizzaSizes ' ], function (DependentField $ field , ?DynamicTestFood $ food , bool $ upperCasePizzaSizes ) {
4350 if (DynamicTestFood::Pizza !== $ food ) {
4451 return ;
4552 }
0 commit comments