<div>
    <!-- Modal -->
    <div wire:ignore.self class="modal fade" data-bs-backdrop="static" id="selectDiscount" tabindex="-1"
        aria-labelledby="selectDiscountLabel" aria-hidden="true" data-bs-keyboard="false">
        <div class="modal-dialog modal-dialog-centered">
            <div class="modal-content">
                <div class="modal-header">
                    <h5 class="modal-title" id="selectDiscountLabel"><?php echo e($title); ?></h5>
                </div>
                <div class="form-check">
                    <div class="modal-body">
                        <!--[if BLOCK]><![endif]--><?php $__empty_1 = true; $__currentLoopData = $dataDisc; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                            <div class="card me-3 mt-2">
                                <div <?php if($selectedPromo == $data['no']): ?> class="card-body text-white bg-primary rounded-2" <?php else: ?> class="card-body" <?php endif; ?>>
                                    <div class="text-center">
                                        <input class="form-check-input" type="radio" name="promo"
                                        value="<?php echo e($data['no']); ?>" id="promo<?php echo e($loop->index); ?>"
                                        wire:model.live="selectedPromo">
                                    <label for="promo<?php echo e($loop->index); ?>"
                                        class="form-check-label"><?php echo e($data['name']); ?></label>
                                    </div>
                                </div>
                            </div>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                            <p>No data available.</p>
                        <?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
                    </div>
                </div>

                <div class="modal-footer">
                    <button type="button" class="custom-button1" wire:keydown.window.shift.l="<?php echo e($button); ?>" wire:click="<?php echo e($button); ?>"
                        >Next</button>
                    <!--[if BLOCK]><![endif]--><?php if($button == 'saveValue'): ?>
                    <button type="button" class="custom-button1" wire:click="skipDisc"
                        >Skip</button>
                    <?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    Livewire.on('closeModalDisc', () => {
        $('#selectDiscount').modal('hide');
    });
    Livewire.on('openTheModal', () => {
        setTimeout(() => {
            window.Livewire.find('<?php echo e($_instance->getId()); ?>').modalDiscOpen();
            var firstRadioButton = document.querySelector('input[type="radio"][name="promo"]');
            if (firstRadioButton) {
                firstRadioButton.focus();
            }
        }, 500); 
    });
</script>
<?php /**PATH C:\laragon\www\Posprorycroft\resources\views/livewire/cashier/select-discount.blade.php ENDPATH**/ ?>