canvasframework 0.5.16 → 0.5.18

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 (112) hide show
  1. package/dist/canvasframework.js +2 -0
  2. package/dist/canvasframework.js.LICENSE.txt +1 -0
  3. package/package.json +18 -17
  4. package/components/Accordion.js +0 -265
  5. package/components/AndroidDatePickerDialog.js +0 -406
  6. package/components/AppBar.js +0 -398
  7. package/components/AudioPlayer.js +0 -611
  8. package/components/Avatar.js +0 -202
  9. package/components/Banner.js +0 -342
  10. package/components/BottomNavigationBar.js +0 -433
  11. package/components/BottomSheet.js +0 -234
  12. package/components/Button.js +0 -360
  13. package/components/Camera.js +0 -644
  14. package/components/Card.js +0 -193
  15. package/components/Chart.js +0 -700
  16. package/components/Checkbox.js +0 -166
  17. package/components/Chip.js +0 -212
  18. package/components/CircularProgress.js +0 -327
  19. package/components/ContextMenu.js +0 -116
  20. package/components/DatePicker.js +0 -298
  21. package/components/Dialog.js +0 -337
  22. package/components/Divider.js +0 -125
  23. package/components/Drawer.js +0 -276
  24. package/components/FAB.js +0 -270
  25. package/components/FileUpload.js +0 -315
  26. package/components/FloatedCamera.js +0 -644
  27. package/components/IOSDatePickerWheel.js +0 -430
  28. package/components/ImageCarousel.js +0 -219
  29. package/components/ImageComponent.js +0 -223
  30. package/components/Input.js +0 -831
  31. package/components/InputDatalist.js +0 -723
  32. package/components/InputTags.js +0 -624
  33. package/components/List.js +0 -95
  34. package/components/ListItem.js +0 -269
  35. package/components/Modal.js +0 -364
  36. package/components/MorphingFAB.js +0 -428
  37. package/components/MultiSelectDialog.js +0 -206
  38. package/components/NumberInput.js +0 -271
  39. package/components/PasswordInput.js +0 -462
  40. package/components/ProgressBar.js +0 -88
  41. package/components/QRCodeReader.js +0 -539
  42. package/components/RadioButton.js +0 -151
  43. package/components/SearchInput.js +0 -315
  44. package/components/SegmentedControl.js +0 -357
  45. package/components/Select.js +0 -199
  46. package/components/SelectDialog.js +0 -255
  47. package/components/Slider.js +0 -113
  48. package/components/SliverAppBar.js +0 -139
  49. package/components/Snackbar.js +0 -243
  50. package/components/SpeedDialFAB.js +0 -397
  51. package/components/Stepper.js +0 -281
  52. package/components/SwipeableListItem.js +0 -327
  53. package/components/Switch.js +0 -147
  54. package/components/Table.js +0 -492
  55. package/components/Tabs.js +0 -423
  56. package/components/Text.js +0 -141
  57. package/components/TextField.js +0 -151
  58. package/components/TimePicker.js +0 -934
  59. package/components/Toast.js +0 -236
  60. package/components/TreeView.js +0 -420
  61. package/components/Video.js +0 -397
  62. package/components/View.js +0 -140
  63. package/components/VirtualList.js +0 -120
  64. package/core/CanvasFramework.js +0 -3034
  65. package/core/Component.js +0 -243
  66. package/core/ThemeManager.js +0 -358
  67. package/core/UIBuilder.js +0 -267
  68. package/core/WebGLCanvasAdapter.js +0 -782
  69. package/features/Column.js +0 -43
  70. package/features/Grid.js +0 -47
  71. package/features/LayoutComponent.js +0 -43
  72. package/features/OpenStreetMap.js +0 -310
  73. package/features/Positioned.js +0 -33
  74. package/features/PullToRefresh.js +0 -328
  75. package/features/Row.js +0 -40
  76. package/features/SignaturePad.js +0 -257
  77. package/features/Skeleton.js +0 -193
  78. package/features/Stack.js +0 -21
  79. package/index.js +0 -119
  80. package/manager/AccessibilityManager.js +0 -107
  81. package/manager/ErrorHandler.js +0 -59
  82. package/manager/FeatureFlags.js +0 -60
  83. package/manager/MemoryManager.js +0 -107
  84. package/manager/PerformanceMonitor.js +0 -84
  85. package/manager/SecurityManager.js +0 -54
  86. package/utils/AnimationEngine.js +0 -734
  87. package/utils/CryptoManager.js +0 -303
  88. package/utils/DataStore.js +0 -403
  89. package/utils/DevTools.js +0 -1618
  90. package/utils/DevToolsConsole.js +0 -201
  91. package/utils/EventBus.js +0 -407
  92. package/utils/FetchClient.js +0 -74
  93. package/utils/FirebaseAuth.js +0 -653
  94. package/utils/FirebaseCore.js +0 -246
  95. package/utils/FirebaseFirestore.js +0 -581
  96. package/utils/FirebaseFunctions.js +0 -97
  97. package/utils/FirebaseRealtimeDB.js +0 -498
  98. package/utils/FirebaseStorage.js +0 -612
  99. package/utils/FormValidator.js +0 -355
  100. package/utils/GeoLocationService.js +0 -62
  101. package/utils/I18n.js +0 -207
  102. package/utils/IndexedDBManager.js +0 -273
  103. package/utils/InspectionOverlay.js +0 -308
  104. package/utils/NotificationManager.js +0 -60
  105. package/utils/OfflineSyncManager.js +0 -342
  106. package/utils/PayPalPayment.js +0 -678
  107. package/utils/QueryBuilder.js +0 -478
  108. package/utils/SafeArea.js +0 -64
  109. package/utils/SecureStorage.js +0 -289
  110. package/utils/StateManager.js +0 -207
  111. package/utils/StripePayment.js +0 -552
  112. package/utils/WebSocketClient.js +0 -66
