Wedding Invitation
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

show-all-guestbook.blade.php 1.1KB

12345678910111213141516171819202122232425262728293031
  1. <dialog id="allguestbook" class="modal">
  2. <div class="modal-box w-11/12 max-w-5xl">
  3. <h3 class="text-lg font-bold pb-2">Semua Ucapan</h3>
  4. <div id="scrollableContent" class="max-h-96 overflow-auto">
  5. @foreach ($allguestbooks as $allguestbook)
  6. <p class="font-semibold">{{$allguestbook->name}}</p>
  7. <p>{{$allguestbook->speech}}</p>
  8. <hr class="border-t-1 border-gray-300 my-5 w-full self-center">
  9. @endforeach
  10. </div>
  11. <div class="modal-action">
  12. <form method="dialog">
  13. <button class="btn">Tutup</button>
  14. </form>
  15. </div>
  16. </div>
  17. </dialog>
  18. @push('script')
  19. <script>
  20. document.addEventListener('DOMContentLoaded', function () {
  21. var dialog = document.getElementById('allguestbook');
  22. if (dialog) {
  23. dialog.addEventListener('show', function () {
  24. var scrollableContent = document.getElementById('scrollableContent');
  25. scrollableContent.scrollTop = scrollableContent.scrollHeight;
  26. });
  27. }
  28. });
  29. </script>
  30. @endpush