1- <div class =" relative mt-2 pt-2 border-t border-gray-200 dark:border-gray-700 flex items-center gap-x-1 flex-wrap" >
1+ <div class =" comm: relative comm: mt-2 comm: pt-2 comm: border-t comm: border-gray-200 comm: dark:border-gray-700 comm: flex comm: items-center comm: gap-x-1 comm: flex-wrap" >
22 {{-- Inline buttons for existing reactions --}}
33 @foreach ($this -> reactionSummary as $reactionData )
44 <span wire:key =" inline-reaction-button-{{ $reactionData [' reaction' ] } } -{{ $comment -> getId () } }" >
55 <button
66 x-cloak
77 wire:click =" handleReactionToggle('{{ $reactionData [' reaction' ] } } ')"
88 type =" button"
9- class =" inline-flex items-center justify-center gap-1 rounded-full border px-2 h-8 text-sm font-medium transition focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:opacity-50 disabled:cursor-not-allowed
9+ class =" comm: inline-flex comm: items-center comm: justify-center comm: gap-1 comm: rounded-full comm: border comm: px-2 comm: h-8 comm: text-sm comm: font-medium comm: transition comm: focus:outline-none comm: focus:ring-2 comm: focus:ring-offset-2 comm: disabled:opacity-50 comm: disabled:cursor-not-allowed
1010 {{ $reactionData [' reacted_by_current_user' ]
11- ? ' bg-primary-100 dark:bg-primary -800 border-primary -300 dark:border-primary -600 text-primary -700 dark:text-primary -200 hover:bg-primary -200 dark:hover:bg-primary -600'
12- : ' bg-white dark:bg-gray-900 border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600' } }"
11+ ? ' comm: bg-gray-50 comm: dark:bg-gray -800 comm: border-gray -300 comm: dark:border-gray -600 comm: text-gray -700 comm: dark:text-gray -200 comm: hover:bg-gray -200 comm: dark:hover:bg-gray -600'
12+ : ' comm: bg-white comm: dark:bg-gray-900 comm: border-gray-300 comm: dark:border-gray-600 comm: text-gray-700 comm: dark:text-gray-200 comm: hover:bg-gray-100 comm: dark:hover:bg-gray-600' } }"
1313 title =" {{ $reactionData [' reaction' ] } }"
1414
1515 >
@@ -20,16 +20,16 @@ class="inline-flex items-center justify-center gap-1 rounded-full border px-2 h-
2020 @endforeach
2121
2222 {{-- Add Reaction Button --}}
23- <div class =" relative" x-data =" { open: false }" wire:ignore.self >
23+ <div class =" comm: relative" x-data =" { open: false }" wire:ignore.self >
2424 <button
2525 x-on:click =" open = !open"
2626 type =" button"
2727 @disabled (! auth ()-> check () )
28- class =" inline-flex items-center justify-center gap-1 rounded-full border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-900 w-8 h-8 text-sm font-medium text-gray-700 dark:text-gray-200 transition hover:bg-gray-100 dark:hover:bg-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:opacity-50 disabled:cursor-not-allowed"
28+ class =" comm: inline-flex comm: items-center comm: justify-center comm: gap-1 comm: rounded-full comm: border comm: border-gray-300 comm: dark:border-gray-600 comm: bg-white comm: dark:bg-gray-900 comm: w-8 comm: h-8 comm: text-sm comm: font-medium comm: text-gray-700 comm: dark:text-gray-200 comm: transition comm: hover:bg-gray-100 comm: dark:hover:bg-gray-700 comm: focus:outline-none comm: focus:ring-2 comm: focus:ring-offset-2 comm: disabled:opacity-50 comm: disabled:cursor-not-allowed"
2929 title =" Add Reaction"
3030 wire:key =" add-reaction-button-{{ $comment -> getId () } }"
3131 >
32- <svg xmlns =" http://www.w3.org/2000/svg" class =" h-4 w-4" fill =" none" viewBox =" 0 0 24 24" stroke =" currentColor" stroke-width =" 2" >
32+ <svg xmlns =" http://www.w3.org/2000/svg" class =" comm: h-4 comm: w-4" fill =" none" viewBox =" 0 0 24 24" stroke =" currentColor" stroke-width =" 2" >
3333 <path stroke-linecap =" round" stroke-linejoin =" round" d =" M14.828 14.828a4 4 0 01-5.656 0M9 10h.01M15 10h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
3434 </svg >
3535 </button >
@@ -39,7 +39,8 @@ class="inline-flex items-center justify-center gap-1 rounded-full border border-
3939 x-show =" open"
4040 x-cloak
4141 x-on:click.away =" open = false"
42- class =" absolute bottom-full mb-2 z-10 bg-white dark:bg-gray-800 border border-gray-300 dark:border-gray-600 rounded-lg shadow-lg p-2 flex flex-wrap gap-1 w-max max-w-xs"
42+ class =" comm:absolute comm:bottom-full comm:mb-2 comm:z-10 comm:bg-white comm:dark:bg-gray-800 comm:border comm:border-gray-300 comm:dark:border-gray-600 comm:rounded-lg comm:shadow-lg comm:p-2 comm:flex-wrap comm:gap-1 comm:w-max comm:max-w-xs"
43+ :class =" { 'comm:hidden': ! open, 'comm:flex': open }"
4344 >
4445 @foreach ($allowedReactions as $reactionEmoji )
4546 @php
@@ -51,10 +52,10 @@ class="absolute bottom-full mb-2 z-10 bg-white dark:bg-gray-800 border border-gr
5152 x-on:click =" open = false"
5253 type =" button"
5354 @disabled (! auth ()-> check () )
54- class =" inline-flex items-center justify-center gap-1 rounded-full border w-8 h-8 text-sm font-medium transition focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:opacity-50 disabled:cursor-not-allowed
55+ class =" comm: inline-flex comm: items-center comm: justify-center comm: gap-1 comm: rounded-full comm: w-8 comm: h-8 comm: text-sm comm: font-medium comm: transition comm: focus:outline-none comm: focus:ring-2 comm: focus:ring-offset-2 comm: disabled:opacity-50 comm: disabled:cursor-not-allowed
5556 {{ $reactionData [' reacted_by_current_user' ]
56- ? ' bg-primary-100 dark:bg-primary-800 border-primary-300 dark:border-primary-600 text-primary -700 dark:text-primary -200 hover:bg-primary -200 dark:hover:bg-primary -600'
57- : ' bg-white dark:bg-gray-900 border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600' } }"
57+ ? ' comm: text-gray -700 comm: dark:text-gray -200 comm: hover:bg-gray -200 comm: dark:hover:bg-gray -600'
58+ : ' comm: text-gray-700 comm: dark:text-gray-200 comm: hover:bg-gray-100 comm: dark:hover:bg-gray-600' } }"
5859 title =" {{ $reactionEmoji } }"
5960 wire:key =" popup-reaction-button-{{ $reactionEmoji } } -{{ $comment -> getId () } }"
6061 >
@@ -69,7 +70,7 @@ class="inline-flex items-center justify-center gap-1 rounded-full border w-8 h-8
6970 @if (! in_array ($reactionEmoji , $allowedReactions ) && $data [' count' ] > 0 )
7071 <span
7172 wire:key =" reaction-extra-{{ $reactionEmoji } } -{{ $comment -> getId () } }"
72- class =" inline-flex items-center justify-center gap-1 rounded-full border border-gray-300 dark:border-gray-600 bg-gray-100 dark:bg-gray-800 px-2 h-8 text-sm font-medium text-gray-600 dark:text-gray-300"
73+ class =" comm: inline-flex comm: items-center comm: justify-center comm: gap-1 comm: rounded-full comm: border comm: border-gray-300 comm: dark:border-gray-600 comm: bg-gray-100 comm: dark:bg-gray-800 comm: px-2 comm: h-8 comm: text-sm comm: font-medium comm: text-gray-600 comm: dark:text-gray-300"
7374 title =" {{ $reactionEmoji } }"
7475 >
7576 <span >{{ $reactionEmoji } } </span >
0 commit comments