@ivao/atmosphere-react 2.0.0-next.2 → 2.0.0-next.4

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
@@ -18,12 +18,45 @@ pnpm add @ivao/atmosphere-react
18
18
 
19
19
  ### Configure
20
20
 
21
+ #### tailwindcss
22
+
23
+ If you want to use tailwindcss classes, customizations or overrides,
24
+ you need to add our [tailwind preset](https://v3.tailwindcss.com/docs/presets) to your `tailwind.config.ts` file.
25
+
26
+ ```typescript
27
+ import ivaoPreset from '@ivao/atmosphere-react/tailwind.preset.ts'; // import the preset
28
+
29
+ import { Config } from 'tailwindcss';
30
+
31
+ export default {
32
+ content: [
33
+ './src/**/*.tsx', // your files here...
34
+ './node_modules/@ivao/atmosphere-react/dist/atmosphere-react.js', // let tailwind know about our components
35
+ ],
36
+ presets: [ivaoPreset], // add the preset here
37
+ } satisfies Config;
38
+ ```
39
+
40
+ Additionally, you need to import our source CSS file that adds the color variables to your project.
41
+ In your app CSS file, add this line:
42
+
43
+ ```css
44
+ @import '@ivao/atmosphere-react/src/styles/index.css';
45
+ ```
46
+
47
+ You can extend your CSS file (e.g. add utilities or base classes)
48
+ and tailwind config (e.g. add colors) as you prefer.
49
+
50
+ #### CSS only
51
+
21
52
  Import our CSS by adding this line to your index file.
22
53
 
23
54
  ```typescript
24
55
  import '@ivao/atmosphere-react/dist/styles/index.css';
25
56
  ```
26
57
 
58
+ > This approach is sufficient if no further tailwind classes, customizations or overrides are needed.
59
+
27
60
  ## Contributing
28
61
 
29
62
  ### Testing Locally on another repo