-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Labels
lang:css/scss/lessIssues affecting CSS, Less or SCSSIssues affecting CSS, Less or SCSSlocked-due-to-inactivityPlease open a new issue and fill out the template instead of commenting.Please open a new issue and fill out the template instead of commenting.
Description
Negative values in e.g. CSS backgrounds seem to cause some weird behaviour with the wrapping. Are they perhaps ignored?
Prettier 1.13.2
Playground link
--parser cssInput:
.this-will-not-wrap {
background: transparent url(/long/path/to/dummy-image.svg) -1000px center no-repeat;
}
.this-will-wrap-correctly {
background: transparent url(/long/path/to/dummy-image.svg) 1000px center no-repeat;
}
.this-will-also-wrap-but-incorrectly {
background: transparent url(/even/longer/path/to/dummy-image.svg) -1000px center no-repeat;
}Output:
.this-will-not-wrap {
background: transparent url(/long/path/to/dummy-image.svg) -1000px center no-repeat;
}
.this-will-wrap-correctly {
background: transparent url(/long/path/to/dummy-image.svg) 1000px center
no-repeat;
}
.this-will-also-wrap-but-incorrectly {
background: transparent url(/even/longer/path/to/dummy-image.svg) -1000px center
no-repeat;
}Expected behavior:
.this-will-not-wrap {
background: transparent url(/long/path/to/dummy-image.svg) -1000px center
no-repeat;
}
.this-will-wrap {
background: transparent url(/long/path/to/dummy-image.svg) 1000px center
no-repeat;
}
.this-will-also-wrap-but-incorrectly {
background: transparent url(/even/longer/path/to/dummy-image.svg) -1000px
center no-repeat;
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
lang:css/scss/lessIssues affecting CSS, Less or SCSSIssues affecting CSS, Less or SCSSlocked-due-to-inactivityPlease open a new issue and fill out the template instead of commenting.Please open a new issue and fill out the template instead of commenting.