You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes it is convenient to mix styled components and declarative components. It is possible to do it by adding a `Box` suffix to `styled.tag`. Using `styled.buttonBox` instead of `styled.button` let you use any props utilities on the component:
134
+
Sometimes it is convenient to mix styled components and utility props. It is possible to do it by adding a `Box` suffix to `styled.tag`. Using `styled.buttonBox` instead of `styled.button` let you use any props utilities on the component:
125
135
126
136
```js
127
137
importstyledfrom'@xstyled/...'
@@ -139,8 +149,58 @@ function App() {
139
149
}
140
150
```
141
151
152
+
It is possible to explicitly add utility props by using `system` or any utility as interpolation:
## Use utility props to apply style in styled components
177
+
178
+
Some utilities like `ring` can't be used in styled components. The `apply` method available on each utility or utilities family allows you to apply style directly on your styled components:
**Media queries are automatically transformed by xstyled, these utilities are deprecated and will be removed in next major version. Please use `@media` instead.**
203
+
144
204
### breakpoints
145
205
146
206
`breakpoints` lets you write style for each breakpoint.
0 commit comments