<?php

namespace Database\Factories;

use Illuminate\Database\Eloquent\Factories\Factory;

use App\Models\Page;
use App\Models\User;

/**
 * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Page>
 */
class PageFactory extends Factory
{
    protected $model = Page::class;
    
    public function definition(): array {
        return [
            'user_id' => User::factory(),
            'title' => $this->faker->sentence,
            'slug' => $this->faker->slug,
            'content' => ['blocks' => []],
            'is_published' => $this->faker->boolean,
            'main' => false,
            'linked' => false,
            'linkorder' => $this->faker->numberBetween(1, 10),
            'visibility' => 'public',
        ];
    }
}
