@extends('layouts.admin')
@section('content')
<div class="page-header"><div class="page-block"><div class="row align-items-center">
    <div class="col-md-12"><ul class="breadcrumb"><li class="breadcrumb-item"><a href="{{ route('admin.dashboard') }}">হোম</a></li><li class="breadcrumb-item"><a href="javascript: void(0)">মিডিয়া</a></li><li class="breadcrumb-item" aria-current="page">Widget Settings</li></ul></div>
    <div class="col-md-12"><div class="page-header-title"><h2 class="mb-0">{{ __('Widget Settings') }}</h2></div></div>
</div></div></div>

@include('includes.admin.form-error')
@include('includes.admin.form-success')
@include('includes.admin.flash-message')

<form id="geniusformdata" action="{{ route('widget.settings.update')}}" method="POST" enctype="multipart/form-data">
    {{csrf_field()}}
    <div class="card">
        <div class="card-header"><h5>{{ __('Home Page Widgets') }}</h5></div>
        <div class="card-body">
            <div class="row g-3">
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Feature/Recent/Top News') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="feature_inhome" value="1" {{$data->feature_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Categories') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="category_inhome" value="1" {{$data->category_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Follow Us') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="follow_inhome" value="1" {{$data->follow_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Tags') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="tag_inhome" value="1" {{$data->tag_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Poll') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="poll_inhome" value="1" {{$data->poll_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Calendar') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="calendar_inhome" value="1" {{$data->calendar_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Newsletter') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="newsletter_inhome" value="1" {{$data->newsletter_inhome == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="card">
        <div class="card-header"><h5>{{ __('Category Page Widgets') }}</h5></div>
        <div class="card-body">
            <div class="row g-3">
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Category') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="category_incategory" value="1" {{$data->category_incategory == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Newsletter') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="newsletter_incategory" value="1" {{$data->newsletter_incategory == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Calendar') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="calendar_incategory" value="1" {{$data->calendar_incategory == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="card">
        <div class="card-header"><h5>{{ __('Details Page Widgets') }}</h5></div>
        <div class="card-body">
            <div class="row g-3">
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Category') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="category_indetails" value="1" {{$data->category_indetails == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Newsletter') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="newsletter_indetails" value="1" {{$data->newsletter_indetails == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
                <div class="col-md-6">
                    <div class="d-flex align-items-center justify-content-between p-3 border rounded">
                        <label class="form-label mb-0">{{ __('Calendar') }}</label>
                        <div class="form-check form-switch"><input class="form-check-input" type="checkbox" name="calendar_indetails" value="1" {{$data->calendar_indetails == 1 ? 'checked': ''}}></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="card"><div class="card-body">
        <button class="btn btn-primary" type="submit"><i class="ti ti-device-floppy me-1"></i>{{ __('Update') }}</button>
    </div></div>
</form>
@endsection
