@flowerforce/flower-core 3.3.1-beta.1 → 4.0.1-beta.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.
Files changed (35) hide show
  1. package/dist/index.cjs.js +241 -271
  2. package/dist/index.esm.js +231 -270
  3. package/dist/src/constants/index.d.ts +5 -0
  4. package/dist/src/event-emitter/index.d.ts +1 -0
  5. package/dist/src/index.d.ts +6 -8
  6. package/dist/src/interfaces/CoreInterface.d.ts +23 -17
  7. package/dist/src/interfaces/ReducerInterface.d.ts +117 -99
  8. package/dist/src/{rules-matcher/interface.d.ts → interfaces/RulesMatcherInterface.d.ts} +1 -1
  9. package/dist/src/interfaces/SelectorsInterface.d.ts +21 -12
  10. package/dist/src/interfaces/Store.d.ts +2 -10
  11. package/dist/src/interfaces/UtilsInterface.d.ts +1 -1
  12. package/dist/src/interfaces/index.d.ts +3 -0
  13. package/dist/src/rules-matcher/RulesMatcher.d.ts +2 -0
  14. package/dist/src/rules-matcher/index.d.ts +2 -0
  15. package/dist/src/rules-matcher/utils.d.ts +2 -3
  16. package/dist/src/state-manager/index.d.ts +2 -0
  17. package/dist/src/state-manager/state-functions/FlowerCoreMergedReducers.d.ts +2 -0
  18. package/dist/src/state-manager/state-functions/FlowerCoreStateFunctions.d.ts +5 -0
  19. package/dist/src/state-manager/state-functions/FlowerDataStateFunctions.d.ts +13 -0
  20. package/dist/src/state-manager/state-functions/index.d.ts +4 -0
  21. package/dist/src/state-manager/state-selectors/FlowerCoreStateSelectors.d.ts +2 -0
  22. package/dist/src/state-manager/state-selectors/FlowerFormStateSelectors.d.ts +2 -0
  23. package/dist/src/state-manager/state-selectors/FlowerSelectorsMerged.d.ts +2 -0
  24. package/dist/src/state-manager/state-selectors/index.d.ts +4 -0
  25. package/dist/src/{FlowerCoreStateUtils.d.ts → utils/FlowerCoreStateUtils.d.ts} +2 -2
  26. package/dist/src/{CoreUtils.d.ts → utils/FlowerCoreUtils.d.ts} +1 -2
  27. package/dist/src/utils/FlowerFlowUtils.d.ts +3 -0
  28. package/dist/src/utils/FlowerFormCoreUtils.d.ts +2 -0
  29. package/dist/src/utils/index.d.ts +4 -0
  30. package/package.json +1 -1
  31. package/dist/src/FlowerCoreStateFunctions.d.ts +0 -5
  32. package/dist/src/FlowerCoreStateSelectors.d.ts +0 -2
  33. package/dist/src/RulesMatcher.d.ts +0 -5
  34. package/dist/src/devtoolState.d.ts +0 -2
  35. /package/dist/src/{Emitter.d.ts → event-emitter/Emitter.d.ts} +0 -0
@@ -0,0 +1,5 @@
1
+ export declare enum REDUCER_NAME {
2
+ FLOWER_FLOW = "FlowerFlow",
3
+ FLOWER_DATA = "FlowerData"
4
+ }
5
+ export declare const devtoolState: {};
@@ -0,0 +1 @@
1
+ export * from './Emitter';
@@ -1,8 +1,6 @@
1
- export { Emitter } from './Emitter';
2
- export { FlowerCoreReducers } from './FlowerCoreStateFunctions';
3
- export { FlowerStateUtils } from './FlowerCoreStateUtils';
4
- export { FlowerCoreStateSelectors as Selectors } from './FlowerCoreStateSelectors';
5
- export { CoreUtils } from './CoreUtils';
6
- export { MatchRules } from './RulesMatcher';
7
- export { devtoolState } from './devtoolState';
8
- export * from './interfaces';
1
+ export * from './event-emitter';
2
+ export * from './constants';
3
+ export * from './utils';
4
+ export * from './rules-matcher';
5
+ export * from './state-manager';
6
+ export type * from './interfaces';
@@ -47,6 +47,8 @@ export declare enum RulesModes {
47
47
  $or = "$or"
48
48
  }
