@rolster/react-forms 18.10.3 → 18.11.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.
package/dist/es/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { createFormControlOptions, createFormGroupOptions, createFormArrayOptions } from '@rolster/forms/arguments';
2
- import { controlIsValid, hasError, someErrors, groupIsValid, controlsAllChecked, controlsPartialChecked, controlsToValue, arrayIsValid, groupAllChecked, groupPartialChecked } from '@rolster/forms/helpers';
2
+ import { controlIsValid, hasError, someErrors, groupIsValid, controlsAllChecked, controlsPartialChecked, controlsToValue, groupAllChecked, arrayIsValid, reduceControlsToArray } from '@rolster/forms/helpers';
3
3
  import { v4 } from 'uuid';
4
4
  import { useRef, useState, useEffect, useCallback } from 'react';
5
5
 
@@ -113,13 +113,13 @@ class RolsterArrayGroup {
113
113
  this.errors.length === 0 && controlsAllChecked(controls, 'valid');
114
114
  this.invalid = !this.valid;
115
115
  this.dirty = controlsPartialChecked(controls, 'dirty');
116
- this.dirtyAll = controlsAllChecked(controls, 'dirty');
116
+ this.dirties = controlsAllChecked(controls, 'dirty');
117
117
  this.touched = controlsPartialChecked(controls, 'touched');
118
- this.touchedAll = controlsAllChecked(controls, 'touched');
119
- this.untouched = !this.touched;
120
- this.untouchedAll = !this.touchedAll;
118
+ this.toucheds = controlsAllChecked(controls, 'touched');
121
119
  this.pristine = !this.dirty;
122
- this.pristineAll = !this.dirtyAll;
120
+ this.pristines = !this.dirties;
121
+ this.untouched = !this.touched;
122
+ this.untoucheds = !this.toucheds;
123
123
  this.wrong = this.touched && this.invalid;
124
124
  this.value = controlsToValue(controls);
125
125
  const subscriber = (options) => {
@@ -216,57 +216,53 @@ function formArrayList(valueToControls, options) {
216
216
  });
217
217
  }
218
218
 
219
+ function errorsInArray(groups, validators) {
220
+ return validators ? arrayIsValid({ groups, validators }) : [];
221
+ }
222
+ function validStateInArray(groups, validators) {
223
+ const errors = errorsInArray(groups, validators);
224
+ return {
225
+ errors,
226
+ valid: errors.length === 0 && groupAllChecked(groups, 'valid')
227
+ };
228
+ }
229
+ function replaceStateInArray(groups, validators) {
230
+ return {
231
+ ...validStateInArray(groups, validators),
232
+ groups,
233
+ controls: groups.map(({ controls }) => controls),
234
+ value: groups.map(({ controls }) => controlsToValue(controls))
235
+ };
236
+ }
219
237
  function useFormArray(options, validators) {
220
238
  const _options = createFormArrayOptions(options, validators);
221
239
  const groups = _options.groups || [];
222
- const _value = useRef(groups);
240
+ const initialValue = useRef(groups);
223
241
  const [state, setState] = useState({
242
+ ...validStateInArray(groups, _options.validators),
224
243
  controls: groups.map(({ controls }) => controls),
244
+ dirty: false,
245
+ dirties: false,
225
246
  disabled: false,
226
247
  groups,
248
+ touched: false,
249
+ toucheds: false,
227
250
  value: groups.map(({ controls }) => controlsToValue(controls)),
228
251
  validators: _options.validators
229
252
  });
230
- const [errors, setErrors] = useState([]);
231
- const [controlState, setControlState] = useState({
232
- valid: false,
233
- dirty: false,
234
- dirtyAll: false,
235
- touched: false,
236
- touchedAll: false
237
- });
238
253
  useEffect(() => {
239
254
  const subscriber = (options) => {
240
- setValue(state.groups.map((group) => group.uuid === options.uuid
241
- ? new RolsterArrayGroup(options)
242
- : group));
255
+ setState((state) => ({
256
+ ...state,
257
+ ...replaceStateInArray(state.groups.map((group) => group.uuid === options.uuid
258
+ ? new RolsterArrayGroup(options)
259
+ : group), state.validators)
260
+ }));
243
261
  };
244
262
  state.groups.forEach((group) => {
245
263
  group.subscribe(subscriber);
246
264
  });
247
- setState((_state) => ({
248
- ..._state,
249
- controls: state.groups.map(({ controls }) => controls),
250
- value: state.groups.map(({ controls }) => controlsToValue(controls))
251
- }));
252
265
  }, [state.groups]);
253
- useEffect(() => {
254
- setErrors(state.validators
255
- ? arrayIsValid({
256
- groups: state.groups,
257
- validators: state.validators
258
- })
259
- : []);
260
- }, [state.groups, state.validators]);
261
- useEffect(() => {
262
- setControlState({
263
- valid: errors.length === 0 && groupAllChecked(state.groups, 'valid'),
264
- dirty: groupPartialChecked(state.groups, 'dirty'),
265
- dirtyAll: groupAllChecked(state.groups, 'dirty'),
266
- touched: groupPartialChecked(state.groups, 'touched'),
267
- touchedAll: groupAllChecked(state.groups, 'touched')
268
- });
269
- }, [state.groups, errors]);
270
266
  const disable = useCallback(() => {
271
267
  setState((state) => ({ ...state, disabled: true }));
272
268
  }, []);
@@ -274,45 +270,62 @@ function useFormArray(options, validators) {
274
270
  setState((state) => ({ ...state, disabled: false }));
275
271
  }, []);
276
272
  const setValue = useCallback((groups) => {
277
- setState((state) => ({ ...state, groups }));
273
+ setState((state) => ({
274
+ ...state,
275
+ ...replaceStateInArray(groups, state.validators)
276
+ }));
278
277
  }, []);
279
278
  const setInitialValue = useCallback((groups) => {
280
- setState((state) => ({ ...state, groups }));
281
- _value.current = groups;
279
+ setState((state) => ({
280
+ ...state,
281
+ ...replaceStateInArray(groups, state.validators)
282
+ }));
283
+ initialValue.current = groups;
282
284
  }, []);
283
285
  const push = useCallback((group) => {
284
- setState((state) => ({ ...state, groups: [...state.groups, group] }));
286
+ setState((state) => ({
287
+ ...state,
288
+ ...replaceStateInArray([...state.groups, group], state.validators)
289
+ }));
285
290
  }, []);
286
291
  const merge = useCallback((groups) => {
287
- setState((state) => ({ ...state, groups: [...state.groups, ...groups] }));
292
+ setState((state) => ({
293
+ ...state,
294
+ ...replaceStateInArray([...state.groups, ...groups], state.validators)
295
+ }));
288
296
  }, []);
