-
Notifications
You must be signed in to change notification settings - Fork 9
Description
Describe the bug
Hello! First of all, thanks for the awesome work! We're adopting chromatic-e2e this week, and I've really been enjoying it. Anyway, we're having an issue where our shorthand properties seem to be getting broken out into their constituent properties in our Storybook builds (specifically, during the page.evaluate of our Chromatic snapshot step). For example, all: unset:
gets broken out into every-style-that-wasn't-explicitly-set: unset. This is a problem because, for example, all the different ways to address border radius (e.g. border-end-end-radius, etc.), can end up overriding the intended border-radius:
It also seems like some shorthand styles such as padding-block
don't get properly split out into, e.g., padding-block-start if the style isn't actively applied:
I can repro the problem locally and in CI, so it's not something platform-specific. And again, it occurs specifically during the page.evaluate of our Chromatic snapshot step:
To Reproduce
Wellll, I tried to reproduce on a fork. but it didn't do it---which is probably a good thing:

Here's how to not reproduce:
git clone [email protected]:jcamden/chromatic-e2e.gitcd chromatic-e2egit checkout shorthand-css-propertiesyarn installyarn dev:server- (new shell)
yarn build yarn playwright installyarn test:playwrightyarn archive-storybook:playwright(styles are correct)yarn build-archive-storybook:playwrightcd storybook-staticnpx http-server(styles are correct)
As shown in the screenshot, the shorthand properties were preserved in these builds. I'm hoping you might have some insight as to why the shorthand properties are getting transformed during page.evaluate for our app. I really appreciate it!





