<?php

namespace Database\Factories;

use App\Models\PublicationList;
use Illuminate\Database\Eloquent\Factories\Factory;

class PublicationListFactory extends Factory
{
    /**
     * The name of the factory's corresponding model.
     *
     * @var string
     */
    protected $model = PublicationList::class;

    /**
     * Define the model's default state.
     *
     * @return array
     */
    public function definition()
    {
        return [
            //'header' =>
            'hide_paginator' => false,
            //'blog_layouts' => [],
        ];
    }

    public function search()
    {
        return $this->state(function (array $attributes) {
            return [
                'header' => $this->faker->sentence,
            ];
        });
    }

    public function blog()
    {
        return $this->state(function (array $attributes) {
            return [
                'type' => 'blog',
            ];
        });
    }

    public function announcement()
    {
        return $this->state(function (array $attributes) {
            return [
                'type' => 'announcement',
            ];
        });
    }
}