289
297
  const remove = useCallback(({ uuid }) => {
290
298
  setState((state) => ({
291
299
  ...state,
292
- groups: state.groups.filter((group) => group.uuid !== uuid)
300
+ ...replaceStateInArray(state.groups.filter((group) => group.uuid !== uuid), state.validators)
293
301
  }));
294
302
  }, []);
295
303
  const reset = useCallback(() => {
296
- setState((state) => ({ ...state, groups: _value.current }));
304
+ setState((state) => ({
305
+ ...state,
306
+ ...replaceStateInArray(initialValue.current, state.validators)
307
+ }));
297
308
  }, []);
298
309
  const setValidators = useCallback((validators) => {
299
- setState((state) => ({ ...state, validators }));
310
+ setState((state) => ({
311
+ ...state,
312
+ ...validStateInArray(state.groups, validators),
313
+ validators
314
+ }));
300
315
  }, []);
301
- const hasError$1 = useCallback((key) => hasError(errors, key), [errors]);
302
- const someErrors$1 = useCallback((keys) => someErrors(errors, keys), [errors]);
316
+ const hasError$1 = useCallback((key) => hasError(state.errors, key), [state.errors]);
317
+ const someErrors$1 = useCallback((keys) => someErrors(state.errors, keys), [state.errors]);
303
318
  return {
304
319
  ...state,
305
- ...controlState,
306
320
  disable,
307
321
  enable,
308
322
  enabled: !state.disabled,
309
- error: errors[0],
310
- errors: errors,
323
+ error: state.errors[0],
311
324
  hasError: hasError$1,
312
- invalid: !controlState.valid,
325
+ invalid: !state.valid,
313
326
  merge,
314
- pristine: !controlState.dirty,
315
- pristineAll: !controlState.dirtyAll,
327
+ pristine: !state.dirty,
328
+ pristines: !state.dirties,
316
329
  push,
317
330
  remove,
318
331
  reset,
@@ -320,33 +333,28 @@ function useFormArray(options, validators) {
320
333
  setValidators,
321
334
  setValue,
322
335
  someErrors: someErrors$1,
323
- untouched: !controlState.touched,
324
- untouchedAll: !controlState.touchedAll,
325
- wrong: controlState.touched && !controlState.valid
336
+ untouched: !state.touched,
337
+ untoucheds: !state.toucheds,
338
+ wrong: state.touched && !state.valid
326
339
  };
327
340
  }
328
341
 
342
+ function errorsInControl(value, validators) {
343
+ return validators ? controlIsValid({ value, validators }) : [];
344
+ }
329
345
  function useControl(options, validators) {
330
346
  const _options = createFormControlOptions(options, validators);
347
+ const initialValue = useRef(_options.value);
331
348
  const [state, setState] = useState({
332
349
  dirty: false,
333
350
  disabled: false,
351
+ errors: errorsInControl(_options.value, _options.validators),
334
352
  focused: false,
335
353
  touched: !!_options.touched,
336
- validators: _options.validators,
337
- value: _options.value
354
+ value: _options.value,
355
+ validators: _options.validators
338
356
  });
339
- const [errors, setErrors] = useState([]);
340
- const initialValue = useRef(_options.value);
341
357
  const elementRef = useRef(null);
342
- useEffect(() => {
343
- setErrors(state.validators
344
- ? controlIsValid({
345
- value: state.value,
346
- validators: state.validators
347
- })
348
- : []);
349
- }, [state.value, state.validators]);
350
358
  const focus = useCallback(() => {
351
359
  setState((state) => ({ ...state, focused: true }));
352
360
  }, []);
@@ -364,25 +372,40 @@ function useControl(options, validators) {
364
372
  }, []);
365
373
  const setInitialValue = useCallback((value) => {
366
374
  initialValue.current = value;
367
- setState((state) => ({ ...state, dirty: true, value }));
375
+ setState((state) => ({
376
+ ...state,
377
+ dirty: true,
378
+ errors: errorsInControl(value, state.validators),
379
+ value
380
+ }));
368
381
  }, []);
369
382
  const setValue = useCallback((value) => {
370
- setState((state) => ({ ...state, dirty: true, value }));
383
+ setState((state) => ({
384
+ ...state,
385
+ dirty: true,
386
+ errors: errorsInControl(value, state.validators),
387
+ value
388
+ }));
371
389
  }, []);
372
390
  const setValidators = useCallback((validators) => {
373
- setState((state) => ({ ...state, validators }));
391
+ setState((state) => ({
392
+ ...state,
393
+ errors: errorsInControl(state.value, validators),
394
+ validators
395
+ }));
374
396
  }, []);
375
397
  const reset = useCallback(() => {
376
398
  setState((state) => ({
377
399
  ...state,
378
400
  dirty: false,
401
+ errors: errorsInControl(initialValue.current, state.validators),
379
402
  value: initialValue.current,
380
403
  touched: false
381
404
  }));
382
405
  }, []);
