primefaces / primevue-tailwind

PrimeVue Components Styled with Tailwind CSS
https://tailwind.primevue.org
MIT License
627 stars 76 forks source link

Popover arrow renders on the wrong side #341

Closed benkissi closed 2 weeks ago

benkissi commented 1 month ago

The popover component https://tailwind.primevue.org/popover/ renders the arrow on the wrong side. I thought it was something I did wrong and tried it on your documentation example and the behaviour is the same.

I moved the button in the example to the far right and popover rendered the arrow on the left

https://prnt.sc/iSaPW3nCwQGy

Screenshot 2024-10-29 at 9 44 49 PM
tugcekucukoglu commented 2 weeks ago

Cannot replicate the issue. If you think the problem still persists, please reopen this issue with a reproducer link.

iduchamp commented 1 week ago

I have the same problem

for fix need to add this code into popover.css

.p-popover:after, .p-popover:before {
     left: calc(1.25rem + var(--p-popover-arrow-left))
}

cause: on original primevue u have this rule:

.p-popover:after, .p-popover:before {
     ......
     left: calc(var(--p-popover-arrow-offset) + var(--p-popover-arrow-left));
     .....
}     

and tailwind version css have just

.p-popover:after, .p-popover:before {
      .....
      left: 1.25rem;
      .......
}    
benkissi commented 1 week ago

Thanks