@chayns-components/ranking 5.0.33 → 5.0.35

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.
Files changed (2) hide show
  1. package/AI_USAGE.md +271 -0
  2. package/package.json +5 -4
package/AI_USAGE.md ADDED
@@ -0,0 +1,271 @@
1
+ # @chayns-components/ranking
2
+
3
+ React component package providing 2 documented components for chayns applications.
4
+
5
+ Documented components: `Ranking`, `RankingOverview`.
6
+
7
+ ## Import
8
+
9
+ ```ts
10
+ import { Ranking, RankingOverview } from '@chayns-components/ranking';
11
+ ```
12
+
13
+ ## Typical Usage
14
+
15
+ ```tsx
16
+ <Ranking
17
+ entries={[
18
+ {
19
+ rank: 1,
20
+ name: 'Michael Gesenhues',
21
+ personId: 'MIC-HAEL1',
22
+ points: 12,
23
+ content: [
24
+ {
25
+ id: 'ahdadrh',
26
+ name: 'Richtiges Ergebnis',
27
+ value: '3',
28
+ },
29
+ {
30
+ id: 'haerdjh',
31
+ name: 'Richtige Tordifferenz',
32
+ value: '2',
33
+ },
34
+ {
35
+ id: 'adrhs',
36
+ name: 'Richtige Tendenz',
37
+ value: '5',
38
+ },
39
+ {
40
+ id: 'rhd',
41
+ headline: 'BONUS',
42
+ },
43
+ {
44
+ id: 'hdfghm',
45
+ name: 'Abgegebene Tipps',
46
+ value: '10',
47
+ },
48
+ {
49
+ id: 'gjhfd',
50
+ name: 'Frühe Tippabgabe',
51
+ value: '458.943 Min.',
52
+ },
53
+ ],
54
+ },
55
+ {
56
+ rank: 2,
57
+ name: 'Jannik Weise',
58
+ personId: 'JAN-NIK96',
59
+ points: 11,
60
+ content: [
61
+ {
62
+ id: 'ahdadrh',
63
+ name: 'Richtiges Ergebnis',
64
+ value: '3',
65
+ },
66
+ {
67
+ id: 'haerdjh',
68
+ name: 'Richtige Tordifferenz',
69
+ value: '2',
70
+ },
71
+ {
72
+ id: 'adrhs',
73
+ name: 'Richtige Tendenz',
74
+ value: '5',
75
+ },
76
+ {
77
+ id: 'rhd',
78
+ headline: 'BONUS',
79
+ },
80
+ {
81
+ id: 'hdfghm',
82
+ name: 'Abgegebene Tipps',
83
+ value: '10',
84
+ },
85
+ {
86
+ id: 'gjhfd',
87
+ name: 'Frühe Tippabgabe',
88
+ value: '458.943 Min.',
89
+ },
90
+ ],
91
+ },
92
+ ]}
93
+ />
94
+ ```
95
+
96
+ ## Components
97
+
98
+ - `Ranking`
99
+ - `RankingOverview`
100
+
101
+ ## Ranking
102
+
103
+ `Ranking` is exported by `@chayns-components/ranking` and should be imported from the public package entry point.
104
+
105
+ ### Import
106
+
107
+ ```ts
108
+ import { Ranking } from '@chayns-components/ranking';
109
+ ```
110
+
111
+ ### Examples
112
+
113
+ #### General
114
+
115
+ ```tsx
116
+ <Ranking
117
+ entries={[
118
+ {
119
+ rank: 1,
120
+ name: 'Michael Gesenhues',
121
+ personId: 'MIC-HAEL1',
122
+ points: 12,
123
+ content: [
124
+ {
125
+ id: 'ahdadrh',
126
+ name: 'Richtiges Ergebnis',
127
+ value: '3',
128
+ },
129
+ {
130
+ id: 'haerdjh',
131
+ name: 'Richtige Tordifferenz',
132
+ value: '2',
133
+ },
134
+ {
135
+ id: 'adrhs',
136
+ name: 'Richtige Tendenz',
137
+ value: '5',
138
+ },
139
+ {
140
+ id: 'rhd',
141
+ headline: 'BONUS',
142
+ },
143
+ {
144
+ id: 'hdfghm',
145
+ name: 'Abgegebene Tipps',
146
+ value: '10',
147
+ },
148
+ {
149
+ id: 'gjhfd',
150
+ name: 'Frühe Tippabgabe',
151
+ value: '458.943 Min.',
152
+ },
153
+ ],
154
+ },
155
+ {
156
+ rank: 2,
157
+ name: 'Jannik Weise',
158
+ personId: 'JAN-NIK96',
159
+ points: 11,
160
+ content: [
161
+ {
162
+ id: 'ahdadrh',
163
+ name: 'Richtiges Ergebnis',
164
+ value: '3',
165
+ },
166
+ {
167
+ id: 'haerdjh',
168
+ name: 'Richtige Tordifferenz',
169
+ value: '2',
170
+ },
171
+ {
172
+ id: 'adrhs',
173
+ name: 'Richtige Tendenz',
174
+ value: '5',
175
+ },
176
+ {
177
+ id: 'rhd',
178
+ headline: 'BONUS',
179
+ },
180
+ {
181
+ id: 'hdfghm',
182
+ name: 'Abgegebene Tipps',
183
+ value: '10',
184
+ },
185
+ {
186
+ id: 'gjhfd',
187
+ name: 'Frühe Tippabgabe',
188
+ value: '458.943 Min.',
189
+ },
190
+ ],
191
+ },
192
+ ]}
193
+ />
194
+ ```
195
+
196
+ #### Flaschenjagd
197
+
198
+ ```tsx
199
+ <Ranking
200
+ entries={[
201
+ {
202
+ rank: 1,
203
+ name: 'Michael Gesenhues',
204
+ personId: 'MIC-HAEL1',
205
+ points: 40,
206
+ icons: ['fa fa-jug-bottle'],
207
+ },
208
+ {
209
+ rank: 2,
210
+ name: 'Jannik Weise',
211
+ personId: 'JAN-NIK96',
212
+ points: 38,
213
+ icons: ['fa fa-jug-bottle'],
214
+ },
215
+ ]}
216
+ />
217
+ ```
218
+
219
+ ### Props
220
+
221
+ No prop documentation available.
222
+
223
+ ### Types
224
+
225
+ No additional exported types documented.
226
+
227
+ ### Usage Notes
228
+
229
+ - Import `Ranking` directly from `@chayns-components/ranking` instead of internal source paths.
230
+ - Start with one of the documented Storybook examples and adapt the props incrementally for your use case.
231
+
232
+ ### Anti Patterns
233
+
234
+ - Avoid imports from internal paths such as `@chayns-components/ranking/src/...`; always use the public package export.
235
+ ## RankingOverview
236
+
237
+ `RankingOverview` is exported by `@chayns-components/ranking` and should be imported from the public package entry point.
238
+
239
+ ### Import
240
+
241
+ ```ts
242
+ import { RankingOverview } from '@chayns-components/ranking';
243
+ ```
244
+
245
+ ### Examples
246
+
247
+ #### General
248
+
249
+ ```tsx
250
+ <RankingOverview
251
+ userRank={1234}
252
+ totalPlayers={456789}
253
+ />
254
+ ```
255
+
256
+ ### Props
257
+
258
+ No prop documentation available.
259
+
260
+ ### Types
261
+
262
+ No additional exported types documented.
263
+
264
+ ### Usage Notes
265
+
266
+ - Import `RankingOverview` directly from `@chayns-components/ranking` instead of internal source paths.
267
+ - Start with one of the documented Storybook examples and adapt the props incrementally for your use case.
268
+
269
+ ### Anti Patterns
270
+
271
+ - Avoid imports from internal paths such as `@chayns-components/ranking/src/...`; always use the public package export.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chayns-components/ranking",
3
- "version": "5.0.33",
3
+ "version": "5.0.35",
4
4
  "description": "A set of beautiful React components for developing your own applications with chayns.",
5
5
  "sideEffects": false,
6
6
  "browserslist": [
@@ -33,7 +33,8 @@
33
33
  "test": "__tests__"
34
34
  },
35
35
  "files": [
36
- "lib"
36
+ "lib",
37
+ "AI_USAGE.md"
37
38
  ],
38
39
  "repository": {
39
40
  "type": "git",
@@ -71,7 +72,7 @@
71
72
  "typescript": "^5.9.3"
72
73
  },
73
74
  "dependencies": {
74
- "@chayns-components/core": "^5.0.33"
75
+ "@chayns-components/core": "^5.0.35"
75
76
  },
76
77
  "peerDependencies": {
77
78
  "chayns-api": ">=2.2.0",
@@ -83,5 +84,5 @@
83
84
  "publishConfig": {
84
85
  "access": "public"
85
86
  },
86
- "gitHead": "5e41d9af042b3c272c8c08b67a9c9bf4911902f6"
87
+ "gitHead": "9fabdc06522f6a9879e5ec03f8629ae0179b7495"
87
88
  }