I am migrating our customer account extension to Preact, and I think I am seeing an anomaly with the “background” attribute and the “base” value which is not taking on the usual white color for this value on other pages.
I tested it specifically with the s-box and s-stack components, but on the other hand I cannot reproduce this behavior with our extension on the checkout pages (payment and thank you page).
Can you please confirm whether this is abnormal behavior or is this value for this attribute supposed to be transparent in a customer account extension?
Here is are the dependencies of my extension’s package.json:
Hello Robin,
Thanks for replying. Here is the code that wasn’t working as I expected:
<s-box padding="base" background="base" border="base" borderRadius="base"> // here is the 'background="base"' that is not working
<s-stack gap="small-200" background="base"> // tried the same here with s-stack, same result, background is transparent instead of white
// some code...
</s-stack>
</s-box>
As you recommended, I wrapped my content inside an s-section component and it worked, thanks a lot for that.
Let me know if the code I shared above is enough for you to reproduce the issue. I tried with minimal content inside of it (if the issue could ever be related to the content), and still got the problem.
thanks for the snippet.
You mentioned that you are migrating to the Preact version. Could you also share the code that you had before that did set the background color?