-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[REFACTOR] added logic to manipulate AST to deal with negative values… (
#1120) * [REFACTOR] added logic to manipulate AST to deal with negative values + fixed PR comments * [CHORE] Added changeset * Update .changeset/lemon-ladybugs-float.md Co-authored-by: Monica <molejniczak@atlassian.com> * Update packages/babel-plugin/src/utils/css-builders.tsx Co-authored-by: Monica <molejniczak@atlassian.com> Co-authored-by: Monica <molejniczak@atlassian.com>
- Loading branch information
1 parent
356b120
commit 5e3ad5e
Showing
5 changed files
with
113 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@compiled/babel-plugin': patch | ||
--- | ||
|
||
Fixed bug where negative and positive values were getting evaluated as the same |
Binary file added
BIN
+1.55 KB
.loki/reference/chrome_laptop_css_negative_css_values_Negative_Css_Values.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { styled } from '@compiled/react'; | ||
|
||
export default { | ||
title: 'css/negative css values', | ||
}; | ||
|
||
const gridSize = 8; | ||
|
||
const LayoutRight = styled.aside` | ||
position: relative; | ||
margin-right: -${gridSize * 5}px; | ||
margin-left: ${gridSize * 5}px; | ||
top: -${gridSize}px; | ||
bottom: ${gridSize}px; | ||
left: -6px; | ||
right: 6px; | ||
color: blue; | ||
`; | ||
|
||
export const NegativeCssValues = (): JSX.Element => <LayoutRight>Layout Right</LayoutRight>; |