@moises.ai/design-system 0.0.1 → 0.0.2
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 +17 -16
- package/dist/icons.js +1 -0
- package/package.json +14 -2
package/Readme.md
CHANGED
|
@@ -12,8 +12,6 @@ npm install @moises.ai/design-system
|
|
|
12
12
|
|
|
13
13
|
```jsx
|
|
14
14
|
import { Theme, Button, Text } from '@moises.ai/design-system';
|
|
15
|
-
// Import the styles directly from @moises.ai/design-system
|
|
16
|
-
import '@moises.ai/design-system/styles.css';
|
|
17
15
|
|
|
18
16
|
function App() {
|
|
19
17
|
return (
|
|
@@ -25,19 +23,22 @@ function App() {
|
|
|
25
23
|
}
|
|
26
24
|
```
|
|
27
25
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
The Theme component comes with the following default props:
|
|
31
|
-
|
|
32
|
-
- `accentColor="cyan"`
|
|
33
|
-
- `appearance="dark"`
|
|
34
|
-
- `radius="small"`
|
|
35
|
-
- `panelBackground="solid"`
|
|
36
|
-
|
|
37
|
-
You can override these defaults by passing your own props:
|
|
26
|
+
# Setup example
|
|
38
27
|
|
|
28
|
+
Next.js:
|
|
39
29
|
```jsx
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
30
|
+
import { Theme } from "@moises.ai/design-system";
|
|
31
|
+
import "@moises.ai/design-system/styles.css";
|
|
32
|
+
|
|
33
|
+
export default function RootLayout({ children }) {
|
|
34
|
+
return (
|
|
35
|
+
<html lang="en" className="dark" style={{ colorScheme: "dark" }}>
|
|
36
|
+
<body>
|
|
37
|
+
<Theme>
|
|
38
|
+
{children}
|
|
39
|
+
</Theme>
|
|
40
|
+
</body>
|
|
41
|
+
</html>
|
|
42
|
+
);
|
|
43
|
+
}
|
|
44
|
+
```
|
package/dist/icons.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "@radix-ui/react-icons";
|
package/package.json
CHANGED
|
@@ -1,21 +1,33 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@moises.ai/design-system",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2",
|
|
4
4
|
"description": "Design System package based on @radix-ui/themes with custom defaults",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/index.js",
|
|
8
8
|
"module": "dist/index.js",
|
|
9
9
|
"style": "styles.css",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"import": "./dist/index.js",
|
|
13
|
+
"require": "./dist/index.js"
|
|
14
|
+
},
|
|
15
|
+
"./icons": {
|
|
16
|
+
"import": "./dist/icons.js",
|
|
17
|
+
"require": "./dist/icons.js"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
10
20
|
"files": [
|
|
11
21
|
"dist",
|
|
12
22
|
"styles.css"
|
|
13
23
|
],
|
|
14
24
|
"scripts": {
|
|
15
25
|
"build": "vite build",
|
|
26
|
+
"dev": "vite build --watch",
|
|
16
27
|
"prepare": "npm run build"
|
|
17
28
|
},
|
|
18
29
|
"dependencies": {
|
|
30
|
+
"@radix-ui/react-icons": "^1.3.0",
|
|
19
31
|
"@radix-ui/themes": "^2.0.0"
|
|
20
32
|
},
|
|
21
33
|
"peerDependencies": {
|
|
@@ -39,4 +51,4 @@
|
|
|
39
51
|
"publishConfig": {
|
|
40
52
|
"access": "public"
|
|
41
53
|
}
|
|
42
|
-
}
|
|
54
|
+
}
|