<?php

namespace Database\Seeders\Tenant;

use App\Facades\Settings;
use Illuminate\Database\Seeder;

class SeoSitemapOfferSettingSeeder extends Seeder
{
    public function run(): void
    {
        collect($this->settings())
            ->each(fn($setting) => Settings::make($setting));
    }

    private function settings(): array
    {
        return [
            [
                'tab' => 'Site',
                'section' => 'SEO',
                'group' => 'Sitemap',
                'name' => 'Include offers top-level listing',
                'config_key' => 'seo-sitemap-offers-top-level-listing',
                'type' => 'boolean',
                'value' => true,
                'description' => 'Include the top-level offers listing page '
                    . '(e.g. /offers/) in the sitemap',
                'order' => 10,
            ],
            [
                'tab' => 'Site',
                'section' => 'SEO',
                'group' => 'Sitemap',
                'name' => 'Include offers type listing pages',
                'config_key' => 'seo-sitemap-offers-top-level-type-listing',
                'type' => 'boolean',
                'value' => true,
                'description' => 'Include offer type listing pages '
                    . '(e.g. /offers/motability) in the sitemap',
                'order' => 11,
            ],
            [
                'tab' => 'Site',
                'section' => 'SEO',
                'group' => 'Sitemap',
                'name' => 'Include franchise offer listing pages',
                'config_key' => 'seo-sitemap-offers-franchise-listing',
                'type' => 'boolean',
                'value' => false,
                'description' => 'Include franchise-specific offer listing '
                    . 'pages (e.g. /ford/offers) in the sitemap',
                'order' => 12,
            ],
            [
                'tab' => 'Site',
                'section' => 'SEO',
                'group' => 'Sitemap',
                'name' => 'Include franchise type listing pages',
                'config_key' => 'seo-sitemap-offers-franchise-type-listing',
                'type' => 'boolean',
                'value' => false,
                'description' => 'Include franchise+type listing pages '
                    . '(e.g. /ford/motability) in the sitemap',
                'order' => 13,
            ],
        ];
    }
}
