fansunited-management-components 1.33.2-RC1 → 1.34.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 ADDED
@@ -0,0 +1,90 @@
1
+ # Fans United Management Components
2
+
3
+ **Fans United Management Components** is a library that provides a collection of React components and utilities designed for integration
4
+ with Fans United. This project is distributed as an npm package, offering a modular approach to incorporate reusable components and
5
+ utilities across your React applications.
6
+
7
+ ## Installation
8
+
9
+ To install the package, run the following command:
10
+
11
+ ```bash
12
+ npm install fansunited-management-components
13
+ ```
14
+
15
+ Or with yarn:
16
+
17
+ ```bash
18
+ yarn add fansunited-management-components
19
+ ```
20
+
21
+ This library depends on the following peer dependencies. Make sure to install them in your consuming project:
22
+
23
+ ```bash
24
+ npm install @emotion/react @emotion/styled @mui/icons-material @mui/joy @mui/material react-quill fansunited-sdk-esm react react-dom
25
+ ```
26
+
27
+ ```bash
28
+ yarn add @emotion/react @emotion/styled @mui/icons-material @mui/joy @mui/material react-quill fansunited-sdk-esm react react-dom
29
+ ```
30
+
31
+ ## Usage
32
+
33
+ To use the components and utilities provided by **Fans United Management Components**, import them into your React project as needed:
34
+
35
+ ```javascript
36
+ import utils from 'fansunited-management-components';
37
+ import 'fansunited-management-components/style.css';
38
+
39
+ const MyComponent = () => {
40
+ const { https, sdk } = utils.useAPIContext();
41
+ const { Login, InformationInput, Branding } = utils.useComponentContext();
42
+
43
+ return (
44
+ <>
45
+ <Login />
46
+ <InformationInput />
47
+ <Branding />
48
+ </>
49
+ );
50
+ };
51
+
52
+ const App = () => {
53
+ const configuration = {
54
+ apiKey: '',
55
+ clientId: '',
56
+ environment: '',
57
+ language: '',
58
+ errorHandlingMode: '',
59
+ sportal365Project: '',
60
+ sportal365Infrastructure: '',
61
+ };
62
+ const { AuthProvider, APIProvider, ComponentProvider } = utils;
63
+
64
+ return (
65
+ <AuthProvider environment={configuration.environment}>
66
+ <APIProvider config={config}>
67
+ <ComponentProvider>
68
+ <MyComponent />
69
+ </ComponentProvider>
70
+ </APIProvider>
71
+ </AuthProvider>
72
+ );
73
+ };
74
+ ```
75
+
76
+ ## Components
77
+
78
+ The package includes a variety of React components designed for easy integration. Each component is documented with examples to guide
79
+ implementation.
80
+
81
+ ## Utilities
82
+
83
+ In addition to React components, this package includes several utility functions to assist with common tasks. These utilities are designed
84
+ to work seamlessly within the Fans United ecosystem.
85
+
86
+ ## Configuration
87
+
88
+ To use **Fans United Management Components**, certain configurations are required. These configurations ensure that the components and
89
+ utilities function correctly within your application. Please refer to the internal documentation or contact the project maintainer for
90
+ configuration details.