<?php if (isset($component)) { $__componentOriginalb998c89882eab8e1df2af93927d4d429 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalb998c89882eab8e1df2af93927d4d429 = $attributes; } ?>
<?php $component = App\View\Components\Dashboard\Layout::resolve(['title' => __('dashboard.edit') . $slider->title] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('dashboard.layout'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\App\View\Components\Dashboard\Layout::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes([]); ?>

    <!-- Page Header -->
    <?php if (isset($component)) { $__componentOriginalc4b5621f8181a8c32b7ca121a30adcc7 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalc4b5621f8181a8c32b7ca121a30adcc7 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.dashboard.partials.page-header','data' => ['header' => __('dashboard.edit') . $slider->title,'labelUrl' => route('dashboard.sliders.index'),'label' => __('dashboard.sliders')]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('dashboard.partials.page-header'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['header' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(__('dashboard.edit') . $slider->title),'label_url' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(route('dashboard.sliders.index')),'label' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(__('dashboard.sliders'))]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalc4b5621f8181a8c32b7ca121a30adcc7)): ?>
<?php $attributes = $__attributesOriginalc4b5621f8181a8c32b7ca121a30adcc7; ?>
<?php unset($__attributesOriginalc4b5621f8181a8c32b7ca121a30adcc7); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalc4b5621f8181a8c32b7ca121a30adcc7)): ?>
<?php $component = $__componentOriginalc4b5621f8181a8c32b7ca121a30adcc7; ?>
<?php unset($__componentOriginalc4b5621f8181a8c32b7ca121a30adcc7); ?>
<?php endif; ?>
    <!-- End Page Header -->


    <!-- Row-->
    <div class="row">
        <div class="col-sm-12 col-xl-12 col-lg-12">
            <div class="card custom-card overflow-hidden">
                <div class="card-header">
                    <h4 class="card-title"><?php echo e(__('dashboard.edit') . $slider->title); ?></h4>
                </div>

                <div class="card-body">

                    <form action="<?php echo e(route('dashboard.sliders.update', [$slider->id])); ?>" method="POST"
                        enctype="multipart/form-data">
                        <?php echo csrf_field(); ?>
                        <?php echo method_field('PATCH'); ?>
                        <div class="row">

                            <?php if (isset($component)) { $__componentOriginalb93ecfbbc66c41ea18856039222be9d3 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.dashboard.multilingual-input','data' => ['name' => 'title','type' => 'text','required' => true,'model' => $slider]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('dashboard.multilingual-input'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['name' => 'title','type' => 'text','required' => true,'model' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($slider)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $attributes = $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $component = $__componentOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>
                            <div class="form-group col-md-2">
                                <label class=""><?php echo e(__('dashboard.order')); ?></label>
                                <input class="form-control" name="order" type="number" value="<?php echo e($slider->order); ?>"
                                    placeholder="<?php echo e(__('dashboard.order')); ?>">
                            </div>

                            <?php if (isset($component)) { $__componentOriginalb93ecfbbc66c41ea18856039222be9d3 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.dashboard.multilingual-input','data' => ['name' => 'title2','type' => 'text','model' => $slider]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('dashboard.multilingual-input'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['name' => 'title2','type' => 'text','model' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($slider)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $attributes = $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $component = $__componentOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>

                            <div class="form-group col-md-4 mb-3">
                                <label for="type"><?php echo e(__('dashboard.type')); ?></label>
                                <select name="type" class="form-control">
                                    <option value=""><?php echo e(__('dashboard.choose_type')); ?></option>
                                    <?php $__currentLoopData = App\Models\Slider::getTypeSelect(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $label): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <option value="<?php echo e($key); ?>" <?php if(old('type', $slider->type ?? '') == $key): echo 'selected'; endif; ?>>
                                            <?php echo e($label); ?>

                                        </option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </select>
                            </div>

                            <div class="form-group col-md-4 mb-3">
                                <label for="language"><?php echo e(__('dashboard.language')); ?></label>
                                <select name="language" class="form-control">
                                    <?php $__currentLoopData = App\Models\Slider::getLanguageSelect(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $label): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <option value="<?php echo e($key); ?>" <?php if(old('language', $slider->language ?? 'all') == $key): echo 'selected'; endif; ?>>
                                            <?php echo e($label); ?>

                                        </option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </select>
                            </div>

                            <div class="form-group col-md-6">
                                <label><?php echo e(__('dashboard.desktop_image')); ?> (1920px * 1080px max 2mb)</label>
                                <input type="file" class="form-control" name="image" accept="image/*">
                            </div>

                            <div class="form-group col-md-6">
                                <label><?php echo e(__('dashboard.mobile_image')); ?> (768px * 1024px max 1mb) <small
                                        class="text-muted">(<?php echo e(__('dashboard.optional')); ?>)</small></label>
                                <input type="file" class="form-control" name="mobile_image" accept="image/*">
                            </div>

                            <div class="form-group col-md-6">
                                <label for=""><?php echo e(__('dashboard.desktop_image')); ?></label>
                                <img src="<?php echo e($slider->image_path); ?>" width="250" class="img-thumbnail">
                            </div>

                            <div class="form-group col-md-6">
                                <label for=""><?php echo e(__('dashboard.mobile_image')); ?></label>
                                <?php if($slider->mobile_image): ?>
                                    <img src="<?php echo e($slider->mobile_image_path); ?>" width="250" class="img-thumbnail">
                                <?php else: ?>
                                    <div class="text-muted"><?php echo e(__('dashboard.no_mobile_image')); ?></div>
                                <?php endif; ?>
                            </div>

                            <div class="form-group col-md-6">
                                <label class=""><?php echo e(__('dashboard.alt_image')); ?>

                                    (<?php echo e(__('dashboard.desktop')); ?>)</label>
                                <input class="form-control" name="alt_image" type="text"
                                    placeholder="<?php echo e(__('dashboard.alt_image')); ?>" value="<?php echo e($slider->alt_image); ?>">
                            </div>

                            <div class="form-group col-md-6">
                                <label class=""><?php echo e(__('dashboard.alt_image')); ?> (<?php echo e(__('dashboard.mobile')); ?>)
                                    <small class="text-muted">(<?php echo e(__('dashboard.optional')); ?>)</small></label>
                                <input class="form-control" name="alt_mobile_image" type="text"
                                    placeholder="<?php echo e(__('dashboard.alt_mobile_image')); ?>"
                                    value="<?php echo e($slider->alt_mobile_image); ?>">
                            </div>


                            <!-- Multilingual Long Description -->
                            <?php if (isset($component)) { $__componentOriginalb93ecfbbc66c41ea18856039222be9d3 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.dashboard.multilingual-input','data' => ['name' => 'text','type' => 'editor','rows' => '10','model' => $slider]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('dashboard.multilingual-input'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['name' => 'text','type' => 'editor','rows' => '10','model' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($slider)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $attributes = $__attributesOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__attributesOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3)): ?>
<?php $component = $__componentOriginalb93ecfbbc66c41ea18856039222be9d3; ?>
<?php unset($__componentOriginalb93ecfbbc66c41ea18856039222be9d3); ?>
<?php endif; ?>

                            <div class="form-group col-md-4 mt-3 mb-3">
                                <div class="d-flex flex-wrap gap-2">
                                    <h5 class="font-size-14 mb-3"><?php echo e(__('dashboard.publish/unpublish')); ?> </h5>
                                    <input type="checkbox" id="switch1" switch="none" value="1" name="status"
                                        <?php if(old('status', $slider->status)): echo 'checked'; endif; ?> />
                                    <label for="switch1" data-on-label="<?php echo e(__('dashboard.yes')); ?>"
                                        data-off-label="<?php echo e(__('dashboard.no')); ?>"></label>
                                </div>
                            </div>

                            <div class="form-group col-md-12">
                                <button type="submit" class="btn btn-success"><i class="icon-note"></i>
                                    <?php echo e(__('dashboard.update')); ?> </button>
                                <a href="<?php echo e(route('dashboard.sliders.index')); ?>"><button type="button"
                                        class="btn btn-danger mr-1"><i class="icon-trash"></i>
                                        <?php echo e(__('dashboard.cancel')); ?></button></a>
                            </div>

                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
    <!-- End Row -->




 <?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalb998c89882eab8e1df2af93927d4d429)): ?>
<?php $attributes = $__attributesOriginalb998c89882eab8e1df2af93927d4d429; ?>
<?php unset($__attributesOriginalb998c89882eab8e1df2af93927d4d429); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalb998c89882eab8e1df2af93927d4d429)): ?>
<?php $component = $__componentOriginalb998c89882eab8e1df2af93927d4d429; ?>
<?php unset($__componentOriginalb998c89882eab8e1df2af93927d4d429); ?>
<?php endif; ?>
<?php /**PATH /home/egypetoo/public_html/resources/views/Dashboard/Sliders/edit.blade.php ENDPATH**/ ?>