<?php if(!empty($ingredient_categories)): ?>
    <?php $__currentLoopData = $ingredient_categories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $ingredient_category): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
        <div class="col-md-6 m-b-md">
            <div class="border text-left p-sm  bg-muted" style="    box-shadow: 0 0 3px rgb(0 0 0 / 30%);">
                <div class="form-group">
                    <div class="col-sm-12">
                        <input type="text" name="ingredients[<?php echo e($loop->index); ?>][name]"
                               value="<?php echo e($ingredient_category->name); ?>"
                               class="form-control"
                               placeholder="Nume categorie ingrediente (ex. Ingrediente crema)"
                               class="form-control">
                    </div>
                </div>

                <div class="form-group">
                    <div class="col-sm-12">
                        
                        <?php if(isset($ingredient_category->items)): ?>
                            <?php $__currentLoopData = $ingredient_category->items; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $ingredient): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

                                <div class="text- font-bold text-uppercase small m-t-or-not m-b-xs">
                                    <button
                                            data-confirm="Sigur stergeti ingredientul?"
                                            data-url="<?php echo e(route('admin.articles.ingredients.delete', [$article, $loop->parent->index, $loop->index])); ?>"
                                            type="button"
                                            class="btn btn-sm no-padding text-uppercase text-danger pull-right ajax-action-trigger">
                                                    <span class="small">
                                                        <i class="fa fa-times"></i> sterge
                                                    </span>
                                    </button>
                                    Ingredient <?php echo e($loop->iteration); ?>

                                </div>
                                <div class="m-b-or-not border-bottom m-b">
                                    <div class="row no-margins">
                                        <div class="col-md-12 no-padding m-b">






                                            <textarea
                                                    placeholder="ingrediente, separate prin rand nou..."
                                                    class="form-control"
                                                    rows="3"
                                                    name="ingredients[<?php echo e($loop->parent->index); ?>][items][<?php echo e($loop->index); ?>]"><?php echo e($ingredient); ?></textarea>
                                        </div>
                                    </div>
                                </div>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        <?php endif; ?>
                        








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

<div class="<?php echo e(empty($ingredient_categories) ? 'col-md-12' : 'col-md-6'); ?> text-center">
    <button type="button"
            data-url="<?php echo e(route('admin.articles.ingredients.category', $article)); ?>"
            class="btn btn-secondary p-lg  ajax-action-trigger">
        <i class="fa fa-plus-circle fa-5x"></i>
        <div class="h4">
            Adauga categorie cu <b>ingrediente</b>
        </div>
    </button>
</div>

<script>
    $('.ingredients-xhr').xhrAction();
</script>
<?php /**PATH /home/superch1/public_html/resources/views/admin/article/recipe/ingredients.blade.php ENDPATH**/ ?>