383
- const hasError$1 = useCallback((key) => hasError(errors, key), [errors]);
384
- const someErrors$1 = useCallback((keys) => someErrors(errors, keys), [errors]);
385
- const valid = errors.length === 0;
406
+ const hasError$1 = useCallback((key) => hasError(state.errors, key), [state.errors]);
407
+ const someErrors$1 = useCallback((keys) => someErrors(state.errors, keys), [state.errors]);
408
+ const valid = state.errors.length === 0;
386
409
  return {
387
410
  ...state,
388
411
  blur,
@@ -390,8 +413,7 @@ function useControl(options, validators) {
390
413
  elementRef,
391
414
  enable,
392
415
  enabled: !state.disabled,
393
- error: errors[0],
394
- errors,
416
+ error: state.errors[0],
395
417
  focus,
396
418
  hasError: hasError$1,
397
419
  invalid: !valid,
@@ -418,46 +440,84 @@ function useInputControl(options, validators) {
418
440
  return useControl(options, validators);
419
441
  }
420
442
 
421
- function useFormGroup(options, groupValidators) {
422
- const _options = createFormGroupOptions(options, groupValidators);
423
- const [validators, setValidators] = useState(_options.validators);
443
+ function errorsInGroup(controls, validators) {
444
+ return validators ? groupIsValid({ controls, validators }) : [];
445
+ }
446
+ function validStateInGroup(controls, validators) {
447
+ const errors = errorsInGroup(controls, validators);
448
+ return {
449
+ errors,
450
+ valid: errors.length === 0 && controlsAllChecked(controls, 'valid')
451
+ };
452
+ }
453
+ function useFormGroup(options, validators) {
454
+ const _options = createFormGroupOptions(options, validators);
424
455
  const { controls } = _options;
425
- const errors = validators ? groupIsValid({ controls, validators }) : [];
426
- const valid = errors.length === 0 && controlsAllChecked(controls, 'valid');
427
- const value = controlsToValue(controls);
428
- const dirty = controlsPartialChecked(controls, 'dirty');
429
- const dirtyAll = controlsAllChecked(controls, 'dirty');
430
- const touched = controlsPartialChecked(controls, 'touched');
431
- const touchedAll = controlsAllChecked(controls, 'touched');
432
- function reset() {
456
+ const [state, setState] = useState({
457
+ ...validStateInGroup(controls, _options.validators),
458
+ controls,
459
+ dirties: controlsAllChecked(controls, 'dirty'),
460
+ dirty: controlsPartialChecked(controls, 'dirty'),
461
+ touched: controlsPartialChecked(controls, 'touched'),
462
+ toucheds: controlsAllChecked(controls, 'touched'),
463
+ value: controlsToValue(controls),
464
+ validators: _options.validators
465
+ });
466
+ useEffect(() => {
467
+ setState((state) => ({
468
+ ...state,
469
+ controls,
470
+ dirty: controlsPartialChecked(controls, 'dirty'),
471
+ dirties: controlsAllChecked(controls, 'dirty')
472
+ }));
473
+ }, reduceControlsToArray(controls, 'dirty'));
474
+ useEffect(() => {
475
+ setState((state) => ({
476
+ ...state,
477
+ controls,
478
+ touched: controlsPartialChecked(controls, 'touched'),
479
+ toucheds: controlsAllChecked(controls, 'touched')
480
+ }));
481
+ }, reduceControlsToArray(controls, 'touched'));
482
+ useEffect(() => {
483
+ setState((state) => ({
484
+ ...state,
485
+ ...validStateInGroup(controls, state.validators),
486
+ controls,
487
+ value: controlsToValue(controls)
488
+ }));
489
+ }, reduceControlsToArray(controls, 'value'));
490
+ const setValidators = useCallback((validators) => {
491
+ setState((state) => ({
492
+ ...state,
493
+ ...validStateInGroup(state.controls, validators)
494
+ }));
495
+ }, []);
496
+ const reset = useCallback(() => {
433
497
  Object.values(controls).forEach((control) => {
434
498
  control.reset();
435
499
  });
436
- }
500
+ }, []);
437
501
  return {
438
- controls,
439
- dirty,
440
- dirtyAll,
441
- error: errors[0],
442
- errors,
443
- invalid: !valid,
444
- pristine: !dirty,
445
- pristineAll: !dirtyAll,
502
+ ...state,
503
+ error: state.errors[0],
504
+ invalid: !state.valid,
505
+ pristine: !state.dirty,
506
+ pristines: !state.dirties,
446
507
  reset,
447
508
  setValidators,
448
- touched,
449
- touchedAll,
450
- untouched: !touched,
451
- untouchedAll: !touchedAll,
452
- valid,
453
- value,
454
- wrong: touched && !valid
509
+ untouched: !state.touched,
510
+ untoucheds: !state.toucheds,
511
+ wrong: state.touched && !state.valid
455
512
  };
456
513
  }
457
514
 
458
- function formGroupToArray({ controls }) {
459
- return Object.values(controls).map(({ value }) => value);
515
+ function reduceControlsToValues(controls) {
516
+ return reduceControlsToArray(controls, 'value');
517
+ }
518
+ function reduceGroupToValues(group) {
519
+ return reduceControlsToValues(group.controls);
460
520
  }
461
521
 
462
- export { formArrayControl, formArrayGroup, formArrayList, formGroupToArray, inputArrayControl, reactArrayControl, useFormArray, useFormControl, useFormGroup, useInputControl, useReactControl };
522
+ export { formArrayControl, formArrayGroup, formArrayList, inputArrayControl, reactArrayControl, reduceControlsToValues, reduceGroupToValues, useFormArray, useFormControl, useFormGroup, useInputControl, useReactControl };
463
523
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../esm/form-array/form-array-control.js","../esm/form-array/form-array-group.js","../esm/form-array/form-array-list.js","../esm/form-array/form-array.js","../esm/form-control.js","../esm/form-group.js","../esm/helpers.js"],"sourcesContent":["import { createFormControlOptions } from '@rolster/forms/arguments';\nimport { controlIsValid, hasError, someErrors } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nexport class RolsterReactArrayControl {\n constructor(options) {\n this.initialValue = options.initialValue;\n this.uuid = options.uuid;\n this.focused = !!options.focused;\n this.unfocused = !this.focused;\n this.touched = !!options.touched;\n this.untouched = !this.touched;\n this.dirty = !!options.dirty;\n this.pristine = !this.dirty;\n this.disabled = !!options.disabled;\n this.enabled = !this.disabled;\n const { value, validators } = options;\n this.value = value;\n this.validators = validators;\n this.errors = validators ? controlIsValid({ value, validators }) : [];\n this.error = this.errors[0];\n }\n focus() {\n this.unfocused && this.refresh({ focused: true });\n }\n blur() {\n this.focused && this.refresh({ focused: false, touched: true });\n }\n disable() {\n this.enabled && this.refresh({ disabled: true });\n }\n enable() {\n this.disabled && this.refresh({ disabled: false });\n }\n touch() {\n this.untouched && this.refresh({ touched: true });\n }\n setInitialValue(value) {\n this.initialValue = value;\n this.setValue(value);\n }\n setValue(value) {\n this.refresh({ value });\n }\n setValidators(validators) {\n this.refresh({ validators });\n }\n subscribe(subscriber) {\n this.subscriber = subscriber;\n }\n hasError(key) {\n return hasError(this.errors, key);\n }\n someErrors(keys) {\n return someErrors(this.errors, keys);\n }\n reset() {\n this.refresh({\n dirty: false,\n touched: false,\n value: this.initialValue\n });\n }\n refresh(changes) {\n this.subscriber &&\n this.subscriber({\n ...this,\n ...changes,\n initialValue: this.initialValue\n });\n }\n}\nexport class RolsterArrayControl extends RolsterReactArrayControl {\n constructor(options) {\n super(options);\n this.valid = this.errors.length === 0;\n this.invalid = !this.valid;\n this.wrong = this.touched && this.invalid;\n }\n clone(options) {\n return new RolsterArrayControl(options);\n }\n}\nfunction rolsterArrayControl(options, validators) {\n const controlOptions = createFormControlOptions(options, validators);\n return new RolsterArrayControl({\n ...controlOptions,\n initialValue: controlOptions.value,\n uuid: uuid()\n });\n}\nexport function reactArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\nexport function formArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\nexport function inputArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\n//# sourceMappingURL=form-array-control.js.map","import { createFormGroupOptions } from '@rolster/forms/arguments';\nimport { controlsAllChecked, controlsPartialChecked, controlsToValue, groupIsValid } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nexport class RolsterArrayGroup {\n constructor(options) {\n const { controls, resource, uuid, validators } = options;\n this.uuid = uuid;\n this.controls = controls;\n this.validators = validators;\n this.resource = resource;\n this.errors = validators ? groupIsValid({ controls, validators }) : [];\n this.error = this.errors[0];\n this.valid =\n this.errors.length === 0 && controlsAllChecked(controls, 'valid');\n this.invalid = !this.valid;\n this.dirty = controlsPartialChecked(controls, 'dirty');\n this.dirtyAll = controlsAllChecked(controls, 'dirty');\n this.touched = controlsPartialChecked(controls, 'touched');\n this.touchedAll = controlsAllChecked(controls, 'touched');\n this.untouched = !this.touched;\n this.untouchedAll = !this.touchedAll;\n this.pristine = !this.dirty;\n this.pristineAll = !this.dirtyAll;\n this.wrong = this.touched && this.invalid;\n this.value = controlsToValue(controls);\n const subscriber = (options) => {\n this.refresh({\n controls: Object.entries(this.controls).reduce((controls, [key, control]) => {\n controls[key] =\n control.uuid === options.uuid ? control.clone(options) : control;\n return controls;\n }, {})\n });\n };\n Object.values(controls).forEach((control) => {\n control.subscribe(subscriber);\n });\n }\n setValidators(validators) {\n this.refresh({ validators });\n }\n subscribe(subscriber) {\n this.subscriber = subscriber;\n }\n refresh(changes) {\n this.subscriber && this.subscriber({ ...this, ...changes });\n }\n}\nexport function formArrayGroup(options, validators) {\n return new RolsterArrayGroup({\n ...createFormGroupOptions(options, validators),\n uuid: uuid()\n });\n}\n//# sourceMappingURL=form-array-group.js.map","import { controlsAllChecked, controlsToValue } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nimport { RolsterReactArrayControl } from './form-array-control';\nexport class RolsterArrayList extends RolsterReactArrayControl {\n constructor(options) {\n const value = options.controls.map((controls) => controlsToValue(controls));\n super({ ...options, value });\n this.valueToControls = options.valueToControls;\n this.controls = options.controls;\n this.valid =\n this.errors.length === 0 &&\n this.controls.reduce((valid, controls) => valid && controlsAllChecked(controls, 'valid'), true);\n this.invalid = !this.valid;\n this.wrong = this.touched && this.invalid;\n options.controls.forEach((controls) => {\n this.subscribeControls(controls);\n });\n }\n setValue(value) {\n this.refresh({\n controls: value.map((value) => this.valueToControls(value))\n });\n }\n clone(options) {\n return new RolsterArrayList(options);\n }\n push(controls) {\n this.refresh({\n controls: [...this.controls, controls]\n });\n }\n remove(controls) {\n this.refresh({\n controls: this.controls.filter((currentControls) => currentControls !== controls)\n });\n }\n refresh(changes) {\n super.refresh(changes);\n }\n subscribeControls(newControls) {\n Object.values(newControls).forEach((control) => {\n control.subscribe((options) => {\n const controls = this.controls.map((_controls) => _controls !== newControls\n ? _controls\n : Object.entries(newControls).reduce((controls, [key, control]) => {\n controls[key] =\n control.uuid === options.uuid\n ? control.clone(options)\n : control;\n return controls;\n }, {}));\n this.refresh({ controls });\n });\n });\n }\n}\nexport function formArrayList(valueToControls, options) {\n const value = options?.value || [];\n return new RolsterArrayList({\n ...options,\n valueToControls,\n controls: value.map((value) => valueToControls(value)),\n initialValue: value,\n uuid: uuid()\n });\n}\n//# sourceMappingURL=form-array-list.js.map","import { createFormArrayOptions } from '@rolster/forms/arguments';\nimport { arrayIsValid, controlsToValue, groupAllChecked, groupPartialChecked, hasError as rolsterHasError, someErrors as rolsterSomeErrors } from '@rolster/forms/helpers';\nimport { useCallback, useEffect, useRef, useState } from 'react';\nimport { RolsterArrayGroup } from './form-array-group';\nexport function useFormArray(options, validators) {\n const _options = createFormArrayOptions(options, validators);\n const groups = _options.groups || [];\n const _value = useRef(groups);\n const [state, setState] = useState({\n controls: groups.map(({ controls }) => controls),\n disabled: false,\n groups,\n value: groups.map(({ controls }) => controlsToValue(controls)),\n validators: _options.validators\n });\n const [errors, setErrors] = useState([]);\n const [controlState, setControlState] = useState({\n valid: false,\n dirty: false,\n dirtyAll: false,\n touched: false,\n touchedAll: false\n });\n useEffect(() => {\n const subscriber = (options) => {\n setValue(state.groups.map((group) => group.uuid === options.uuid\n ? new RolsterArrayGroup(options)\n : group));\n };\n state.groups.forEach((group) => {\n group.subscribe(subscriber);\n });\n setState((_state) => ({\n ..._state,\n controls: state.groups.map(({ controls }) => controls),\n value: state.groups.map(({ controls }) => controlsToValue(controls))\n }));\n }, [state.groups]);\n useEffect(() => {\n setErrors(state.validators\n ? arrayIsValid({\n groups: state.groups,\n validators: state.validators\n })\n : []);\n }, [state.groups, state.validators]);\n useEffect(() => {\n setControlState({\n valid: errors.length === 0 && groupAllChecked(state.groups, 'valid'),\n dirty: groupPartialChecked(state.groups, 'dirty'),\n dirtyAll: groupAllChecked(state.groups, 'dirty'),\n touched: groupPartialChecked(state.groups, 'touched'),\n touchedAll: groupAllChecked(state.groups, 'touched')\n });\n }, [state.groups, errors]);\n const disable = useCallback(() => {\n setState((state) => ({ ...state, disabled: true }));\n }, []);\n const enable = useCallback(() => {\n setState((state) => ({ ...state, disabled: false }));\n }, []);\n const setValue = useCallback((groups) => {\n setState((state) => ({ ...state, groups }));\n }, []);\n const setInitialValue = useCallback((groups) => {\n setState((state) => ({ ...state, groups }));\n _value.current = groups;\n }, []);\n const push = useCallback((group) => {\n setState((state) => ({ ...state, groups: [...state.groups, group] }));\n }, []);\n const merge = useCallback((groups) => {\n setState((state) => ({ ...state, groups: [...state.groups, ...groups] }));\n }, []);\n const remove = useCallback(({ uuid }) => {\n setState((state) => ({\n ...state,\n groups: state.groups.filter((group) => group.uuid !== uuid)\n }));\n }, []);\n const reset = useCallback(() => {\n setState((state) => ({ ...state, groups: _value.current }));\n }, []);\n const setValidators = useCallback((validators) => {\n setState((state) => ({ ...state, validators }));\n }, []);\n const hasError = useCallback((key) => rolsterHasError(errors, key), [errors]);\n const someErrors = useCallback((keys) => rolsterSomeErrors(errors, keys), [errors]);\n return {\n ...state,\n ...controlState,\n disable,\n enable,\n enabled: !state.disabled,\n error: errors[0],\n errors: errors,\n hasError,\n invalid: !controlState.valid,\n merge,\n pristine: !controlState.dirty,\n pristineAll: !controlState.dirtyAll,\n push,\n remove,\n reset,\n setInitialValue,\n setValidators,\n setValue,\n someErrors,\n untouched: !controlState.touched,\n untouchedAll: !controlState.touchedAll,\n wrong: controlState.touched && !controlState.valid\n };\n}\n//# sourceMappingURL=form-array.js.map","import { createFormControlOptions } from '@rolster/forms/arguments';\nimport { controlIsValid, hasError as rolsterHasError, someErrors as rolsterSomeErrors } from '@rolster/forms/helpers';\nimport { useCallback, useEffect, useRef, useState } from 'react';\nfunction useControl(options, validators) {\n const _options = createFormControlOptions(options, validators);\n const [state, setState] = useState({\n dirty: false,\n disabled: false,\n focused: false,\n touched: !!_options.touched,\n validators: _options.validators,\n value: _options.value\n });\n const [errors, setErrors] = useState([]);\n const initialValue = useRef(_options.value);\n const elementRef = useRef(null);\n useEffect(() => {\n setErrors(state.validators\n ? controlIsValid({\n value: state.value,\n validators: state.validators\n })\n : []);\n }, [state.value, state.validators]);\n const focus = useCallback(() => {\n setState((state) => ({ ...state, focused: true }));\n }, []);\n const blur = useCallback(() => {\n setState((state) => ({ ...state, focused: false, touched: true }));\n }, []);\n const disable = useCallback(() => {\n setState((state) => ({ ...state, disabled: true }));\n }, []);\n const enable = useCallback(() => {\n setState((state) => ({ ...state, disabled: false }));\n }, []);\n const touch = useCallback(() => {\n setState((state) => ({ ...state, touched: true }));\n }, []);\n const setInitialValue = useCallback((value) => {\n initialValue.current = value;\n setState((state) => ({ ...state, dirty: true, value }));\n }, []);\n const setValue = useCallback((value) => {\n setState((state) => ({ ...state, dirty: true, value }));\n }, []);\n const setValidators = useCallback((validators) => {\n setState((state) => ({ ...state, validators }));\n }, []);\n const reset = useCallback(() => {\n setState((state) => ({\n ...state,\n dirty: false,\n value: initialValue.current,\n touched: false\n }));\n }, []);\n const hasError = useCallback((key) => rolsterHasError(errors, key), [errors]);\n const someErrors = useCallback((keys) => rolsterSomeErrors(errors, keys), [errors]);\n const valid = errors.length === 0;\n return {\n ...state,\n blur,\n disable,\n elementRef,\n enable,\n enabled: !state.disabled,\n error: errors[0],\n errors,\n focus,\n hasError,\n invalid: !valid,\n pristine: !state.dirty,\n reset,\n setInitialValue,\n setValidators,\n setValue,\n someErrors,\n touch,\n unfocused: !state.focused,\n untouched: !state.touched,\n valid,\n wrong: state.touched && !valid\n };\n}\nexport function useReactControl(options, validators) {\n return useControl(options, validators);\n}\nexport function useFormControl(options, validators) {\n return useControl(options, validators);\n}\nexport function useInputControl(options, validators) {\n return useControl(options, validators);\n}\n//# sourceMappingURL=form-control.js.map","import { createFormGroupOptions } from '@rolster/forms/arguments';\nimport { controlsAllChecked, controlsPartialChecked, controlsToValue, groupIsValid } from '@rolster/forms/helpers';\nimport { useState } from 'react';\nexport function useFormGroup(options, groupValidators) {\n const _options = createFormGroupOptions(options, groupValidators);\n const [validators, setValidators] = useState(_options.validators);\n const { controls } = _options;\n const errors = validators ? groupIsValid({ controls, validators }) : [];\n const valid = errors.length === 0 && controlsAllChecked(controls, 'valid');\n const value = controlsToValue(controls);\n const dirty = controlsPartialChecked(controls, 'dirty');\n const dirtyAll = controlsAllChecked(controls, 'dirty');\n const touched = controlsPartialChecked(controls, 'touched');\n const touchedAll = controlsAllChecked(controls, 'touched');\n function reset() {\n Object.values(controls).forEach((control) => {\n control.reset();\n });\n }\n return {\n controls,\n dirty,\n dirtyAll,\n error: errors[0],\n errors,\n invalid: !valid,\n pristine: !dirty,\n pristineAll: !dirtyAll,\n reset,\n setValidators,\n touched,\n touchedAll,\n untouched: !touched,\n untouchedAll: !touchedAll,\n valid,\n value,\n wrong: touched && !valid\n };\n}\n//# sourceMappingURL=form-group.js.map","export function formGroupToArray({ controls }) {\n return Object.values(controls).map(({ value }) => value);\n}\n//# sourceMappingURL=helpers.js.map"],"names":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B,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC;AAChE,IAAI,MAAM,UAAU,GAAG,kBAAkB,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC;AAC/D,IAAI,SAAS,KAAK,GAAG;AACrB,QAAQ,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,CAAC,OAAO,KAAK;AACrD,YAAY,OAAO,CAAC,KAAK,EAAE,CAAC;AAC5B,SAAS,CAAC,CAAC;AACX,KAAK;AACL,IAAI,OAAO;AACX,QAAQ,QAAQ;AAChB,QAAQ,KAAK;AACb,QAAQ,QAAQ;AAChB,QAAQ,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACxB,QAAQ,MAAM;AACd,QAAQ,OAAO,EAAE,CAAC,KAAK;AACvB,QAAQ,QAAQ,EAAE,CAAC,KAAK;AACxB,QAAQ,WAAW,EAAE,CAAC,QAAQ;AAC9B,QAAQ,KAAK;AACb,QAAQ,aAAa;AACrB,QAAQ,OAAO;AACf,QAAQ,UAAU;AAClB,QAAQ,SAAS,EAAE,CAAC,OAAO;AAC3B,QAAQ,YAAY,EAAE,CAAC,UAAU;AACjC,QAAQ,KAAK;AACb,QAAQ,KAAK;AACb,QAAQ,KAAK,EAAE,OAAO,IAAI,CAAC,KAAK;AAChC,KAAK,CAAC;AACN;;ACtCO,SAAS,gBAAgB,CAAC,EAAE,QAAQ,EAAE,EAAE;AAC/C,IAAI,OAAO,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,KAAK,CAAC,CAAC;AAC7D;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../esm/form-array/form-array-control.js","../esm/form-array/form-array-group.js","../esm/form-array/form-array-list.js","../esm/form-array/form-array.js","../esm/form-control.js","../esm/form-group.js","../esm/helpers.js"],"sourcesContent":["import { createFormControlOptions } from '@rolster/forms/arguments';\nimport { controlIsValid, hasError, someErrors } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nexport class RolsterReactArrayControl {\n constructor(options) {\n this.initialValue = options.initialValue;\n this.uuid = options.uuid;\n this.focused = !!options.focused;\n this.unfocused = !this.focused;\n this.touched = !!options.touched;\n this.untouched = !this.touched;\n this.dirty = !!options.dirty;\n this.pristine = !this.dirty;\n this.disabled = !!options.disabled;\n this.enabled = !this.disabled;\n const { value, validators } = options;\n this.value = value;\n this.validators = validators;\n this.errors = validators ? controlIsValid({ value, validators }) : [];\n this.error = this.errors[0];\n }\n focus() {\n this.unfocused && this.refresh({ focused: true });\n }\n blur() {\n this.focused && this.refresh({ focused: false, touched: true });\n }\n disable() {\n this.enabled && this.refresh({ disabled: true });\n }\n enable() {\n this.disabled && this.refresh({ disabled: false });\n }\n touch() {\n this.untouched && this.refresh({ touched: true });\n }\n setInitialValue(value) {\n this.initialValue = value;\n this.setValue(value);\n }\n setValue(value) {\n this.refresh({ value });\n }\n setValidators(validators) {\n this.refresh({ validators });\n }\n subscribe(subscriber) {\n this.subscriber = subscriber;\n }\n hasError(key) {\n return hasError(this.errors, key);\n }\n someErrors(keys) {\n return someErrors(this.errors, keys);\n }\n reset() {\n this.refresh({\n dirty: false,\n touched: false,\n value: this.initialValue\n });\n }\n refresh(changes) {\n this.subscriber &&\n this.subscriber({\n ...this,\n ...changes,\n initialValue: this.initialValue\n });\n }\n}\nexport class RolsterArrayControl extends RolsterReactArrayControl {\n constructor(options) {\n super(options);\n this.valid = this.errors.length === 0;\n this.invalid = !this.valid;\n this.wrong = this.touched && this.invalid;\n }\n clone(options) {\n return new RolsterArrayControl(options);\n }\n}\nfunction rolsterArrayControl(options, validators) {\n const controlOptions = createFormControlOptions(options, validators);\n return new RolsterArrayControl({\n ...controlOptions,\n initialValue: controlOptions.value,\n uuid: uuid()\n });\n}\nexport function reactArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\nexport function formArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\nexport function inputArrayControl(options, validators) {\n return rolsterArrayControl(options, validators);\n}\n//# sourceMappingURL=form-array-control.js.map","import { createFormGroupOptions } from '@rolster/forms/arguments';\nimport { controlsAllChecked, controlsPartialChecked, controlsToValue, groupIsValid } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nexport class RolsterArrayGroup {\n constructor(options) {\n const { controls, resource, uuid, validators } = options;\n this.uuid = uuid;\n this.controls = controls;\n this.validators = validators;\n this.resource = resource;\n this.errors = validators ? groupIsValid({ controls, validators }) : [];\n this.error = this.errors[0];\n this.valid =\n this.errors.length === 0 && controlsAllChecked(controls, 'valid');\n this.invalid = !this.valid;\n this.dirty = controlsPartialChecked(controls, 'dirty');\n this.dirties = controlsAllChecked(controls, 'dirty');\n this.touched = controlsPartialChecked(controls, 'touched');\n this.toucheds = controlsAllChecked(controls, 'touched');\n this.pristine = !this.dirty;\n this.pristines = !this.dirties;\n this.untouched = !this.touched;\n this.untoucheds = !this.toucheds;\n this.wrong = this.touched && this.invalid;\n this.value = controlsToValue(controls);\n const subscriber = (options) => {\n this.refresh({\n controls: Object.entries(this.controls).reduce((controls, [key, control]) => {\n controls[key] =\n control.uuid === options.uuid ? control.clone(options) : control;\n return controls;\n }, {})\n });\n };\n Object.values(controls).forEach((control) => {\n control.subscribe(subscriber);\n });\n }\n setValidators(validators) {\n this.refresh({ validators });\n }\n subscribe(subscriber) {\n this.subscriber = subscriber;\n }\n refresh(changes) {\n this.subscriber && this.subscriber({ ...this, ...changes });\n }\n}\nexport function formArrayGroup(options, validators) {\n return new RolsterArrayGroup({\n ...createFormGroupOptions(options, validators),\n uuid: uuid()\n });\n}\n//# sourceMappingURL=form-array-group.js.map","import { controlsAllChecked, controlsToValue } from '@rolster/forms/helpers';\nimport { v4 as uuid } from 'uuid';\nimport { RolsterReactArrayControl } from './form-array-control';\nexport class RolsterArrayList extends RolsterReactArrayControl {\n constructor(options) {\n const value = options.controls.map((controls) => controlsToValue(controls));\n super({ ...options, value });\n this.valueToControls = options.valueToControls;\n this.controls = options.controls;\n this.valid =\n this.errors.length === 0 &&\n this.controls.reduce((valid, controls) => valid && controlsAllChecked(controls, 'valid'), true);\n this.invalid = !this.valid;\n this.wrong = this.touched && this.invalid;\n options.controls.forEach((controls) => {\n this.subscribeControls(controls);\n });\n }\n setValue(value) {\n this.refresh({\n controls: value.map((value) => this.valueToControls(value))\n });\n }\n clone(options) {\n return new RolsterArrayList(options);\n }\n push(controls) {\n this.refresh({\n controls: [...this.controls, controls]\n });\n }\n remove(controls) {\n this.refresh({\n controls: this.controls.filter((currentControls) => currentControls !== controls)\n });\n }\n refresh(changes) {\n super.refresh(changes);\n }\n subscribeControls(newControls) {\n Object.values(newControls).forEach((control) => {\n control.subscribe((options) => {\n const controls = this.controls.map((_controls) => _controls !== newControls\n ? _controls\n : Object.entries(newControls).reduce((controls, [key, control]) => {\n controls[key] =\n control.uuid === options.uuid\n ? control.clone(options)\n : control;\n return controls;\n }, {}));\n this.refresh({ controls });\n });\n });\n }\n}\nexport function formArrayList(valueToControls, options) {\n const value = options?.value || [];\n return new RolsterArrayList({\n ...options,\n valueToControls,\n controls: value.map((value) => valueToControls(value)),\n initialValue: value,\n uuid: uuid()\n });\n}\n//# sourceMappingURL=form-array-list.js.map","import { createFormArrayOptions } from '@rolster/forms/arguments';\nimport { arrayIsValid, controlsToValue, groupAllChecked, hasError as rolsterHasError, someErrors as rolsterSomeErrors } from '@rolster/forms/helpers';\nimport { useCallback, useEffect, useRef, useState } from 'react';\nimport { RolsterArrayGroup } from './form-array-group';\nfunction errorsInArray(groups, validators) {\n return validators ? arrayIsValid({ groups, validators }) : [];\n}\nfunction validStateInArray(groups, validators) {\n const errors = errorsInArray(groups, validators);\n return {\n errors,\n valid: errors.length === 0 && groupAllChecked(groups, 'valid')\n };\n}\nfunction replaceStateInArray(groups, validators) {\n return {\n ...validStateInArray(groups, validators),\n groups,\n controls: groups.map(({ controls }) => controls),\n value: groups.map(({ controls }) => controlsToValue(controls))\n };\n}\nexport function useFormArray(options, validators) {\n const _options = createFormArrayOptions(options, validators);\n const groups = _options.groups || [];\n const initialValue = useRef(groups);\n const [state, setState] = useState({\n ...validStateInArray(groups, _options.validators),\n controls: groups.map(({ controls }) => controls),\n dirty: false,\n dirties: false,\n disabled: false,\n groups,\n touched: false,\n toucheds: false,\n value: groups.map(({ controls }) => controlsToValue(controls)),\n validators: _options.validators\n });\n useEffect(() => {\n const subscriber = (options) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray(state.groups.map((group) => group.uuid === options.uuid\n ? new RolsterArrayGroup(options)\n : group), state.validators)\n }));\n };\n state.groups.forEach((group) => {\n group.subscribe(subscriber);\n });\n }, [state.groups]);\n const disable = useCallback(() => {\n setState((state) => ({ ...state, disabled: true }));\n }, []);\n const enable = useCallback(() => {\n setState((state) => ({ ...state, disabled: false }));\n }, []);\n const setValue = useCallback((groups) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray(groups, state.validators)\n }));\n }, []);\n const setInitialValue = useCallback((groups) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray(groups, state.validators)\n }));\n initialValue.current = groups;\n }, []);\n const push = useCallback((group) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray([...state.groups, group], state.validators)\n }));\n }, []);\n const merge = useCallback((groups) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray([...state.groups, ...groups], state.validators)\n }));\n }, []);\n const remove = useCallback(({ uuid }) => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray(state.groups.filter((group) => group.uuid !== uuid), state.validators)\n }));\n }, []);\n const reset = useCallback(() => {\n setState((state) => ({\n ...state,\n ...replaceStateInArray(initialValue.current, state.validators)\n }));\n }, []);\n const setValidators = useCallback((validators) => {\n setState((state) => ({\n ...state,\n ...validStateInArray(state.groups, validators),\n validators\n }));\n }, []);\n const hasError = useCallback((key) => rolsterHasError(state.errors, key), [state.errors]);\n const someErrors = useCallback((keys) => rolsterSomeErrors(state.errors, keys), [state.errors]);\n return {\n ...state,\n disable,\n enable,\n enabled: !state.disabled,\n error: state.errors[0],\n hasError,\n invalid: !state.valid,\n merge,\n pristine: !state.dirty,\n pristines: !state.dirties,\n push,\n remove,\n reset,\n setInitialValue,\n setValidators,\n setValue,\n someErrors,\n untouched: !state.touched,\n untoucheds: !state.toucheds,\n wrong: state.touched && !state.valid\n };\n}\n//# sourceMappingURL=form-array.js.map","import { createFormControlOptions } from '@rolster/forms/arguments';\nimport { controlIsValid, hasError as rolsterHasError, someErrors as rolsterSomeErrors } from '@rolster/forms/helpers';\nimport { useCallback, useRef, useState } from 'react';\nfunction errorsInControl(value, validators) {\n return validators ? controlIsValid({ value, validators }) : [];\n}\nfunction useControl(options, validators) {\n const _options = createFormControlOptions(options, validators);\n const initialValue = useRef(_options.value);\n const [state, setState] = useState({\n dirty: false,\n disabled: false,\n errors: errorsInControl(_options.value, _options.validators),\n focused: false,\n touched: !!_options.touched,\n value: _options.value,\n validators: _options.validators\n });\n const elementRef = useRef(null);\n const focus = useCallback(() => {\n setState((state) => ({ ...state, focused: true }));\n }, []);\n const blur = useCallback(() => {\n setState((state) => ({ ...state, focused: false, touched: true }));\n }, []);\n const disable = useCallback(() => {\n setState((state) => ({ ...state, disabled: true }));\n }, []);\n const enable = useCallback(() => {\n setState((state) => ({ ...state, disabled: false }));\n }, []);\n const touch = useCallback(() => {\n setState((state) => ({ ...state, touched: true }));\n }, []);\n const setInitialValue = useCallback((value) => {\n initialValue.current = value;\n setState((state) => ({\n ...state,\n dirty: true,\n errors: errorsInControl(value, state.validators),\n value\n }));\n }, []);\n const setValue = useCallback((value) => {\n setState((state) => ({\n ...state,\n dirty: true,\n errors: errorsInControl(value, state.validators),\n value\n }));\n }, []);\n const setValidators = useCallback((validators) => {\n setState((state) => ({\n ...state,\n errors: errorsInControl(state.value, validators),\n validators\n }));\n }, []);\n const reset = useCallback(() => {\n setState((state) => ({\n ...state,\n dirty: false,\n errors: errorsInControl(initialValue.current, state.validators),\n value: initialValue.current,\n touched: false\n }));\n }, []);\n const hasError = useCallback((key) => rolsterHasError(state.errors, key), [state.errors]);\n const someErrors = useCallback((keys) => rolsterSomeErrors(state.errors, keys), [state.errors]);\n const valid = state.errors.length === 0;\n return {\n ...state,\n blur,\n disable,\n elementRef,\n enable,\n enabled: !state.disabled,\n error: state.errors[0],\n focus,\n hasError,\n invalid: !valid,\n pristine: !state.dirty,\n reset,\n setInitialValue,\n setValidators,\n setValue,\n someErrors,\n touch,\n unfocused: !state.focused,\n untouched: !state.touched,\n valid,\n wrong: state.touched && !valid\n };\n}\nexport function useReactControl(options, validators) {\n return useControl(options, validators);\n}\nexport function useFormControl(options, validators) {\n return useControl(options, validators);\n}\nexport function useInputControl(options, validators) {\n return useControl(options, validators);\n}\n//# sourceMappingURL=form-control.js.map","import { createFormGroupOptions } from '@rolster/forms/arguments';\nimport { controlsAllChecked, controlsPartialChecked, controlsToValue, groupIsValid, reduceControlsToArray } from '@rolster/forms/helpers';\nimport { useCallback, useEffect, useState } from 'react';\nfunction errorsInGroup(controls, validators) {\n return validators ? groupIsValid({ controls, validators }) : [];\n}\nfunction validStateInGroup(controls, validators) {\n const errors = errorsInGroup(controls, validators);\n return {\n errors,\n valid: errors.length === 0 && controlsAllChecked(controls, 'valid')\n };\n}\nexport function useFormGroup(options, validators) {\n const _options = createFormGroupOptions(options, validators);\n const { controls } = _options;\n const [state, setState] = useState({\n ...validStateInGroup(controls, _options.validators),\n controls,\n dirties: controlsAllChecked(controls, 'dirty'),\n dirty: controlsPartialChecked(controls, 'dirty'),\n touched: controlsPartialChecked(controls, 'touched'),\n toucheds: controlsAllChecked(controls, 'touched'),\n value: controlsToValue(controls),\n validators: _options.validators\n });\n useEffect(() => {\n setState((state) => ({\n ...state,\n controls,\n dirty: controlsPartialChecked(controls, 'dirty'),\n dirties: controlsAllChecked(controls, 'dirty')\n }));\n }, reduceControlsToArray(controls, 'dirty'));\n useEffect(() => {\n setState((state) => ({\n ...state,\n controls,\n touched: controlsPartialChecked(controls, 'touched'),\n toucheds: controlsAllChecked(controls, 'touched')\n }));\n }, reduceControlsToArray(controls, 'touched'));\n useEffect(() => {\n setState((state) => ({\n ...state,\n ...validStateInGroup(controls, state.validators),\n controls,\n value: controlsToValue(controls)\n }));\n }, reduceControlsToArray(controls, 'value'));\n const setValidators = useCallback((validators) => {\n setState((state) => ({\n ...state,\n ...validStateInGroup(state.controls, validators)\n }));\n }, []);\n const reset = useCallback(() => {\n Object.values(controls).forEach((control) => {\n control.reset();\n });\n }, []);\n return {\n ...state,\n error: state.errors[0],\n invalid: !state.valid,\n pristine: !state.dirty,\n pristines: !state.dirties,\n reset,\n setValidators,\n untouched: !state.touched,\n untoucheds: !state.toucheds,\n wrong: state.touched && !state.valid\n };\n}\n//# sourceMappingURL=form-group.js.map","import { reduceControlsToArray } from '@rolster/forms/helpers';\nexport function reduceControlsToValues(controls) {\n return reduceControlsToArray(controls, 'value');\n}\nexport function reduceGroupToValues(group) {\n return reduceControlsToValues(group.controls);\n}\n//# sourceMappingURL=helpers.js.map"],"names":["uuid","hasError","rolsterHasError","someErrors","rolsterSomeErrors"],"mappings":";;;;;AAGO,MAAM,wBAAwB,CAAC;AACtC,IAAI,WAAW,CAAC,OAAO,EAAE;AACzB,QAAQ,IAAI,CAAC,YAAY,GAAG,OAAO,CAAC,YAAY,CAAC;AACjD,QAAQ,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;AACjC,QAAQ,IAAI,CAAC,OAAO,GAAG,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;AACzC,QAAQ,IAAI,CAAC,SAAS,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC;AACvC,QAAQ,IAAI,CAAC,OAAO,GAAG,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;AACzC,QAAQ,IAAI,CAAC,SAAS,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC;AACvC,QAAQ,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC;AACrC,QAA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only controls: C;
7
7
  readonly value: ControlsValue<C>;
8
8
  readonly dirty: boolean;
9
- readonly dirtyAll: boolean;
9
+ readonly dirties: boolean;
10
10
  readonly errors: ValidatorError<any>[];
11
11
  readonly invalid: boolean;
12
12
  readonly pristine: boolean;
13
- readonly pristineAll: boolean;
13
+ readonly pristines: boolean;
14
14
  readonly touched: boolean;
15
- readonly touchedAll: boolean;
15
+ readonly toucheds: boolean;
16
16
  readonly untouched: boolean;
17
- readonly untouchedAll: boolean;
17
+ readonly untoucheds: boolean;
18
18
  readonly valid: boolean;
19
19
  readonly wrong: boolean;
20
20
  readonly error?: ValidatorError<any>;
@@ -14,13 +14,13 @@ export class RolsterArrayGroup {
14
14
  this.errors.length === 0 && controlsAllChecked(controls, 'valid');
15
15
  this.invalid = !this.valid;
16
16
  this.dirty = controlsPartialChecked(controls, 'dirty');
17
- this.dirtyAll = controlsAllChecked(controls, 'dirty');
17
+ this.dirties = controlsAllChecked(controls, 'dirty');
18
18
  this.touched = controlsPartialChecked(controls, 'touched');
19
- this.touchedAll = controlsAllChecked(controls, 'touched');
20
- this.untouched = !this.touched;
21
- this.untouchedAll = !this.touchedAll;
19
+ this.toucheds = controlsAllChecked(controls, 'touched');
22
20
  this.pristine = !this.dirty;
23
- this.pristineAll = !this.dirtyAll;
21
+ this.pristines = !this.dirties;
22
+ this.untouched = !this.touched;
23
+ this.untoucheds = !this.toucheds;
24
24
  this.wrong = this.touched && this.invalid;
25
25
  this.value = controlsToValue(controls);
26
26
  const subscriber = (options) => {
@@ -1 +1 @@
1
- {"version":3,"file":"form-array-group.js","sourceRoot":"","sources":["../../../src/form-array/form-array-group.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,EACf,YAAY,EACb,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,EAAE,IAAI,IAAI,EAAE,MAAM,MAAM,CA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