@@ -1,246 +0,0 @@
1
- /**
2
- * FirebaseCore - Classe de base pour initialiser Firebase
3
- *
4
- * @example
5
- * const firebase = new FirebaseCore({
6
- * apiKey: "YOUR_API_KEY",
7
- * authDomain: "YOUR_PROJECT.firebaseapp.com",
8
- * projectId: "YOUR_PROJECT_ID",
9
- * storageBucket: "YOUR_PROJECT.appspot.com",
10
- * messagingSenderId: "YOUR_SENDER_ID",
11
- * appId: "YOUR_APP_ID"
12
- * });
13
- * await firebase.initialize();
14
- */
15
- class FirebaseCore {
16
- constructor(config) {
17
- this.config = config;
18
- this.app = null;
19
- this.isInitialized = false;
20
-
21
- // Options
22
- this.enablePersistence = config.enablePersistence !== false;
23
- this.enableAnalytics = config.enableAnalytics !== false;
24
-
25
- // Références aux services
26
- this.auth = null;
27
- this.db = null;
28
- this.storage = null;
29
- this.functions = null;
30
- this.messaging = null;
31
- this.analytics = null;
32
- }
33
-
34
- /**
35
- * Initialiser Firebase
36
- */
37
- async initialize() {
38
- if (this.isInitialized) {
39
- return this.app;
40
- }
41
-
42
- try {
43
- // Charger les scripts Firebase
44
- await this.loadFirebaseScripts();
45
-
46
- // Initialiser l'app Firebase
47
- this.app = firebase.initializeApp(this.config);
48
-
49
- // Initialiser Analytics si activé
50
- if (this.enableAnalytics && firebase.analytics) {
51
- this.analytics = firebase.analytics();
52
- }
53
-
54
- this.isInitialized = true;
55
-
56
- return this.app;
57
-
58
- } catch (error) {
59
- console.error('❌ Erreur initialisation Firebase:', error);
60
- throw error;
61
- }
62
- }
63
-
64
- /**
65
- * Charger les scripts Firebase depuis le CDN
66
- */
67
- async loadFirebaseScripts() {
68
- const version = '9.23.0'; // Version Firebase
69
-
70
- const scripts = [
71
- `https://www.gstatic.com/firebasejs/${version}/firebase-app-compat.js`,
72
- `https://www.gstatic.com/firebasejs/${version}/firebase-auth-compat.js`,
73
- `https://www.gstatic.com/firebasejs/${version}/firebase-database-compat.js`,
74
- `https://www.gstatic.com/firebasejs/${version}/firebase-firestore-compat.js`,
75
- `https://www.gstatic.com/firebasejs/${version}/firebase-storage-compat.js`,
76
- `https://www.gstatic.com/firebasejs/${version}/firebase-functions-compat.js`,
77
- `https://www.gstatic.com/firebasejs/${version}/firebase-messaging-compat.js`,
78
- `https://www.gstatic.com/firebasejs/${version}/firebase-analytics-compat.js`
79
- ];
80
-
81
- // Charger tous les scripts en parallèle
82
- await Promise.all(scripts.map(src => this.loadScript(src)));
83
- }
84
-
85
- /**
86
- * Charger un script
87
- */
88
- loadScript(src) {
89
- return new Promise((resolve, reject) => {
90
- // Vérifier si le script est déjà chargé
91
- if (document.querySelector(`script[src="${src}"]`)) {
92
- resolve();
93
- return;
94
- }
95
-
96
- const script = document.createElement('script');
97
- script.src = src;
98
- script.async = true;
99
- script.onload = resolve;
100
- script.onerror = () => reject(new Error(`Échec du chargement: ${src}`));
101
- document.head.appendChild(script);
102
- });
103
- }
104
-
105
- /**
106
- * Obtenir l'instance Firebase
107
- */
108
- getApp() {
109
- if (!this.isInitialized) {
110
- throw new Error('Firebase non initialisé. Appelez initialize() d\'abord.');
111
- }
112
- return this.app;
113
- }
114
-
115
- /**
116
- * Obtenir un service Firebase
117
- */
118
- getAuth() {
119
- if (!this.auth) {
120
- this.auth = firebase.auth();
121
- }
122
- return this.auth;
123
- }
124
-
125
- getDatabase() {
126
- if (!this.db) {
127
- this.db = firebase.database();
128
- }
129
- return this.db;
130
- }
131
-
132
- getFirestore() {
133
- if (!this.firestore) {
134
- this.firestore = firebase.firestore();
135
-
136
- // Activer la persistance si demandé
137
- if (this.enablePersistence) {
138
- this.firestore.enablePersistence({ synchronizeTabs: true })
139
- .catch(err => {
140
- if (err.code === 'failed-precondition') {
141
- console.warn('⚠️ Persistance: plusieurs onglets ouverts');
142
- } else if (err.code === 'unimplemented') {
143
- console.warn('⚠️ Persistance non supportée par ce navigateur');
144
- }
145
- });
146
- }
147
- }
148
- return this.firestore;
149
- }
150
-
151
- getStorage() {
152
- if (!this.storage) {
153
- this.storage = firebase.storage();
154
- }
155
- return this.storage;
156
- }
157
-
158
- getFunctions(region = 'us-central1') {
159
- if (!this.functions) {
160
- this.functions = firebase.functions(region);
161
- }
162
- return this.functions;
163
- }
164
-
165
- getMessaging() {
166
- if (!this.messaging) {
167
- this.messaging = firebase.messaging();
168
- }
169
- return this.messaging;
170
- }
171
-
172
- getAnalytics() {
173
- if (!this.analytics) {
174
- this.analytics = firebase.analytics();
175
- }
176
- return this.analytics;
177
- }
178
-
179
- /**
180
- * Obtenir le timestamp serveur
181
- */
182
- getServerTimestamp() {
183
- return firebase.database.ServerValue.TIMESTAMP;
184
- }
185
-
186
- /**
187
- * Obtenir le timestamp Firestore serveur
188
- */
189
- getFirestoreServerTimestamp() {
190
- return firebase.firestore.FieldValue.serverTimestamp();
191
- }
192
-
193
- /**
194
- * Logger un événement Analytics
195
- */
196
- logEvent(eventName, eventParams = {}) {
197
- if (this.analytics) {
198
- this.analytics.logEvent(eventName, eventParams);
199
- }
200
- }
201
-
202
- /**
203
- * Définir l'utilisateur pour Analytics
204
- */
205
- setUserId(userId) {
206
- if (this.analytics) {
207
- this.analytics.setUserId(userId);
208
- }
209
- }
210
-
211
- /**
212
- * Définir une propriété utilisateur
213
- */
214
- setUserProperty(name, value) {
215
- if (this.analytics) {
216
- this.analytics.setUserProperties({ [name]: value });
217
- }
218
- }
219
-
220
- /**
221
- * Vérifier si Firebase est initialisé
222
- */
223
- isReady() {
224
- return this.isInitialized;
225
- }
226
-
227
- /**
228
- * Nettoyer les ressources
229
- */
230
- destroy() {
231
- if (this.app) {
232
- this.app.delete();
233
- this.app = null;
234
- }
235
-
236
- this.auth = null;
237
- this.db = null;
238
- this.storage = null;
239
- this.functions = null;
240
- this.messaging = null;
241
- this.analytics = null;
242
- this.isInitialized = false;
243
- }
244
- }
245
-
246
- export default FirebaseCore;