cornerstone icon indicating copy to clipboard operation
cornerstone copied to clipboard

Write a Review - empty modal

Open bigmadness opened this issue 1 year ago • 6 comments

empty modal when you open and close more than 1.

https://github.com/bigcommerce/cornerstone/assets/10583985/0d277fd4-a800-4f0b-b9e0-a494d674c9ad

bigmadness avatar May 16 '23 16:05 bigmadness

@BC-krasnoshapka

bigmadness avatar May 17 '23 02:05 bigmadness

In my experience, this problem occurs with any Foundation modal. The content loads properly the first time any modal is opened. Once closed, all content within div.modal-content is removed and not repopulated.

The last version of Cornerstone I worked with, 6.5, did not have this issue.

Aidance-Scientific avatar May 19 '23 14:05 Aidance-Scientific

There is a function called clearContent() in the modal close function that wipes out the html in modal-content. My workaround is to just add content when the modal is opened, but it would be nice to just keep my modal content in a template file.

loganofaz avatar Jun 30 '23 17:06 loganofaz

Interesting, thanks for the hint @loganofaz ! I commented out line 227 in modal.js which seems to have worked for the most part.

onModalClose() {
        $('body').removeClass(bodyActiveClass);

        // this.clearContent();
    }

Unfortunately modals on cart.php continue to clear permanently. There must be a similar function call in a cart page-specific script somewhere.

Aidance-Scientific avatar Jun 30 '23 17:06 Aidance-Scientific

hey, this issue will be fixed by #2368 in the upcoming Cornerstone release.

BC-krasnoshapka avatar Jul 03 '23 09:07 BC-krasnoshapka

That’s Fantastic!

Thank you so much for taking the time to let me know 😊

~ Chris.

From: Volodymyr Krasnoshapka @.> Date: Monday, July 3, 2023 at 5:58 AM To: bigcommerce/cornerstone @.> Cc: Chris Simpson @.>, Manual @.> Subject: Re: [bigcommerce/cornerstone] Write a Review - empty modal (Issue #2359)

hey, this issue will be fixed by #2368https://github.com/bigcommerce/cornerstone/pull/2368 in the upcoming Cornerstone release.

— Reply to this email directly, view it on GitHubhttps://github.com/bigcommerce/cornerstone/issues/2359#issuecomment-1617767627, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ASYYNFGQDURXGSYKDD67Z5LXOKJUDANCNFSM6AAAAAAYD5STBA. You are receiving this because you are subscribed to this thread.Message ID: @.***>

Aidance-Scientific avatar Jul 03 '23 17:07 Aidance-Scientific