<?php

use Spatie\LaravelSettings\Migrations\SettingsBlueprint;
use Spatie\LaravelSettings\Migrations\SettingsMigration;

return new class extends SettingsMigration
{
    public function up(): void
    {
        $this->migrator->inGroup('system', function (SettingsBlueprint $blueprint): void {
            $blueprint->add('app_name', config('app.name', 'DST Collection'));
            $blueprint->add('address', 'Jl. Raya Cipeundeuy - Pabuaran No.909, Pabuaran, Kec. Pabuaran, Kabupaten Subang, Jawa Barat 41262');
            $blueprint->add('about_app', '');
            $blueprint->add('email', '');
            $blueprint->add('phone', '');
        });

        $this->migrator->inGroup('social_media', function (SettingsBlueprint $blueprint): void {
            $blueprint->add('instagram_url', null);
            $blueprint->add('facebook_url', null);
            $blueprint->add('tiktok_url', null);
        });

        $this->migrator->inGroup('hr', function (SettingsBlueprint $blueprint): void {
            $blueprint->add('scheduled_check_in_time', '08:00');
            $blueprint->add('scheduled_check_out_time', '17:00');
            $blueprint->add('late_penalty_amount', 0);
            $blueprint->add('absent_penalty_amount', 0);
        });

        $this->migrator->inGroup('homepage', function (SettingsBlueprint $blueprint): void {
            $blueprint->add('hero_image_url', 'https://images.unsplash.com/photo-1490481651871-ab68de25d43d?w=1000&auto=format&fit=crop&q=80');
            $blueprint->add('about_image_url', 'https://images.unsplash.com/photo-1595777457583-95e059d581b8?w=800&auto=format&fit=crop&q=80');
            $blueprint->add('gallery_images', [
                'https://images.unsplash.com/photo-1595777457583-95e059d581b8?w=800&auto=format&fit=crop&q=80',
                'https://images.unsplash.com/photo-1572804013309-59a88b7e92f1?w=800&auto=format&fit=crop&q=80',
                'https://images.unsplash.com/photo-1515886657613-9f3515b0c78f?w=800&auto=format&fit=crop&q=80',
                'https://images.unsplash.com/photo-1539109136881-3be0616acf4b?w=800&auto=format&fit=crop&q=80',
                'https://images.unsplash.com/photo-1496747611176-843222e1e57c?w=800&auto=format&fit=crop&q=80',
                'https://images.unsplash.com/photo-1509631179647-0177331693ae?w=800&auto=format&fit=crop&q=80',
            ]);
        });
    }
};
