tech-systems / panes

🎉📱 Create dynamic modals, cards, panes for your applications in few steps. One instance – Thousands solutions. Any framework and free.
https://panejs.com
MIT License
687 stars 40 forks source link

[FEAT] allow hide() to set animate prop #242

Open henryyuuu opened 3 months ago

henryyuuu commented 3 months ago

How to reproduce: step 1. pane.hide() step 2. pane.present({animate: false})

It seems that the pane will present with animate even i call present with animate: false. Is this the correct behavior? Or how can i present a pane without animate when it's hidden?

thanks

roman-rr commented 3 months ago

Thank you @henryyuuu You are right! This is probably because most useful case is

pane.present({animate: false});

pane.destroy({animate: false});

pane.present({animate: false});

Hide function used with transition.

Does animate: false will fix your needs, or you need to using hide() function instead of present/destroy ?

henryyuuu commented 3 months ago

hi @roman-rr, thanks for fast reply, i just want to make sure if this is a bug or there's other public method that i missed. i will use other method instead of hide in my case. Thanks very much.