*/ class ProjectFactory extends Factory { /** * Define the model's default state. * * @return array */ protected $model = Project::class; public function definition(): array { return [ 'title' => $this->faker->sentence, 'category' => $this->faker->randomElement(['Web Design', 'App Design', 'Graphic Design', 'Front End', 'Back End']), 'images' => json_encode([ ['src' => $this->faker->imageUrl(), 'position' => 'bottom-[-5px] left-[-5px]', 'zIndex' => 20], ['src' => $this->faker->imageUrl(), 'position' => 'top-[-5px] right-[-5px]', 'zIndex' => 10], ]), ]; } }