@stamcat/craftsman 0.0.24 → 0.0.26

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 CHANGED
@@ -1,5 +1,52 @@
1
1
  # @stamcat/craftsman
2
2
 
3
- # Craftsman Design System Framework
3
+ Craftsman design system components and styling utilities.
4
4
 
5
- trivial commit to test ci publish
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @stamcat/craftsman
9
+ ```
10
+
11
+ ## RSC-safe setup
12
+
13
+ Use this pattern in React Server Component architectures (for example Next.js App Router):
14
+
15
+ 1. Import package global styles once at the application root.
16
+ 2. Render `ThemeProvider` at the root with your theme object.
17
+
18
+ ```tsx
19
+ import { ThemeProvider } from "@stamcat/craftsman/styles";
20
+ import "@stamcat/craftsman/styles";
21
+
22
+ const appTheme = {
23
+ root: {
24
+ "--w-gutter": "16px",
25
+ },
26
+ };
27
+
28
+ export default function RootLayout({ children }: { children: React.ReactNode }) {
29
+ return (
30
+ <html lang="en">
31
+ <body>
32
+ <ThemeProvider theme={appTheme}>{children}</ThemeProvider>
33
+ </body>
34
+ </html>
35
+ );
36
+ }
37
+ ```
38
+
39
+ ## Component imports
40
+
41
+ Use component entry points:
42
+
43
+ ```tsx
44
+ import { Button } from "@stamcat/craftsman/Button";
45
+ import { Input } from "@stamcat/craftsman/Input";
46
+ import { Modal } from "@stamcat/craftsman/Modal";
47
+ ```
48
+
49
+ ## Styling notes
50
+
51
+ - `ThemeProvider` injects theme CSS variables and component override rules.
52
+ - Global styles should be loaded once at app root.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stamcat/craftsman",
3
- "version": "0.0.24",
3
+ "version": "0.0.26",
4
4
  "type": "module",
5
5
  "description": "A powerful, lightweight framework for design systems",
6
6
  "repository": {
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { isEmpty as e } from "../utilities/validations.esm.js";
2
3
  import { width as t } from "../styles/utilities/layout.esm.js";
3
4
  import "../../Styles.esm.js";
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { Input as e } from "./Input.esm.js";
2
3
  import { jsx as t } from "react/jsx-runtime";
3
4
  //#region src/components/Checkbox.tsx
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { isEmpty as e } from "../utilities/validations.esm.js";
2
3
  import t from "./Input.module.esm.js";
3
4
  import n from "clsx";
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { Button as e } from "./Button.esm.js";
2
3
  import { Input as t } from "./Input.esm.js";
3
4
  import { jsx as n } from "react/jsx-runtime";
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { isEmpty as e } from "../utilities/validations.esm.js";
2
3
  import { loaders as t } from "../styles/global/components/loaders.esm.js";
3
4
  import n from "../styles/global/components/loaders.module.esm.js";
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { isEmpty as e } from "../utilities/validations.esm.js";
2
3
  import { color as t } from "../styles/utilities/color.esm.js";
3
4
  import { Button as n } from "./Button.esm.js";
@@ -1,3 +1,4 @@
1
+ "use client";
1
2
  import { Input as e } from "./Input.esm.js";
2
3
  import { jsx as t } from "react/jsx-runtime";
3
4
  //#region src/components/RadioButton.tsx
@@ -3,5 +3,5 @@ export * from './utilities/constants';
3
3
  export * from './utilities/layout';
4
4
  export * from './utilities/types';
5
5
  export * from './theme/theme';
6
- export * from './global/globalStyles';
6
+ export { globalStyles } from './global/globalStyles';
7
7
  export { ThemeProvider } from './components/ThemeProvider';