Joomla Module Custom Position From X-axis Set To Percentage Changes Back To Px After Every Safe Event - Question | JoomShaper
Black Friday sale is live with flat 50% OFF. Sale ends soon! Grab your deal now!

Joomla Module Custom Position From X-axis Set To Percentage Changes Back To Px After Every Safe Event

Dennis van Duijn

Dennis van Duijn

SP Page Builder 2 years ago

Problem I've succesfully set my Joomla Module to shift a percentage to the left. Every time I save the page, the percentage dropdown type appears to be set back to type px. It's pretty annoying, as every change to the page needs to have a final manual push back to percentage.

Steps to reproduce

  • Make sure to have a Joomla Module
  • Go to Settings
  • Go to Advanced
  • Turn on Enable Custom Position
  • Select position Relative
  • Enter a value > 0 in field From X-axis
  • In the pulldown to the right of the value select type %
  • Save the changes made
  • Change some other setting of the Joomla Module
  • Save the change made
  • Turn back to the pulldown to the right of the value

Expected result

  • The type is still %

Actual result

  • The type is px

Solution

  • If this is a bug, please fix. It would be nice to have a workaround in the meantime though. Like custom CSS. Could this be provided?
0
10 Answers
Pavel
Pavel
Accepted Answer
2 years ago #111547

It would be nice to have a workaround in the meantime though. Like custom CSS. Could this be provided?

Hi Dennis. You should turn off Custom Position and find addon's ID through dev tools. Then use it in such code:

/*Shift to the right*/
#sppb-addon-wrapper-ADDON_ID {
    position: relative !important;
    left: 20% !important;
}
/*Shift to the left*/
#sppb-addon-wrapper-ADDON_ID {
    position: relative !important;
    right: 20% !important;
}
0
Dennis van Duijn
Dennis van Duijn
Accepted Answer
2 years ago #111590

Hi Pavel, thank you for your quick response. Your proposed solution does noet work for me. I disabled Custom Position and added the CSS code as you told, including the correct ADDON_ID and only to shift to left.

This is the custom CSS (exaggerated the shift percentage hoping to see a profound result):

/*Shift to the left*/
#sppb-addon-wrapper-5F3yDTo6QVhWeoxP_Psfo {
    position: relative !important;
    right: 50% !important;
}

This is the link to the page where you can see the result (First turn to mobile view, and see the wrapper with the 360° tour): https://www.helix.okijk.nl/portfolio/erasmus-university-college

0
Mehtaz Afsana Borsha
Mehtaz Afsana Borsha
Accepted Answer
Support Agent 2 years ago #111604

Hi

Thanks for contatcing us. And thanks Pavel for helping him. Dennis you can follow pavels instructions. It may help you.

-Regards.

0
Pavel
Pavel
Accepted Answer
2 years ago #111645

Hi Dennis. I do not see that you have applied this code to the addon. Where did you add this code?

If I add the code in Dev Tools, then everything works well.

0
Pavel
Pavel
Accepted Answer
2 years ago #111647

I found this. It looks like you inserted the code in the addon's Custom CSS field. This is not the right place for such a code. This leads to an incorrect sequence of selectors.

The code in which the addon's ID is used should be added to a more global level - to the Page CSS field (good place but it is not convenient to edit), to the Custom CSS Helix field (I do not recommend) or to the custom.css file (the best place).

0
Pavel
Pavel
Accepted Answer
2 years ago #111648

Just to let you know. When adding the code to the addon's Custom Css field, at the output an addon ID is automatically added to this code.

For clarity, I will add class to addon.

In the source code you can see the entire addon and the place where my-Сlass was added.

In the addon's Custom Css field you can use code for my-Сlass and all its children.

The code for the parental elements of my-Сlass like #sppb-addon-xxxxxxxx & #sppb-addon-wrapper-xxxxxxxx should be added to a more global level but not to addon's Custom Css field.

0
Dennis van Duijn
Dennis van Duijn
Accepted Answer
2 years ago #111657

Hi Pavel,

Thank you so much for your explanation! I added the CSS to the Page CSS field, which works best for me. Of course I hope that the bug of changing px type to % type eventually will be solved, but in the meantime the workaround is fine.

Kind regards,

Dennis

0
Pavel
Pavel
Accepted Answer
2 years ago #111678

Hi Dennis. I was glad to help.

Nevertheless, I am not an employee of Joomshaper. Therefore, you need to make sure that the problem is added to the bug list. To do this, remove Accepted Answer label from my answer and wait for comments from support employees.

0
Dennis van Duijn
Dennis van Duijn
Accepted Answer
2 years ago #111683

Thank you, removed the Accepted Answer. Hope the original issue will be picked up as a bug report.

0
Mehtaz Afsana Borsha
Mehtaz Afsana Borsha
Accepted Answer
Support Agent 2 years ago #111754

Hi Pavel and Dennis,

Thanks for helping. And Dennis thanks for your opinions. I will add it in our bug list so that our team will take care of it.

-Regards.

0