Custom CSS For Section Doesn'work As Expected - Question | JoomShaper
SP Page Builder 6 is Here! Learn More →

Custom CSS For Section Doesn'work As Expected

AM

Anton Majoroff

SP Page Builder 3 months ago

Hi. CSS for sections and columns doesn't work the same way for elements. If I add CCS for some section like: .sppb-addon-text In the page code it adds like: #trulala.sppb-addon-text that is, without a space after the section identifier, so the CSS does not apply.

The same thing is with CSS for columns.

Please fix it!

0
19 Answers
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #198550

Hi,

Thanks for the details I was searching for. I missunderstood about the section CSS. However, I have got the issue now and reported to the team already. Thanks again for finding out the bug and reporting it back with clear screenshots.

I have checked and found the issue as follows:

https://share.cleanshot.com/pjLR1BZ6

https://share.cleanshot.com/ZCFL5s5K

https://share.cleanshot.com/vxv2fxQx

Wish you good luck:)

0
AM
Anton Majoroff
Accepted Answer
3 months ago #198552

Thank you, Rashida, I hope they will fix it as soon as possible.

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #198556

You are always welcome:)

I hope so too...

Have a nice day!

0
AM
Anton Majoroff
Accepted Answer
3 months ago #199226

Hi! Please remind the team about this bug. I see that the last patch 5.7.1 didn't fix it unforunately.

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #199260

Hello,

The version was already on testing phase, so it doesn't considered. I will knock my team. Thanks for the reminder.

Have a nice day!

0
AM
Anton Majoroff
Accepted Answer
3 months ago #199262

I'm sure it can be done in a few minutes and it will make the creation process easier.

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #199355

I understand...

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #198394

Hi there!

Sorry to hear that.

Where are you facing this issue? May I have access to check that?

Best regards,

0
AM
Anton Majoroff
Accepted Answer
3 months ago #198424

Hi, did you get it? ID of the section or column is incorrectly added to the CSS selector: no space is added after the identifier. You can check and verify this on any site.

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 3 months ago #198445

Hello,

I think so.

I have already tried on my local with a random section ID and it works fine.

https://share.cleanshot.com/c3rXJXhZ

That's why asking for more details. Where did you put the custom CSS?

Best regards,

0
AM
Anton Majoroff
Accepted Answer
3 months ago #198454

You didn't read my first post carefully. The problem is with the custom CSS for sections and columns, not for elements. Please try to add any CSS for some section/column custom CSS text area and check this issue. It doesn't work as expected because the space after ID is missing in output CSS code.

0
AM
Anton Majoroff
Accepted Answer
3 months ago #198473

Example.

Where Custom CSS is added: https://disk.yandex.ru/i/g2V5St0EFAl3zg

The output: https://disk.yandex.ru/i/LhAfZYgkUZ4ezw

You can see that there is no space between ID of the section and the first selector in the rule. But it works here because the ID and the first selector are the same. If we use any another selector as first for custom CSS rule, this rule doesn't work because the space is missing.

0
AM
Anton Majoroff
Accepted Answer
3 months ago #198547

Did you catch it? Will you fix this bug?

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 2 months ago #199975

Hi,

I got response on this matter as follows:

"In the Custom CSS field of a section, if you intend to directly reference the section's ID, you must use the specific #addonId. image.png

CSS written in this field is scoped to the section itself, so selectors are applied without needing additional spacing or context for the same level. However, if you need to target nested elements within that section, you should use the format #addonId .selector to ensure proper specificity and targeting."

Best regards,

0
AM
Anton Majoroff
Accepted Answer
2 months ago #199984

I've tried to insert any CSS selector in some section Custom CSS and these CSS haven't being applied in this section for the reason that had been mentioned many times, is this how it should work???

0
AM
Anton Majoroff
Accepted Answer
2 months ago #199978

Rashida, they haven't looked into the problem. Added selectors without any context for the same level have to be applied, but they don't because the CSS code is compiled without the required space after the section ID. The section/column custom CSS doesn't work as the addon costum CSS! It's very strange that I have to repeat this again, especially since you checked it yourself and made sure that the option doesn't work as expected.

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 2 months ago #200061

Hi,

Let me clear. Please check the screenshot: https://share.cleanshot.com/yYgM5g9g

Did you try css following this rule?

#addonId .sppb-addon-text-block{
  color: red;
}

Please add #addonId at the begining.

Best regards

0
AM
Anton Majoroff
Accepted Answer
2 months ago #200083

UPD: I have tried using "#addonId", it works, but how will other users know that they need to use it? Why can't this feature work like for addons?

0
Rashida Rahman
Rashida Rahman
Accepted Answer
Support Agent 2 months ago #200686

Hi,

Glad that it work anyway. However, I will request for documentation update including this information.

Why can't this feature work like for addons?

Not sure! Just got that answer: if you need to target nested elements within that section, you should use the format #addonId .selector

Thanks!

0