rn-css 1.8.14 → 1.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -0
- package/dist/app.json +4 -0
- package/dist/index.d.ts +3 -1439
- package/dist/index.js +166 -56
- package/dist/src/convertStyle.d.ts +5 -0
- package/dist/src/convertStyle.js +56 -0
- package/dist/src/convertUnits.d.ts +5 -0
- package/dist/src/convertUnits.js +71 -0
- package/dist/src/cssToRN/convert.d.ts +55 -0
- package/dist/src/cssToRN/convert.js +418 -0
- package/dist/src/cssToRN/index.d.ts +8 -0
- package/dist/src/cssToRN/index.js +134 -0
- package/dist/src/cssToRN/maths.d.ts +4 -0
- package/dist/src/cssToRN/maths.js +86 -0
- package/dist/src/cssToRN/mediaQueries.d.ts +7 -0
- package/dist/src/cssToRN/mediaQueries.js +161 -0
- package/dist/src/features.d.ts +34 -0
- package/dist/src/features.js +102 -0
- package/dist/src/generateHash.d.ts +2 -0
- package/dist/src/generateHash.js +8 -0
- package/dist/src/index.d.ts +1805 -0
- package/dist/src/index.js +60 -0
- package/dist/src/polyfill.d.ts +3 -0
- package/dist/src/polyfill.js +23 -0
- package/dist/src/rnToCss.d.ts +3 -0
- package/dist/src/rnToCss.js +8 -0
- package/dist/src/styleComponent.d.ts +45 -0
- package/dist/src/styleComponent.js +163 -0
- package/dist/src/types.d.ts +85 -0
- package/dist/src/types.js +2 -0
- package/dist/src/useTheme.d.ts +18 -0
- package/dist/src/useTheme.js +33 -0
- package/package.json +1 -1
- package/src/cssToRN/index.ts +7 -1
- package/src/features.tsx +15 -1
- package/src/styleComponent.tsx +15 -8
- package/src/types.ts +1 -0
- package/CHANGELOG.md +0 -25
package/README.md
CHANGED
|
@@ -18,6 +18,9 @@ const MyComponent = styled.View`
|
|
|
18
18
|
&:hover {
|
|
19
19
|
background: red;
|
|
20
20
|
}
|
|
21
|
+
&:active {
|
|
22
|
+
background: blue;
|
|
23
|
+
}
|
|
21
24
|
@media (min-width: 600px) {
|
|
22
25
|
border: 1px solid rgb(128, 128, 128);
|
|
23
26
|
}
|
|
@@ -245,6 +248,19 @@ const Hoverable = styled.View`
|
|
|
245
248
|
`
|
|
246
249
|
```
|
|
247
250
|
|
|
251
|
+
### <ins>active:</ins>
|
|
252
|
+
|
|
253
|
+
You can add active with `&:active { <instructions> }`. An element is considered `active` as long as it is focused.
|
|
254
|
+
|
|
255
|
+
```javascript
|
|
256
|
+
const Activable = styled.View`
|
|
257
|
+
background: red;
|
|
258
|
+
&:active {
|
|
259
|
+
background: blue;
|
|
260
|
+
}
|
|
261
|
+
`
|
|
262
|
+
```
|
|
263
|
+
|
|
248
264
|
### <ins>media queries:</ins>
|
|
249
265
|
|
|
250
266
|
You can add media queries with `@media <constraints> { <instructions> }`
|
package/dist/app.json
ADDED