vex close button

  • Posts: 17
  • Thank you received: 2
5 years 4 weeks ago #304938

-- url of the page with the problem -- : fa4.ru/
-- HikaShop version -- : 4.0.2
-- Joomla version -- : 3.9.3
-- PHP version -- : 7.2.10
-- Browser(s) name and version -- : chrome

Hi! Please tell me how to add a pop-up button to Close the window VEX

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 81484
  • Thank you received: 13062
  • MODERATOR
5 years 4 weeks ago #304953

Hi,

There is already a close button by default on vew popups:
monosnap.com/file/ppjuFVVYP4dDnyPRq6PSRJda1HbNyT
If you don't see it, it probably means that you have custom CSS to hide it.
Otherwise, it could also be that you didn't set the showCloseButton parameter of vex to 1 when you initialized your vew popups.

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 2
5 years 4 weeks ago #304963

Thank you! That's right, I'm using the vex dialog on frontend, and the default setting is showCloseButton of vex set to 0. Please tell me how to initiate it to 1?

Please Log in or Create an account to join the conversation.

  • Posts: 81484
  • Thank you received: 13062
  • MODERATOR
5 years 4 weeks ago #304967

Hi,

Well, how do you add that vew popup ?

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 2
5 years 3 weeks ago #305007

The pop-up window is called by the plugin "HikaShop Card notification Plugin" method popup, by clicking on the " Buy " button in the product card

Please Log in or Create an account to join the conversation.

  • Posts: 81484
  • Thank you received: 13062
  • MODERATOR
5 years 3 weeks ago #305008

Hi,

Then try adding the code:
vex.defaultOptions.showCloseButton = 1;
after the code:
vex.defaultOptions.className = "vex-theme-default";
in the file plugins/hikashop/cartnotify/cartnotify.php

The following user(s) said Thank You: aron555

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 2
5 years 3 weeks ago #305028

Thanks Nikolas! I understand the principle and read the documentation github.com/HubSpot/vex/blob/29b137d92b18...ex.dialog.coffee#L42 found that correctly you need to specify with DIALOG
vex.dialog.defaultOptions.showCloseButton = 1;
it work!

The following user(s) said Thank You: nicolas

Please Log in or Create an account to join the conversation.

Time to create page: 0.063 seconds
Powered by Kunena Forum