49
49
  type RulesValuesType<T> = {
50
+ '$data.isValid'?: boolean;
51
+ /** @deprecated use $data.isValid instead */
50
52
  '$form.isValid'?: boolean;
51
53
  } & T;
52
54
  type RulesOperatorsInArray<T> = Partial<{
@@ -74,7 +76,7 @@ export type RulesObject<T> = RulesValuesType<T> | {
74
76
  export type CleanPath = (name: string, char?: string) => string;
75
77
  export type GetPath = (idValue?: string) => {
76
78
  path: string | string[];
77
- flowNameFromPath?: string;
79
+ formName?: string;
78
80
  };
79
81
  export type AllEqual = (...args: Array<number | string | boolean>[]) => boolean;
80
82
  export type FindValidRule<T = Rules<RulesObject<any>>> = (nextRules: {
@@ -112,7 +114,7 @@ export type MapKeysDeepLodash = (obj: Record<string, any>, cb: (...args: any) =>
112
114
  export type GenerateRulesName = (nextRules: RulesWithName[]) => {
113
115
  [X: string]: string;
114
116
  };
115
- export interface CoreUtilitiesFunctions {
117
+ export interface FlowUtilitiesFunctions {
116
118
  /**
117
119
  *
118
120
  * Generates rule names from a set of rules.
@@ -181,21 +183,6 @@ export interface CoreUtilitiesFunctions {
181
183
  * @returns
182
184
  */
183
185
  generateNodesForFlowerJson: GenerateNodesForFlowerJson;
184
- /**
185
- * Removes specified characters from the beginning of a string (default char -> '^').
186
- * @param name
187
- * @param char
188
- *
189
- * @returns
190
- */
191
- cleanPath: CleanPath;
192
- /**
193
- * Creates a valid path from idValue
194
- * @param idValue
195
- *
196
- * @returns
197
- */
198
- getPath: GetPath;
199
186
  /**
200
187
  * Checks if two arrays are equal in length and have the same elements.
201
188
  * @param arr
@@ -214,4 +201,23 @@ export interface CoreUtilitiesFunctions {
214
201
  */
215
202
  findValidRule: FindValidRule;
216
203
  }
204
+ export interface FormUtilitiesFunctions {
205
+ /**
206
+ * Removes specified characters from the beginning of a string (default char -> '^').
207
+ * @param name
208
+ * @param char
209
+ *
210
+ * @returns
211
+ */
212
+ cleanPath: CleanPath;
213
+ /**
214
+ * Creates a valid path from idValue
215
+ * @param idValue
216
+ *
217
+ * @returns
218
+ */
219
+ getPath: GetPath;
220
+ }
221
+ export interface CoreUtilitiesFunctions extends FormUtilitiesFunctions, FlowUtilitiesFunctions {
222
+ }
217
223
  export {};
@@ -5,11 +5,14 @@ export type ActionWithPayload<T> = {
5
5
  payload: T;
6
6
  };
7
7
  type ReducerFunctionSign<T extends object, R> = (state: Record<string, Flower<T>>, action: ActionWithPayload<R>) => Record<string, Flower<T>> | void;
8
+ type FormReducerFunctionSign<T extends object, R = object> = (state: Record<string, T>, action: ActionWithPayload<{
9
+ formName: string;
10
+ } & R>) => Record<string, T> | void;
8
11
  export type ActionsTypes = 'historyAdd' | 'historyPrevToNode' | 'setFormTouched' | 'forceAddHistory' | 'historyPop' | 'restoreHistory' | 'replaceNode' | 'initializeFromNode' | 'forceResetHistory' | 'destroy' | 'initNodes' | 'setCurrentNode' | 'formAddErrors' | 'formRemoveErrors' | 'addData' | 'addDataByPath' | 'replaceData' | 'unsetData' | 'setFormIsValidating' | 'resetForm' | 'formFieldTouch' | 'formFieldFocus' | 'node' | 'prevToNode' | 'next' | 'prev' | 'reset';
9
12
  /**
10
13
  * These functions are Redux reducers used in a Flux architecture for managing state transitions and updates in a Flower application.
11
14
  */
12
- export type ReducersFunctions<T extends Record<string, any> = Record<string, Flower<Record<string, any>>>> = {
15
+ export type CoreReducersFunctions<T extends Record<string, any> = Record<string, Flower<Record<string, any>>>> = {
13
16
  /**
14
17
  * @param state
15
18
  * @param action
@@ -34,18 +37,6 @@ export type ReducersFunctions<T extends Record<string, any> = Record<string, Flo
34
37
  name: string;
35
38
  node: string;
36
39
  } | string>;
37
- /**
38
- * @param state
39
- * @param action
40
- *
41
- * Sets the "touched" state of a form node in a flow.
42
- *
43
- * @returns state
44
- */
45
- setFormTouched: ReducerFunctionSign<T, {
46
- flowName: string;
47
- currentNode: string;
48
- } | string>;
49
40
  /**
50
41
  * @param state
51
42
  * @param action
@@ -143,7 +134,6 @@ export type ReducersFunctions<T extends Record<string, any> = Record<string, Flo
143
134
  startId: string;
144
135
  persist: boolean;
145
136
  nodes: Node[];
146
- initialData: any;
147
137
  initialState: {
148
138
  startId?: string;
149
139
  current?: string;
@@ -166,215 +156,244 @@ export type ReducersFunctions<T extends Record<string, any> = Record<string, Flo
166
156
  * @param state
167
157
  * @param action
168
158
  *
169
- * Adds errors to a form node in a flow.
159
+ * Handles node transitions in a flow, updating history and form states accordingly.
170
160
  *
171
161
  * @returns state
172
162
  */
173
- formAddCustomErrors: ReducerFunctionSign<T, {
163
+ node: ReducerFunctionSign<T, {
174
164
  name: string;
175
- currentNode: string;
176
- id: string;
177
- errors: string[];
165
+ flowName?: string;
166
+ nodeId?: string;
167
+ node?: string;
168
+ history: string[];
178
169
  }>;
179
170
  /**
180
171
  * @param state
181
172
  * @param action
182
173
  *
183
- * Adds errors to a form node in a flow.
174
+ * Navigates to a specific node in the history of a flow.
184
175
  *
185
176
  * @returns state
186
177
  */
187
- formAddErrors: ReducerFunctionSign<T, {
188
- name: string;
189
- currentNode: string;
190
- id: string;
191
- errors: {
192
- [x: string]: string[];
193
- } | string[];
178
+ prevToNode: ReducerFunctionSign<T, {
179
+ name?: string;
180
+ flowName?: string;
181
+ node: string;
194
182
  }>;
195
183
  /**
196
184
  * @param state
197
185
  * @param action
198
186
  *
199
- * Set touch form single field
187
+ * Moves to the next node in a flow based on validation rules and current state.
200
188
  *
201
189
  * @returns state
202
190
  */
203
- formFieldTouch: ReducerFunctionSign<T, {
204
- name: string;
205
- currentNode: string;
206
- id: string;
207
- touched?: boolean;
191
+ next: ReducerFunctionSign<T, {
192
+ name?: string;
193
+ flowName?: string;
194
+ route?: string;
195
+ data?: Record<string, any>;
196
+ dataIn?: Record<string, any>;
197
+ isStart?: boolean;
208
198
  }>;
209
199
  /**
210
200
  * @param state
211
201
  * @param action
212
202
  *
213
- * Set touch form single field
203
+ * Moves to the previous node in a flow.
214
204
  *
215
205
  * @returns state
216
206
  */
217
- formFieldFocus: ReducerFunctionSign<T, {
218
- name: string;
219
- currentNode: string;
220
- id: string;
221
- focused?: boolean;
207
+ prev: ReducerFunctionSign<T, {
208
+ name?: string;
209
+ flowName?: string;
222
210
  }>;
223
211
  /**
224
212
  * @param state
225
213
  * @param action
226
214
  *
227
- * Removes errors from a form node in a flow.
215
+ * Return back to the first node and resets history.
228
216
  *
229
217
  * @returns state
230
218
  */
231
- formRemoveErrors: ReducerFunctionSign<T, {
232
- name: string;
233
- currentNode: string;
219
+ restart: ReducerFunctionSign<T, {
220
+ name?: string;
221
+ flowName?: string;
222
+ }>;
223
+ /**
224
+ * @param state
225
+ * @param action
226
+ *
227
+ * Returns back to the first node, resets history and clean all previous data from flow.
228
+ *
229
+ * @returns state
230
+ */
231
+ reset: ReducerFunctionSign<T, {
232
+ name?: string;
233
+ flowName?: string;
234
+ }
235
+ /**
236
+ * @param state
237
+ * @param action
238
+ *
239
+ * Reset form.
240
+ *
241
+ * @returns state
242
+ */
243
+ >;
244
+ };
245
+ export type FormReducersFunctions<T extends Record<string, any> = Record<string, Record<string, any>>> = {
246
+ /**
247
+ * @param state
248
+ * @param action
249
+ *
250
+ * Sets the "touched" state of a form node in a flow.
251
+ *
252
+ * @returns state
253
+ */
254
+ setFormTouched: FormReducerFunctionSign<T>;
255
+ /**
256
+ * @param state
257
+ * @param action
258
+ *
259
+ * Adds errors to a form node in a flow.
260
+ *
261
+ * @returns state
262
+ */
263
+ formAddCustomErrors: FormReducerFunctionSign<T, {
234
264
  id: string;
265
+ errors: string[];
235
266
  }>;
236
267
  /**
237
268
  * @param state
238
269
  * @param action
239
270
  *
240
- * Adds data to a flow.
271
+ * Adds errors to a form node in a flow.
241
272
  *
242
273
  * @returns state
243
274
  */
244
- addData: ReducerFunctionSign<T, {
245
- flowName: string;
246
- value: T;
275
+ formAddErrors: FormReducerFunctionSign<T, {
276
+ id: string;
277
+ errors: {
278
+ [x: string]: string[];
279
+ } | string[];
247
280
  }>;
248
281
  /**
249
282
  * @param state
250
283
  * @param action
251
284
  *
252
- * Adds data to a flow at a specific path.
285
+ * Set dirty form single field
253
286
  *
254
287
  * @returns state
255
288
  */
256
- addDataByPath: ReducerFunctionSign<T, {
289
+ formFieldDirty: FormReducerFunctionSign<T, {
257
290
  id: string;
258
- flowName: string;
259
- value: T | string;
260
291
  dirty?: boolean;
261
292
  }>;
262
293
  /**
263
294
  * @param state
264
295
  * @param action
265
296
  *
266
- * Replaces the data of a flow with new data.
297
+ * Set touch form single field
267
298
  *
268
299
  * @returns state
269
300
  */
270
- replaceData: ReducerFunctionSign<T, {
271
- flowName: string;
272
- value: T;
301
+ formFieldTouch: FormReducerFunctionSign<T, {
302
+ id: string;
303
+ touched?: boolean;
273
304
  }>;
274
305
  /**
275
306
  * @param state
276
307
  * @param action
277
308
  *
278
- * Unsets data from a flow at a specific path.
309
+ * Set touch form single field
279
310
  *
280
311
  * @returns state
281
312
  */
282
- unsetData: ReducerFunctionSign<T, {
283
- id: string[] | string;
284
- flowName: string;
313
+ formFieldFocus: FormReducerFunctionSign<T, {
314
+ id: string;
315
+ focused?: boolean;
285
316
  }>;
286
317
  /**
287
318
  * @param state
288
319
  * @param action
289
320
  *
290
- * Sets the "isValidating" state of a form node in a flow.
321
+ * Removes errors from a form node in a flow.
291
322
  *
292
323
  * @returns state
293
324
  */
294
- setFormIsValidating: ReducerFunctionSign<T, {
295
- name: string;
296
- currentNode: string;
297
- isValidating?: boolean;
325
+ formRemoveErrors: FormReducerFunctionSign<T, {
326
+ id: string;
298
327
  }>;
299
328
  /**
300
329
  * @param state
301
330
  * @param action
302
331
  *
303
- * Handles node transitions in a flow, updating history and form states accordingly.
332
+ * Adds data to a flow.
304
333
  *
305
334
  * @returns state
306
335
  */
307
- node: ReducerFunctionSign<T, {
308
- name: string;
309
- flowName?: string;
310
- nodeId?: string;
311
- node?: string;
312
- history: string[];
336
+ addData: FormReducerFunctionSign<T, {
337
+ value: T;
313
338
  }>;
314
339
  /**
315
340
  * @param state
316
341
  * @param action
317
342
  *
318
- * Navigates to a specific node in the history of a flow.
343
+ * Adds data to a flow at a specific path.
319
344
  *
320
345
  * @returns state
321
346
  */
322
- prevToNode: ReducerFunctionSign<T, {
323
- name?: string;
324
- flowName?: string;
325
- node: string;
347
+ addDataByPath: FormReducerFunctionSign<T, {
348
+ id: string;
349
+ value: T | string;
350
+ dirty?: boolean;
326
351
  }>;
327
352
  /**
328
353
  * @param state
329
354
  * @param action
330
355
  *
331
- * Moves to the next node in a flow based on validation rules and current state.
356
+ * Replaces the data of a flow with new data.
332
357
  *
333
358
  * @returns state
334
359
  */
335
- next: ReducerFunctionSign<T, {
336
- name?: string;
337
- flowName?: string;
338
- data: T;
339
- route?: string;
360
+ replaceData: FormReducerFunctionSign<T, {
361
+ value: T;
340
362
  }>;
341
363
  /**
342
364
  * @param state
343
365
  * @param action
344
366
  *
345
- * Moves to the previous node in a flow.
367
+ * Unsets data from a flow at a specific path.
346
368
  *
347
369
  * @returns state
348
370
  */
349
- prev: ReducerFunctionSign<T, {
350
- name?: string;
351
- flowName?: string;
371
+ unsetData: FormReducerFunctionSign<T, {
372
+ id: string[] | string;
352
373
  }>;
353
374
  /**
354
375
  * @param state
355
376
  * @param action
356
377
  *
357
- * Return back to the first node and resets history.
378
+ * Sets the "isValidating" state of a form node in a flow.
358
379
  *
359
380
  * @returns state
360
381
  */
361
- restart: ReducerFunctionSign<T, {
362
- name?: string;
363
- flowName?: string;
382
+ setFormIsValidating: FormReducerFunctionSign<T, {
383
+ isValidating?: boolean;
364
384
  }>;
365
385
  /**
366
386
  * @param state
367
387
  * @param action
368
388
  *
369
- * Returns back to the first node, resets history and clean all previous data from flow.
389
+ * Reset form.
370
390
  *
371
391
  * @returns state
372
392
  */
373
- reset: ReducerFunctionSign<T, {
374
- name?: string;
375
- flowName?: string;
393
+ resetForm: FormReducerFunctionSign<T, {
394
+ formName: string;
376
395
  initialData?: Record<string, any>;
377
- }
396
+ }>;
378
397
  /**
379
398
  * @param state
380
399
  * @param action
@@ -383,10 +402,9 @@ export type ReducersFunctions<T extends Record<string, any> = Record<string, Flo
383
402
  *
384
403
  * @returns state
385
404
  */
386
- >;
387
- resetForm: ReducerFunctionSign<T, {
388
- id: string;
389
- flowName: string;
405
+ initForm: FormReducerFunctionSign<T, {
406
+ formName: string;
407
+ initialData: Record<string, any>;
390
408
  }>;
391
409
  };
392
410
  export {};
@@ -1,4 +1,4 @@
1
- import { RulesObject } from '../interfaces/CoreInterface';
1
+ import { RulesObject } from './CoreInterface';
2
2
  export type CheckTypeOf = (v: any) => boolean;
3
3
  export type CheckOperationObj = {
4
4
  op: keyof Operators;
@@ -1,12 +1,13 @@
1
+ import { REDUCER_NAME } from '../constants';
1
2
  import { RulesObject } from './CoreInterface';
2
3
  import { Flower, Form, INode } from './Store';
3
- export interface ISelectors {
4
+ export interface IFlowerSelectors {
4
5
  /**
5
6
  * @param state
6
7
  * @returns
7
8
  */
8
9
  selectGlobal<T extends Record<string, any>>(state: {
9
- flower: {
10
+ [REDUCER_NAME.FLOWER_FLOW]: {
10
11
  [x: string]: Flower<T>;
11
12
  };
12
13
  }): {
@@ -19,11 +20,6 @@ export interface ISelectors {
19
20
  selectFlower<T extends Record<string, any>>(name: string): (state: {
20
21
  [x: string]: Flower<T>;
21
22
  }) => Flower<T>;
22
- /**
23
- * @param id
24
- * @returns
25
- */
26
- selectFlowerFormNode<T extends Record<string, any>>(id: string): (state: Flower<T>) => Form<T>;
27
23
  /**
28
24
  * @param flower
29
25
  * @returns
@@ -60,6 +56,24 @@ export interface ISelectors {
60
56
  makeSelectCurrentNodeDisabled<T extends Record<string, any>>(nodes: {
61
57
  [x: string]: Partial<INode>;
62
58
  }, current: Flower<T>['current']): boolean;
59
+ }
60
+ export interface IFormSelectors {
61
+ /**
62
+ * @param state
63
+ * @returns
64
+ */
65
+ selectGlobalReducerByName(name: string): (state: Record<string, Record<string, unknown>>) => Record<string, unknown>;
66
+ /**
67
+ * @param state
68
+ * @returns
69
+ */
70
+ selectGlobalForm<T extends Record<string, any>>(state: {
71
+ [REDUCER_NAME.FLOWER_DATA]: {
72
+ [x: string]: Form<T>;
73
+ };
74
+ }): {
75
+ [x: string]: Form<T>;
76
+ };
63
77
  /**
64
78
  * @param form
65
79
  * @returns
@@ -88,11 +102,6 @@ export interface ISelectors {
88
102
  * @returns
89
103
  */
90
104
  makeSelectNodeFormFieldDirty<T extends Record<string, any>>(id: string): (form: Form<T> | undefined) => boolean | undefined;
91
- /**
92
- * @param flower
93
- * @returns
94
- */
95
- getDataByFlow<T extends Record<string, any>>(flower: Flower<T>): T;
96
105
  /**
97
106
  * @param id
98
107
  * @returns
@@ -1,9 +1,4 @@
1
1
  import { RulesByNodeId } from './CoreInterface';
2
- export interface StoreRoot<T extends Record<string, any>> {
3
- flower: {
4
- [x: string]: Flower<T>;
5
- };
6
- }
7
2
  export interface Flower<T extends Record<string, any>> {
8
3
  persist: boolean;
9
4
  startId: string;
@@ -15,10 +10,6 @@ export interface Flower<T extends Record<string, any>> {
15
10
  nextRules: {
16
11
  [x: string]: RulesByNodeId<T>[];
17
12
  };
18
- data: T;
19
- form: {
20
- [x: string]: Form<T>;
21
- };
22
13
  }
23
14
  export interface INode {
24
15
  nodeId: string;
@@ -26,7 +17,7 @@ export interface INode {
26
17
  retain?: boolean;
27
18
  disabled?: boolean;
28
19
  }
29
- export type Form<T> = {
20
+ export type Form<T extends Record<string, unknown>> = {
30
21
  isSubmitted?: boolean;
31
22
  isDirty?: boolean;
32
23
  hasFocus?: string;
@@ -43,4 +34,5 @@ export type Form<T> = {
43
34
  touches?: {
44
35
  [K in keyof T]: boolean;
45
36
  };
37
+ data?: T;
46
38
  };
@@ -14,7 +14,7 @@ export interface CoreStateUtils {
14
14
  * Selects the form node with a specific ID from a given flow.
15
15
  * It returns a selector function that accepts the state as an argument and retrieves the form node
16
16
  */
17
- selectFlowerFormNode<T extends object>(name: string, id: string): (state: T) => Record<string, any>;
17
+ selectFlowerFormNode<T extends object>(name: string): (state: T) => Record<string, any>;
18
18
  /**
19
19
  *
20
20
  * @param name
@@ -1,5 +1,8 @@
1
1
  export * from './CoreInterface';
2
+ export * from './EmitterInterface';
3
+ export * from './FlatInterface';
2
4
  export * from './ReducerInterface';
5
+ export * from './RulesMatcherInterface';
3
6
  export * from './SelectorsInterface';
4
7
  export * from './Store';
5
8
  export * from './UtilsInterface';
@@ -0,0 +1,2 @@
1
+ import { FunctionRule } from '../interfaces';
2
+ export declare const rulesMatcher: (rules?: Record<string, any> | Record<string, any>[] | FunctionRule, formValue?: Record<string, any>, apply?: boolean, options?: Record<string, any>) => boolean[];
@@ -0,0 +1,2 @@
1
+ export { rulesMatcher } from './RulesMatcher';
2
+ export { rulesMatcherUtils } from './utils';
@@ -1,6 +1,5 @@
1
- import { RulesMatcherUtils } from './interface';
1
+ import { RulesMatcherUtils } from '../interfaces';
2
2
  /**
3
3
  * Defines a utility object named rulesMatcherUtils, which contains various helper functions used for processing rules and data in a rule-matching context.
4
4
  */
5
- declare const rulesMatcherUtils: RulesMatcherUtils;
6
- export default rulesMatcherUtils;
5
+ export declare const rulesMatcherUtils: RulesMatcherUtils;
@@ -0,0 +1,2 @@
1
+ export * from './state-functions';
2
+ export * from './state-selectors';
@@ -0,0 +1,2 @@
1
+ import { CoreReducersFunctions, FormReducersFunctions } from '../../interfaces';
2
+ export declare const FlowerCoreReducers: FormReducersFunctions & CoreReducersFunctions;
@@ -0,0 +1,5 @@
1
+ import { CoreReducersFunctions } from '../../interfaces/ReducerInterface';
2
+ /**
3
+ * These functions are Redux reducers used in a Flux architecture for managing state transitions and updates in a Flower application.
4
+ */
5
+ export declare const FlowerCoreBaseReducers: CoreReducersFunctions;
@@ -0,0 +1,13 @@
1
+ import { FormReducersFunctions } from '../../interfaces/ReducerInterface';
2
+ /**
3
+ * formName => FlowerForm
4
+ * initialData => FlowerForm
5
+ * fieldName => FlowerField
6
+ * fieldValue => FlowerField
7
+ * errors => FlowerField
8
+ * customErrors => FlowerField
9
+ * fieldTouched => FlowerField
10
+ * fieldDirty => FlowerField
11
+ * fieldHasFocus => FlowerField
12
+ */
13
+ export declare const FlowerCoreDataReducers: FormReducersFunctions;
@@ -0,0 +1,4 @@
1
+ export type { CoreReducersFunctions, FormReducersFunctions } from '../../interfaces';
2
+ export { FlowerCoreBaseReducers } from './FlowerCoreStateFunctions';
3
+ export { FlowerCoreDataReducers } from './FlowerDataStateFunctions';
4
+ export { FlowerCoreReducers } from './FlowerCoreMergedReducers';
@@ -0,0 +1,2 @@
1
+ import { IFlowerSelectors } from '../../interfaces/SelectorsInterface';
2
+ export declare const FlowerCoreStateBaseSelectors: IFlowerSelectors;
@@ -0,0 +1,2 @@
1
+ import { IFormSelectors } from '../../interfaces';
2
+ export declare const FlowerCoreStateDataSelectors: IFormSelectors;
@@ -0,0 +1,2 @@
1
+ import { IFlowerSelectors, IFormSelectors } from '../../interfaces';
2
+ export declare const FlowerCoreStateSelectors: IFlowerSelectors & IFormSelectors;