fansunited-frontend-core 0.0.1-RC2 → 0.0.1

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/README.md +89 -6
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
- # Fans United Core Utils
1
+ # Fans United Frontend Core
2
2
 
3
- Core utilities, providers, hooks, and shared functionality for Fans United widget packages.
3
+ Core utilities, types, and shared functionality for Fans United widget packages.
4
4
 
5
5
  ## Installation
6
6
 
@@ -14,9 +14,92 @@ yarn add fansunited-frontend-core
14
14
 
15
15
  ## Features
16
16
 
17
+ - Complete TypeScript definitions for all Fans United components
17
18
  - Theme management with light/dark mode support
18
- - Internationalization (i18n) setup
19
- - Common TypeScript types and interfaces
20
- - Shared utilities and helpers
19
+ - Internationalization (i18n) with 10+ supported languages
20
+ - Shared utilities and helper functions
21
21
  - React providers and hooks
22
- - Component primitives
22
+ - Component primitives
23
+
24
+ ## Core Exports
25
+
26
+ ### Types and Interfaces
27
+
28
+ ```tsx
29
+ import {
30
+ ClassicQuizPlayProps,
31
+ WidgetTemplate,
32
+ WidgetProps,
33
+ CustomThemeOptions,
34
+ LeadsOptions,
35
+ AnalyticsEvent
36
+ } from "fansunited-frontend-core";
37
+ ```
38
+
39
+ ### Theme Utilities
40
+
41
+ ```tsx
42
+ import {
43
+ useSpacingScale,
44
+ getSpacing,
45
+ useFontFamily,
46
+ useCornerRadius,
47
+ useColors,
48
+ useBorderSize,
49
+ useInternalTheme
50
+ } from "fansunited-frontend-core";
51
+ ```
52
+
53
+ ### Helper Functions
54
+
55
+ ```tsx
56
+ import {
57
+ stripHtmlTags,
58
+ hexToRgb,
59
+ isAndroid,
60
+ isMobile
61
+ } from "fansunited-frontend-core";
62
+ ```
63
+
64
+ ### Internationalization
65
+
66
+ ```tsx
67
+ import { initializeI18n } from "fansunited-frontend-core";
68
+
69
+ // Initialize with preferred language
70
+ initializeI18n("en");
71
+ ```
72
+
73
+ ## Supported Languages
74
+
75
+ - English (en)
76
+ - Bulgarian (bg)
77
+ - German (de)
78
+ - French (fr)
79
+ - Belgian French (fr-be)
80
+ - Italian (it)
81
+ - Polish (pl)
82
+ - Portuguese (pt)
83
+ - Brazilian Portuguese (pt-br)
84
+ - Romanian (ro)
85
+ - Serbian (sr)
86
+
87
+ ## Usage with Components
88
+
89
+ This package is designed to work with `fansunited-frontend-components`:
90
+
91
+ ```tsx
92
+ import { ClassicQuizPlay } from "fansunited-frontend-components";
93
+ import { WidgetTemplate } from "fansunited-frontend-core";
94
+
95
+ <ClassicQuizPlay
96
+ entityId="quiz-123"
97
+ sdk={sdkInstance}
98
+ template={WidgetTemplate.STANDARD}
99
+ language="en"
100
+ />;
101
+ ```
102
+
103
+ ## License
104
+
105
+ © Fans United Media. All rights reserved.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fansunited-frontend-core",
3
- "version": "0.0.1-RC2",
3
+ "version": "0.0.1",
4
4
  "description": "Core types, components, providers and constants for Fans United widgets",
5
5
  "main": "index.es.js",
6
6
  "types": "index.d.ts",