<?php

namespace Database\Factories;

use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Support\Str;

/**
 * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Gallery>
 */
class GalleryFactory extends Factory
{
    /**
     * Define the model's default state.
     *
     * @return array<string, mixed>
     */
    public function definition(): array
    {
        $name = $this->faker->words(2, true);
        $slug = Str::uuid()->toString();

        return [
            'name' => $name,
            'slug' => $slug,
            'title' => $name,
            'images_path' => 'uploads/'.$slug,
            'is_public' => true,
            'allow_ai_styles' => true,
            'allow_print' => true,
            'require_password' => false,
            'password_hash' => null,
            'expires_at' => null,
            'access_duration_minutes' => null,
            'upload_enabled' => false,
            'upload_token_hash' => null,
            'upload_token_expires_at' => null,
            'sparkbooth_username' => 'spark-'.$this->faker->regexify('[a-z0-9]{6}'),
            'sparkbooth_password' => 'pw-'.$this->faker->regexify('[A-Za-z0-9]{10}'),
            'sparkbooth_response_format' => 'json',
        ];
    }
}
