@vitus-labs/connector-styler 2.0.0-alpha.8 → 2.0.0-beta.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 +52 -0
- package/lib/index.d.ts +4 -3
- package/lib/index.js +2 -2
- package/package.json +9 -7
package/README.md
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# @vitus-labs/connector-styler
|
|
2
|
+
|
|
3
|
+
CSS-in-JS connector for `@vitus-labs/styler` — the recommended connector for web applications.
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/@vitus-labs/connector-styler)
|
|
6
|
+
[](https://github.com/vitus-labs/ui-system/blob/main/LICENSE)
|
|
7
|
+
|
|
8
|
+
This package re-exports `css`, `styled`, `keyframes`, `createGlobalStyle`, `useTheme`, and `ThemeProvider` from `@vitus-labs/styler` in the shape expected by `@vitus-labs/core`'s `init()` function.
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
npm install @vitus-labs/connector-styler @vitus-labs/styler
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Usage
|
|
17
|
+
|
|
18
|
+
```tsx
|
|
19
|
+
import { init } from '@vitus-labs/core'
|
|
20
|
+
import connector from '@vitus-labs/connector-styler'
|
|
21
|
+
|
|
22
|
+
init({
|
|
23
|
+
...connector,
|
|
24
|
+
component: 'div',
|
|
25
|
+
textComponent: 'span',
|
|
26
|
+
})
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Exports
|
|
30
|
+
|
|
31
|
+
| Export | Source |
|
|
32
|
+
| ------ | ------ |
|
|
33
|
+
| `css` | `@vitus-labs/styler` |
|
|
34
|
+
| `styled` | `@vitus-labs/styler` |
|
|
35
|
+
| `keyframes` | `@vitus-labs/styler` |
|
|
36
|
+
| `createGlobalStyle` | `@vitus-labs/styler` |
|
|
37
|
+
| `useTheme` | `@vitus-labs/styler` |
|
|
38
|
+
| `useCSS` | `@vitus-labs/styler` |
|
|
39
|
+
| `provider` | `ThemeProvider` from `@vitus-labs/styler` |
|
|
40
|
+
|
|
41
|
+
The default export spreads all of the above for convenient use with `init()`.
|
|
42
|
+
|
|
43
|
+
## Peer Dependencies
|
|
44
|
+
|
|
45
|
+
| Package | Version |
|
|
46
|
+
| ------- | ------- |
|
|
47
|
+
| @vitus-labs/styler | * |
|
|
48
|
+
| react | >= 19 |
|
|
49
|
+
|
|
50
|
+
## License
|
|
51
|
+
|
|
52
|
+
MIT
|
package/lib/index.d.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import
|
|
1
|
+
import * as _vitus_labs_styler0 from "@vitus-labs/styler";
|
|
2
|
+
import { createGlobalStyle, css, keyframes, styled, useCSS, useTheme } from "@vitus-labs/styler";
|
|
2
3
|
import * as react from "react";
|
|
3
4
|
|
|
4
5
|
//#region src/index.d.ts
|
|
5
6
|
declare const provider: react.FC<{
|
|
6
|
-
theme: Record<string, unknown>;
|
|
7
|
+
theme: _vitus_labs_styler0.DefaultTheme & Record<string, unknown>;
|
|
7
8
|
children: react.ReactNode;
|
|
8
9
|
}>;
|
|
9
10
|
//#endregion
|
|
10
|
-
export { createGlobalStyle, css, keyframes, provider, styled, useTheme };
|
|
11
|
+
export { createGlobalStyle, css, keyframes, provider, styled, useCSS, useTheme };
|
|
11
12
|
//# sourceMappingURL=index2.d.ts.map
|
package/lib/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ThemeProvider, createGlobalStyle, css, keyframes, styled, useTheme } from "@vitus-labs/styler";
|
|
1
|
+
import { ThemeProvider, createGlobalStyle, css, keyframes, styled, useCSS, useTheme } from "@vitus-labs/styler";
|
|
2
2
|
|
|
3
3
|
//#region src/index.ts
|
|
4
4
|
const provider = ThemeProvider;
|
|
5
5
|
|
|
6
6
|
//#endregion
|
|
7
|
-
export { createGlobalStyle, css, keyframes, provider, styled, useTheme };
|
|
7
|
+
export { createGlobalStyle, css, keyframes, provider, styled, useCSS, useTheme };
|
|
8
8
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vitus-labs/connector-styler",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-beta.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Vit Bokisch <vit@bokisch.cz>",
|
|
6
6
|
"maintainers": [
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
"types": "./lib/index.d.ts"
|
|
15
15
|
},
|
|
16
16
|
"types": "./lib/index.d.ts",
|
|
17
|
+
"main": "./lib/index.js",
|
|
17
18
|
"files": [
|
|
18
19
|
"lib",
|
|
19
20
|
"!lib/**/*.map",
|
|
@@ -46,16 +47,17 @@
|
|
|
46
47
|
"build": "bun run vl_rolldown_build",
|
|
47
48
|
"build:watch": "bun run vl_rolldown_build-watch",
|
|
48
49
|
"lint": "biome check src/",
|
|
49
|
-
"typecheck": "tsc --noEmit"
|
|
50
|
+
"typecheck": "tsc --noEmit",
|
|
51
|
+
"version": "node ../../scripts/sync-peer-deps.mjs"
|
|
50
52
|
},
|
|
51
53
|
"peerDependencies": {
|
|
52
|
-
"@vitus-labs/styler": "
|
|
54
|
+
"@vitus-labs/styler": "2.0.0-alpha.27",
|
|
53
55
|
"react": ">= 19"
|
|
54
56
|
},
|
|
55
57
|
"devDependencies": {
|
|
56
|
-
"@vitus-labs/styler": "2.0.0-
|
|
57
|
-
"@vitus-labs/tools-rolldown": "
|
|
58
|
-
"@vitus-labs/tools-typescript": "
|
|
58
|
+
"@vitus-labs/styler": "2.0.0-beta.0",
|
|
59
|
+
"@vitus-labs/tools-rolldown": "1.10.0",
|
|
60
|
+
"@vitus-labs/tools-typescript": "1.10.0"
|
|
59
61
|
},
|
|
60
|
-
"gitHead": "
|
|
62
|
+
"gitHead": "dd8b9f356086ecd8bfb69c87fcad1e8bfa9ab1f4"
|
|
61
63
|
}
|