@lehnihon/bit-form 2.2.5 → 2.2.7

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 (121) hide show
  1. package/README.md +80 -24
  2. package/dist/angular/index.cjs +1 -1
  3. package/dist/angular/index.cjs.map +1 -1
  4. package/dist/angular/index.d.cts +18 -20
  5. package/dist/angular/index.d.ts +18 -20
  6. package/dist/angular/index.js +1 -1
  7. package/dist/angular/index.js.map +1 -1
  8. package/dist/array-controller-C1A5VKYd.d.cts +23 -0
  9. package/dist/array-controller-DtkmcnUr.d.ts +23 -0
  10. package/dist/{bus-B4zZmB9C.d.ts → bus-DgilLszS.d.ts} +83 -15
  11. package/dist/{bus-BeAeZwWu.d.cts → bus-rcUiufS7.d.cts} +83 -15
  12. package/dist/chunk-DIEE6LUO.js +2 -0
  13. package/dist/chunk-DIEE6LUO.js.map +1 -0
  14. package/dist/chunk-FUUQB4DV.cjs +2 -0
  15. package/dist/chunk-FUUQB4DV.cjs.map +1 -0
  16. package/dist/chunk-IV32WXCF.cjs +2 -0
  17. package/dist/chunk-IV32WXCF.cjs.map +1 -0
  18. package/dist/chunk-K5X37E3U.js +2 -0
  19. package/dist/chunk-K5X37E3U.js.map +1 -0
  20. package/dist/chunk-KWLLYQOL.cjs +2 -0
  21. package/dist/chunk-KWLLYQOL.cjs.map +1 -0
  22. package/dist/chunk-LIYZPSWM.js +2 -0
  23. package/dist/chunk-LIYZPSWM.js.map +1 -0
  24. package/dist/chunk-O5UPA33R.js +2 -0
  25. package/dist/chunk-O5UPA33R.js.map +1 -0
  26. package/dist/chunk-QAL6J5GQ.cjs +2 -0
  27. package/dist/chunk-QAL6J5GQ.cjs.map +1 -0
  28. package/dist/chunk-QKGTVKBU.cjs +2 -0
  29. package/dist/chunk-QKGTVKBU.cjs.map +1 -0
  30. package/dist/chunk-SA47B5OP.js +2 -0
  31. package/dist/chunk-SA47B5OP.js.map +1 -0
  32. package/dist/cli/index.cjs +22 -22
  33. package/dist/core.cjs +2 -0
  34. package/dist/core.cjs.map +1 -0
  35. package/dist/core.d.cts +122 -0
  36. package/dist/core.d.ts +122 -0
  37. package/dist/core.js +2 -0
  38. package/dist/core.js.map +1 -0
  39. package/dist/devtools/bridge.cjs +1 -1
  40. package/dist/devtools/bridge.cjs.map +1 -1
  41. package/dist/devtools/bridge.d.cts +4 -1
  42. package/dist/devtools/bridge.d.ts +4 -1
  43. package/dist/devtools/bridge.js +1 -1
  44. package/dist/devtools/bridge.js.map +1 -1
  45. package/dist/devtools/index.cjs +18 -18
  46. package/dist/devtools/index.cjs.map +1 -1
  47. package/dist/devtools/index.d.cts +26 -2
  48. package/dist/devtools/index.d.ts +26 -2
  49. package/dist/devtools/index.js +18 -18
  50. package/dist/devtools/index.js.map +1 -1
  51. package/dist/devtools/protocol.cjs +2 -0
  52. package/dist/devtools/protocol.cjs.map +1 -0
  53. package/dist/devtools/protocol.d.cts +54 -0
  54. package/dist/devtools/protocol.d.ts +54 -0
  55. package/dist/devtools/protocol.js +2 -0
  56. package/dist/devtools/protocol.js.map +1 -0
  57. package/dist/field-binding-Bi1g-D8X.d.ts +25 -0
  58. package/dist/field-binding-X5TkvfUt.d.cts +25 -0
  59. package/dist/index.cjs +1 -1
  60. package/dist/index.cjs.map +1 -1
  61. package/dist/index.d.cts +64 -150
  62. package/dist/index.d.ts +64 -150
  63. package/dist/index.js +1 -1
  64. package/dist/mask.d.cts +2 -2
  65. package/dist/mask.d.ts +2 -2
  66. package/dist/react/index.cjs +1 -1
  67. package/dist/react/index.cjs.map +1 -1
  68. package/dist/react/index.d.cts +8 -7
  69. package/dist/react/index.d.ts +8 -7
  70. package/dist/react/index.js +1 -1
  71. package/dist/react/index.js.map +1 -1
  72. package/dist/react-native/index.cjs +1 -1
  73. package/dist/react-native/index.cjs.map +1 -1
  74. package/dist/react-native/index.d.cts +7 -6
  75. package/dist/react-native/index.d.ts +7 -6
  76. package/dist/react-native/index.js +1 -1
  77. package/dist/react-native/index.js.map +1 -1
  78. package/dist/resolvers/index.cjs +1 -1
  79. package/dist/resolvers/index.cjs.map +1 -1
  80. package/dist/resolvers/index.d.cts +2 -2
  81. package/dist/resolvers/index.d.ts +2 -2
  82. package/dist/resolvers/index.js +1 -1
  83. package/dist/resolvers/joi.d.cts +2 -2
  84. package/dist/resolvers/joi.d.ts +2 -2
  85. package/dist/resolvers/yup.d.cts +2 -2
  86. package/dist/resolvers/yup.d.ts +2 -2
  87. package/dist/resolvers/zod.d.cts +2 -2
  88. package/dist/resolvers/zod.d.ts +2 -2
  89. package/dist/store-api-types-9ipdute1.d.ts +187 -0
  90. package/dist/store-api-types-B6_bPoVI.d.cts +187 -0
  91. package/dist/{types-D8DgIUhJ.d.cts → types-CUXh7PqD.d.cts} +1 -1
  92. package/dist/{types-D8DgIUhJ.d.ts → types-CUXh7PqD.d.ts} +1 -1
  93. package/dist/{use-bit-persist-iPWLbD8l.d.ts → use-bit-persist-Bc06fmqZ.d.ts} +12 -14
  94. package/dist/{use-bit-persist-CIVN-oIi.d.cts → use-bit-persist-CIKFwtdM.d.cts} +12 -14
  95. package/dist/vue/index.cjs +1 -1
  96. package/dist/vue/index.cjs.map +1 -1
  97. package/dist/vue/index.d.cts +15 -18
  98. package/dist/vue/index.d.ts +15 -18
  99. package/dist/vue/index.js +1 -1
  100. package/dist/vue/index.js.map +1 -1
  101. package/package.json +20 -11
  102. package/dist/chunk-2FDEJYA5.js +0 -2
  103. package/dist/chunk-2FDEJYA5.js.map +0 -1
  104. package/dist/chunk-3CARTBEN.cjs +0 -2
  105. package/dist/chunk-3CARTBEN.cjs.map +0 -1
  106. package/dist/chunk-64KSP4TP.js +0 -2
  107. package/dist/chunk-64KSP4TP.js.map +0 -1
  108. package/dist/chunk-JIWR4KSZ.cjs +0 -2
  109. package/dist/chunk-JIWR4KSZ.cjs.map +0 -1
  110. package/dist/chunk-OZKLQRO6.cjs +0 -2
  111. package/dist/chunk-OZKLQRO6.cjs.map +0 -1
  112. package/dist/chunk-QWH2NBVB.js +0 -2
  113. package/dist/chunk-QWH2NBVB.js.map +0 -1
  114. package/dist/chunk-UMKOKAPD.js +0 -2
  115. package/dist/chunk-UMKOKAPD.js.map +0 -1
  116. package/dist/chunk-VQ7MK5VB.cjs +0 -2
  117. package/dist/chunk-VQ7MK5VB.cjs.map +0 -1
  118. package/dist/field-binding-BXw0Ku2c.d.cts +0 -12
  119. package/dist/field-binding-BXw0Ku2c.d.ts +0 -12
  120. package/dist/public-types-BQXaxmAE.d.cts +0 -94
  121. package/dist/public-types-CVgFf_qY.d.ts +0 -94
@@ -3,7 +3,7 @@ export { zodResolver } from './zod.cjs';
3
3
  export { yupResolver } from './yup.cjs';
4
4
  export { BitJoiResolverConfig, BitResolverScopeOptions, BitYupResolverConfig, BitZodResolverConfig } from './types.cjs';
5
5
  import 'joi';
6
- import '../bus-BeAeZwWu.cjs';
7
- import '../types-D8DgIUhJ.cjs';
6
+ import '../bus-rcUiufS7.cjs';
7
+ import '../types-CUXh7PqD.cjs';
8
8
  import 'zod';
9
9
  import 'yup';
@@ -3,7 +3,7 @@ export { zodResolver } from './zod.js';
3
3
  export { yupResolver } from './yup.js';
4
4
  export { BitJoiResolverConfig, BitResolverScopeOptions, BitYupResolverConfig, BitZodResolverConfig } from './types.js';
5
5
  import 'joi';
6
- import '../bus-B4zZmB9C.js';
7
- import '../types-D8DgIUhJ.js';
6
+ import '../bus-DgilLszS.js';
7
+ import '../types-CUXh7PqD.js';
8
8
  import 'zod';
9
9
  import 'yup';
@@ -1,2 +1,2 @@
1
- import{a as e}from"../chunk-FGJB4DHQ.js";import"../chunk-FQLJOSF7.js";import{a as o}from"../chunk-M2XR4C7T.js";import{a as r}from"../chunk-GDRNKTHO.js";import"../chunk-GUU6EXFN.js";export{e as joiResolver,r as yupResolver,o as zodResolver};
1
+ import{a as r}from"../chunk-GDRNKTHO.js";import{a as e}from"../chunk-FGJB4DHQ.js";import"../chunk-FQLJOSF7.js";import{a as o}from"../chunk-M2XR4C7T.js";import"../chunk-GUU6EXFN.js";export{e as joiResolver,r as yupResolver,o as zodResolver};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  import { ObjectSchema } from 'joi';
2
- import { i as BitErrors } from '../bus-BeAeZwWu.cjs';
2
+ import { c as BitErrors } from '../bus-rcUiufS7.cjs';
3
3
  import { BitJoiResolverConfig, BitResolverScopeOptions } from './types.cjs';
4
- import '../types-D8DgIUhJ.cjs';
4
+ import '../types-CUXh7PqD.cjs';
5
5
 
6
6
  declare const joiResolver: <T extends object>(schema: ObjectSchema<T>, config?: BitJoiResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -1,7 +1,7 @@
1
1
  import { ObjectSchema } from 'joi';
2
- import { i as BitErrors } from '../bus-B4zZmB9C.js';
2
+ import { c as BitErrors } from '../bus-DgilLszS.js';
3
3
  import { BitJoiResolverConfig, BitResolverScopeOptions } from './types.js';
4
- import '../types-D8DgIUhJ.js';
4
+ import '../types-CUXh7PqD.js';
5
5
 
6
6
  declare const joiResolver: <T extends object>(schema: ObjectSchema<T>, config?: BitJoiResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -1,7 +1,7 @@
1
1
  import { Schema } from 'yup';
2
- import { i as BitErrors } from '../bus-BeAeZwWu.cjs';
2
+ import { c as BitErrors } from '../bus-rcUiufS7.cjs';
3
3
  import { BitYupResolverConfig, BitResolverScopeOptions } from './types.cjs';
4
- import '../types-D8DgIUhJ.cjs';
4
+ import '../types-CUXh7PqD.cjs';
5
5
 
6
6
  declare const yupResolver: <T extends object>(schema: Schema<T>, config?: BitYupResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -1,7 +1,7 @@
1
1
  import { Schema } from 'yup';
2
- import { i as BitErrors } from '../bus-B4zZmB9C.js';
2
+ import { c as BitErrors } from '../bus-DgilLszS.js';
3
3
  import { BitYupResolverConfig, BitResolverScopeOptions } from './types.js';
4
- import '../types-D8DgIUhJ.js';
4
+ import '../types-CUXh7PqD.js';
5
5
 
6
6
  declare const yupResolver: <T extends object>(schema: Schema<T>, config?: BitYupResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -1,7 +1,7 @@
1
1
  import { ZodSchema } from 'zod';
2
- import { i as BitErrors } from '../bus-BeAeZwWu.cjs';
2
+ import { c as BitErrors } from '../bus-rcUiufS7.cjs';
3
3
  import { BitZodResolverConfig, BitResolverScopeOptions } from './types.cjs';
4
- import '../types-D8DgIUhJ.cjs';
4
+ import '../types-CUXh7PqD.cjs';
5
5
 
6
6
  declare const zodResolver: <T extends object>(schema: ZodSchema<T>, _config?: BitZodResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -1,7 +1,7 @@
1
1
  import { ZodSchema } from 'zod';
2
- import { i as BitErrors } from '../bus-B4zZmB9C.js';
2
+ import { c as BitErrors } from '../bus-DgilLszS.js';
3
3
  import { BitZodResolverConfig, BitResolverScopeOptions } from './types.js';
4
- import '../types-D8DgIUhJ.js';
4
+ import '../types-CUXh7PqD.js';
5
5
 
6
6
  declare const zodResolver: <T extends object>(schema: ZodSchema<T>, _config?: BitZodResolverConfig) => (values: T, options?: BitResolverScopeOptions) => Promise<BitErrors<T>>;
7
7
 
@@ -0,0 +1,187 @@
1
+ import { f as BitState, e as BitPath, g as BitFieldState, b as BitPathValue, h as BitFieldDefinition, c as BitErrors, D as DeepPartial, B as BitArrayPath, a as BitArrayItem, i as BitPersistMetadata, S as ScopeStatus, j as BitConfig, k as ValidatorFn, l as DevToolsOptions, m as BitPersistResolvedConfig, n as BitIdFactory, o as BitPlugin, p as BitScheduler, q as BitFormGlobal } from './bus-DgilLszS.js';
2
+ import { B as BitMask } from './types-CUXh7PqD.js';
3
+
4
+ type BitSelector<T extends object, TSlice> = (state: Readonly<BitState<T>>) => TSlice;
5
+ type BitEqualityFn<TValue> = (previous: TValue, next: TValue) => boolean;
6
+ interface BitSelectorSubscriptionOptions<TValue> {
7
+ equalityFn?: BitEqualityFn<TValue>;
8
+ emitImmediately?: boolean;
9
+ paths?: string[];
10
+ }
11
+
12
+ interface BitValidationOptions {
13
+ scope?: string;
14
+ scopeFields?: string[];
15
+ }
16
+ interface BitHistoryMetadata {
17
+ enabled: boolean;
18
+ canUndo: boolean;
19
+ canRedo: boolean;
20
+ historyIndex: number;
21
+ historySize: number;
22
+ }
23
+ interface BitFormMeta {
24
+ isValid: boolean;
25
+ isDirty: boolean;
26
+ isSubmitting: boolean;
27
+ }
28
+
29
+ interface BitFrameworkConfig<T extends object = any> extends BitConfig<T> {
30
+ initialValues: T;
31
+ resolver?: ValidatorFn<T>;
32
+ validationDelay: number;
33
+ history: {
34
+ enabled: boolean;
35
+ limit: number;
36
+ };
37
+ masks?: Record<string, BitMask>;
38
+ fields?: Record<string, BitFieldDefinition<T>>;
39
+ devTools?: boolean | DevToolsOptions;
40
+ persist: BitPersistResolvedConfig<T>;
41
+ idFactory: BitIdFactory;
42
+ plugins: BitPlugin<T>[];
43
+ scheduler?: BitScheduler;
44
+ subscriptionCacheSize?: number;
45
+ bus?: BitFormGlobal;
46
+ }
47
+ interface BitStoreQueryApi<T extends object = any> {
48
+ getConfig(): Readonly<BitFrameworkConfig<T>>;
49
+ getState(): Readonly<BitState<T>>;
50
+ isHidden<P extends BitPath<T>>(path: P): boolean;
51
+ isRequired<P extends BitPath<T>>(path: P): boolean;
52
+ isFieldDirty(path: string): boolean;
53
+ isFieldValidating(path: string): boolean;
54
+ getDirtyValues(): Partial<T>;
55
+ getPersistMetadata(): BitPersistMetadata;
56
+ getHistoryMetadata(): BitHistoryMetadata;
57
+ getStepStatus(scopeName: string): ScopeStatus;
58
+ getStepErrors(scopeName: string): Record<string, string>;
59
+ }
60
+ interface BitStoreObserveApi<T extends object = any> {
61
+ subscribe(listener: () => void): () => void;
62
+ subscribePersistMeta(listener: (meta: BitPersistMetadata) => void): () => void;
63
+ subscribeHistoryMeta(listener: (meta: BitHistoryMetadata) => void): () => void;
64
+ subscribeScopeStatus(scopeName: string, listener: (status: ScopeStatus) => void): () => void;
65
+ }
66
+ interface BitStoreWriteApi<T extends object = any> {
67
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
68
+ blurField<P extends BitPath<T>>(path: P): void;
69
+ setValues(values: T | DeepPartial<T>, options?: {
70
+ partial?: boolean;
71
+ rebase?: boolean;
72
+ }): void;
73
+ setError(path: string, message: string | undefined): void;
74
+ setErrors(errors: BitErrors<T>): void;
75
+ setServerErrors(serverErrors: Record<string, string[] | string>): void;
76
+ validate(options?: BitValidationOptions): Promise<boolean>;
77
+ reset(): void;
78
+ transaction<TResult>(callback: () => TResult): TResult;
79
+ submit(onSuccess: (values: T, dirtyValues?: Partial<T>) => void | Promise<void>): Promise<void>;
80
+ }
81
+ interface BitStorePersistFeatureApi {
82
+ getPersistMetadata(): BitPersistMetadata;
83
+ restorePersisted(): Promise<boolean>;
84
+ forceSave(): Promise<void>;
85
+ clearPersisted(): Promise<void>;
86
+ }
87
+ interface BitStoreRegistrationFeatureApi<T extends object = any> {
88
+ cleanup(): void;
89
+ registerField(path: string, config: BitFieldDefinition<T>): void;
90
+ unregisterField(path: string): void;
91
+ }
92
+ interface BitStoreArrayFeatureApi<T extends object = any> {
93
+ pushItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
94
+ prependItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
95
+ insertItem<P extends BitArrayPath<T>>(path: P, index: number, value: BitArrayItem<BitPathValue<T, P>>): void;
96
+ removeItem<P extends BitArrayPath<T>>(path: P, index: number): void;
97
+ moveItem<P extends BitArrayPath<T>>(path: P, from: number, to: number): void;
98
+ swapItems<P extends BitArrayPath<T>>(path: P, indexA: number, indexB: number): void;
99
+ }
100
+ interface BitStoreHistoryFeatureApi {
101
+ undo(): void;
102
+ redo(): void;
103
+ }
104
+ interface BitFormMetaBindingApi<T extends object = any> {
105
+ getState(): Readonly<BitState<T>>;
106
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
107
+ }
108
+ interface BitFieldBindingApi<T extends object = any> {
109
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
110
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
111
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
112
+ blurField<P extends BitPath<T>>(path: P): void;
113
+ resolveMask(path: string): BitMask | undefined;
114
+ unregisterField?(path: string): void;
115
+ }
116
+ interface BitArrayBindingApi<T extends object = any> extends Pick<BitFormBindingApi<T>, "getState" | "setField" | "subscribePath" | "pushItem" | "prependItem" | "insertItem" | "removeItem" | "moveItem" | "swapItems" | "createArrayItemId"> {
117
+ }
118
+ interface BitStoreFeatureApi<T extends object = any> extends BitStorePersistFeatureApi, BitStoreRegistrationFeatureApi<T>, BitStoreArrayFeatureApi<T>, BitStoreHistoryFeatureApi {
119
+ }
120
+ interface BitStoreApi<T extends object = any> extends BitStoreQueryApi<T>, BitStoreObserveApi<T>, BitStoreWriteApi<T>, BitStoreFeatureApi<T> {
121
+ }
122
+ interface BitStoreHooksApi<T extends object = any> extends BitStoreApi<T> {
123
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
124
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
125
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
126
+ subscribePath<P extends BitPath<T>>(path: P, listener: (value: BitPathValue<T, P>) => void, options?: BitSelectorSubscriptionOptions<BitPathValue<T, P>>): () => void;
127
+ subscribeSelector<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: BitSelectorSubscriptionOptions<TSlice>): () => void;
128
+ subscribeTracked<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: Omit<BitSelectorSubscriptionOptions<TSlice>, "paths">): () => void;
129
+ unregisterPrefix?(prefix: string): void;
130
+ markFieldsTouched(paths: string[]): void;
131
+ hasValidationsInProgress(scopeFields?: string[]): boolean;
132
+ resolveMask(path: string): BitMask | undefined;
133
+ getScopeFields(scopeName: string): string[];
134
+ createArrayItemId(path: string, index?: number): string;
135
+ }
136
+ interface BitFormBindingApi<T extends object = any> {
137
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
138
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
139
+ getState(): Readonly<BitState<T>>;
140
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
141
+ subscribe(listener: () => void): () => void;
142
+ subscribePath<P extends BitPath<T>>(path: P, listener: (value: BitPathValue<T, P>) => void, options?: BitSelectorSubscriptionOptions<BitPathValue<T, P>>): () => void;
143
+ subscribeSelector<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: BitSelectorSubscriptionOptions<TSlice>): () => void;
144
+ subscribeTracked<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: Omit<BitSelectorSubscriptionOptions<TSlice>, "paths">): () => void;
145
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
146
+ blurField<P extends BitPath<T>>(path: P): void;
147
+ registerField?(path: string, config: BitFieldDefinition<T>): void;
148
+ unregisterField?(path: string): void;
149
+ unregisterPrefix?(prefix: string): void;
150
+ markFieldsTouched(paths: string[]): void;
151
+ resolveMask(path: string): BitMask | undefined;
152
+ submit(onSuccess: (values: T, dirtyValues?: Partial<T>) => void | Promise<void>): Promise<void>;
153
+ reset(): void;
154
+ validate(options?: BitValidationOptions): Promise<boolean>;
155
+ setError(path: string, message: string | undefined): void;
156
+ setErrors(errors: BitErrors<T>): void;
157
+ setServerErrors(serverErrors: Record<string, string[] | string>): void;
158
+ setValues(values: T | DeepPartial<T>, options?: {
159
+ partial?: boolean;
160
+ rebase?: boolean;
161
+ }): void;
162
+ transaction<TResult>(callback: () => TResult): TResult;
163
+ pushItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
164
+ prependItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
165
+ insertItem<P extends BitArrayPath<T>>(path: P, index: number, value: BitArrayItem<BitPathValue<T, P>>): void;
166
+ removeItem<P extends BitArrayPath<T>>(path: P, index: number): void;
167
+ moveItem<P extends BitArrayPath<T>>(path: P, from: number, to: number): void;
168
+ swapItems<P extends BitArrayPath<T>>(path: P, indexA: number, indexB: number): void;
169
+ undo(): void;
170
+ redo(): void;
171
+ getHistoryMetadata(): BitHistoryMetadata;
172
+ getPersistMetadata(): BitPersistMetadata;
173
+ restorePersisted(): Promise<boolean>;
174
+ forceSave(): Promise<void>;
175
+ clearPersisted(): Promise<void>;
176
+ getDirtyValues(): Partial<T>;
177
+ hasValidationsInProgress(scopeFields?: string[]): boolean;
178
+ getScopeFields(scopeName: string): string[];
179
+ getStepStatus(scopeName: string): ScopeStatus;
180
+ getStepErrors(scopeName: string): Record<string, string>;
181
+ subscribePersistMeta(listener: (meta: BitPersistMetadata) => void): () => void;
182
+ subscribeHistoryMeta(listener: (meta: BitHistoryMetadata) => void): () => void;
183
+ subscribeScopeStatus(scopeName: string, listener: (status: ScopeStatus) => void): () => void;
184
+ createArrayItemId(path: string, index?: number): string;
185
+ }
186
+
187
+ export type { BitArrayBindingApi as B, BitStoreHooksApi as a, BitFormBindingApi as b, BitHistoryMetadata as c, BitValidationOptions as d, BitFormMetaBindingApi as e, BitFormMeta as f, BitFieldBindingApi as g, BitEqualityFn as h, BitFrameworkConfig as i, BitSelector as j, BitSelectorSubscriptionOptions as k, BitStoreApi as l, BitStoreArrayFeatureApi as m, BitStoreFeatureApi as n, BitStoreHistoryFeatureApi as o, BitStoreObserveApi as p, BitStorePersistFeatureApi as q, BitStoreQueryApi as r, BitStoreRegistrationFeatureApi as s, BitStoreWriteApi as t };
@@ -0,0 +1,187 @@
1
+ import { f as BitState, e as BitPath, g as BitFieldState, b as BitPathValue, h as BitFieldDefinition, c as BitErrors, D as DeepPartial, B as BitArrayPath, a as BitArrayItem, i as BitPersistMetadata, S as ScopeStatus, j as BitConfig, k as ValidatorFn, l as DevToolsOptions, m as BitPersistResolvedConfig, n as BitIdFactory, o as BitPlugin, p as BitScheduler, q as BitFormGlobal } from './bus-rcUiufS7.cjs';
2
+ import { B as BitMask } from './types-CUXh7PqD.cjs';
3
+
4
+ type BitSelector<T extends object, TSlice> = (state: Readonly<BitState<T>>) => TSlice;
5
+ type BitEqualityFn<TValue> = (previous: TValue, next: TValue) => boolean;
6
+ interface BitSelectorSubscriptionOptions<TValue> {
7
+ equalityFn?: BitEqualityFn<TValue>;
8
+ emitImmediately?: boolean;
9
+ paths?: string[];
10
+ }
11
+
12
+ interface BitValidationOptions {
13
+ scope?: string;
14
+ scopeFields?: string[];
15
+ }
16
+ interface BitHistoryMetadata {
17
+ enabled: boolean;
18
+ canUndo: boolean;
19
+ canRedo: boolean;
20
+ historyIndex: number;
21
+ historySize: number;
22
+ }
23
+ interface BitFormMeta {
24
+ isValid: boolean;
25
+ isDirty: boolean;
26
+ isSubmitting: boolean;
27
+ }
28
+
29
+ interface BitFrameworkConfig<T extends object = any> extends BitConfig<T> {
30
+ initialValues: T;
31
+ resolver?: ValidatorFn<T>;
32
+ validationDelay: number;
33
+ history: {
34
+ enabled: boolean;
35
+ limit: number;
36
+ };
37
+ masks?: Record<string, BitMask>;
38
+ fields?: Record<string, BitFieldDefinition<T>>;
39
+ devTools?: boolean | DevToolsOptions;
40
+ persist: BitPersistResolvedConfig<T>;
41
+ idFactory: BitIdFactory;
42
+ plugins: BitPlugin<T>[];
43
+ scheduler?: BitScheduler;
44
+ subscriptionCacheSize?: number;
45
+ bus?: BitFormGlobal;
46
+ }
47
+ interface BitStoreQueryApi<T extends object = any> {
48
+ getConfig(): Readonly<BitFrameworkConfig<T>>;
49
+ getState(): Readonly<BitState<T>>;
50
+ isHidden<P extends BitPath<T>>(path: P): boolean;
51
+ isRequired<P extends BitPath<T>>(path: P): boolean;
52
+ isFieldDirty(path: string): boolean;
53
+ isFieldValidating(path: string): boolean;
54
+ getDirtyValues(): Partial<T>;
55
+ getPersistMetadata(): BitPersistMetadata;
56
+ getHistoryMetadata(): BitHistoryMetadata;
57
+ getStepStatus(scopeName: string): ScopeStatus;
58
+ getStepErrors(scopeName: string): Record<string, string>;
59
+ }
60
+ interface BitStoreObserveApi<T extends object = any> {
61
+ subscribe(listener: () => void): () => void;
62
+ subscribePersistMeta(listener: (meta: BitPersistMetadata) => void): () => void;
63
+ subscribeHistoryMeta(listener: (meta: BitHistoryMetadata) => void): () => void;
64
+ subscribeScopeStatus(scopeName: string, listener: (status: ScopeStatus) => void): () => void;
65
+ }
66
+ interface BitStoreWriteApi<T extends object = any> {
67
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
68
+ blurField<P extends BitPath<T>>(path: P): void;
69
+ setValues(values: T | DeepPartial<T>, options?: {
70
+ partial?: boolean;
71
+ rebase?: boolean;
72
+ }): void;
73
+ setError(path: string, message: string | undefined): void;
74
+ setErrors(errors: BitErrors<T>): void;
75
+ setServerErrors(serverErrors: Record<string, string[] | string>): void;
76
+ validate(options?: BitValidationOptions): Promise<boolean>;
77
+ reset(): void;
78
+ transaction<TResult>(callback: () => TResult): TResult;
79
+ submit(onSuccess: (values: T, dirtyValues?: Partial<T>) => void | Promise<void>): Promise<void>;
80
+ }
81
+ interface BitStorePersistFeatureApi {
82
+ getPersistMetadata(): BitPersistMetadata;
83
+ restorePersisted(): Promise<boolean>;
84
+ forceSave(): Promise<void>;
85
+ clearPersisted(): Promise<void>;
86
+ }
87
+ interface BitStoreRegistrationFeatureApi<T extends object = any> {
88
+ cleanup(): void;
89
+ registerField(path: string, config: BitFieldDefinition<T>): void;
90
+ unregisterField(path: string): void;
91
+ }
92
+ interface BitStoreArrayFeatureApi<T extends object = any> {
93
+ pushItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
94
+ prependItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
95
+ insertItem<P extends BitArrayPath<T>>(path: P, index: number, value: BitArrayItem<BitPathValue<T, P>>): void;
96
+ removeItem<P extends BitArrayPath<T>>(path: P, index: number): void;
97
+ moveItem<P extends BitArrayPath<T>>(path: P, from: number, to: number): void;
98
+ swapItems<P extends BitArrayPath<T>>(path: P, indexA: number, indexB: number): void;
99
+ }
100
+ interface BitStoreHistoryFeatureApi {
101
+ undo(): void;
102
+ redo(): void;
103
+ }
104
+ interface BitFormMetaBindingApi<T extends object = any> {
105
+ getState(): Readonly<BitState<T>>;
106
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
107
+ }
108
+ interface BitFieldBindingApi<T extends object = any> {
109
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
110
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
111
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
112
+ blurField<P extends BitPath<T>>(path: P): void;
113
+ resolveMask(path: string): BitMask | undefined;
114
+ unregisterField?(path: string): void;
115
+ }
116
+ interface BitArrayBindingApi<T extends object = any> extends Pick<BitFormBindingApi<T>, "getState" | "setField" | "subscribePath" | "pushItem" | "prependItem" | "insertItem" | "removeItem" | "moveItem" | "swapItems" | "createArrayItemId"> {
117
+ }
118
+ interface BitStoreFeatureApi<T extends object = any> extends BitStorePersistFeatureApi, BitStoreRegistrationFeatureApi<T>, BitStoreArrayFeatureApi<T>, BitStoreHistoryFeatureApi {
119
+ }
120
+ interface BitStoreApi<T extends object = any> extends BitStoreQueryApi<T>, BitStoreObserveApi<T>, BitStoreWriteApi<T>, BitStoreFeatureApi<T> {
121
+ }
122
+ interface BitStoreHooksApi<T extends object = any> extends BitStoreApi<T> {
123
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
124
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
125
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
126
+ subscribePath<P extends BitPath<T>>(path: P, listener: (value: BitPathValue<T, P>) => void, options?: BitSelectorSubscriptionOptions<BitPathValue<T, P>>): () => void;
127
+ subscribeSelector<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: BitSelectorSubscriptionOptions<TSlice>): () => void;
128
+ subscribeTracked<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: Omit<BitSelectorSubscriptionOptions<TSlice>, "paths">): () => void;
129
+ unregisterPrefix?(prefix: string): void;
130
+ markFieldsTouched(paths: string[]): void;
131
+ hasValidationsInProgress(scopeFields?: string[]): boolean;
132
+ resolveMask(path: string): BitMask | undefined;
133
+ getScopeFields(scopeName: string): string[];
134
+ createArrayItemId(path: string, index?: number): string;
135
+ }
136
+ interface BitFormBindingApi<T extends object = any> {
137
+ getFieldState<P extends BitPath<T>>(path: P): Readonly<BitFieldState<T, BitPathValue<T, P>>>;
138
+ subscribeFieldState<P extends BitPath<T>>(path: P, listener: (state: Readonly<BitFieldState<T, BitPathValue<T, P>>>) => void): () => void;
139
+ getState(): Readonly<BitState<T>>;
140
+ subscribeFormMeta(listener: (meta: BitFormMeta) => void): () => void;
141
+ subscribe(listener: () => void): () => void;
142
+ subscribePath<P extends BitPath<T>>(path: P, listener: (value: BitPathValue<T, P>) => void, options?: BitSelectorSubscriptionOptions<BitPathValue<T, P>>): () => void;
143
+ subscribeSelector<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: BitSelectorSubscriptionOptions<TSlice>): () => void;
144
+ subscribeTracked<TSlice>(selector: BitSelector<T, TSlice>, listener: (slice: TSlice) => void, options?: Omit<BitSelectorSubscriptionOptions<TSlice>, "paths">): () => void;
145
+ setField<P extends BitPath<T>>(path: P, value: BitPathValue<T, P>): void;
146
+ blurField<P extends BitPath<T>>(path: P): void;
147
+ registerField?(path: string, config: BitFieldDefinition<T>): void;
148
+ unregisterField?(path: string): void;
149
+ unregisterPrefix?(prefix: string): void;
150
+ markFieldsTouched(paths: string[]): void;
151
+ resolveMask(path: string): BitMask | undefined;
152
+ submit(onSuccess: (values: T, dirtyValues?: Partial<T>) => void | Promise<void>): Promise<void>;
153
+ reset(): void;
154
+ validate(options?: BitValidationOptions): Promise<boolean>;
155
+ setError(path: string, message: string | undefined): void;
156
+ setErrors(errors: BitErrors<T>): void;
157
+ setServerErrors(serverErrors: Record<string, string[] | string>): void;
158
+ setValues(values: T | DeepPartial<T>, options?: {
159
+ partial?: boolean;
160
+ rebase?: boolean;
161
+ }): void;
162
+ transaction<TResult>(callback: () => TResult): TResult;
163
+ pushItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
164
+ prependItem<P extends BitArrayPath<T>>(path: P, value: BitArrayItem<BitPathValue<T, P>>): void;
165
+ insertItem<P extends BitArrayPath<T>>(path: P, index: number, value: BitArrayItem<BitPathValue<T, P>>): void;
166
+ removeItem<P extends BitArrayPath<T>>(path: P, index: number): void;
167
+ moveItem<P extends BitArrayPath<T>>(path: P, from: number, to: number): void;
168
+ swapItems<P extends BitArrayPath<T>>(path: P, indexA: number, indexB: number): void;
169
+ undo(): void;
170
+ redo(): void;
171
+ getHistoryMetadata(): BitHistoryMetadata;
172
+ getPersistMetadata(): BitPersistMetadata;
173
+ restorePersisted(): Promise<boolean>;
174
+ forceSave(): Promise<void>;
175
+ clearPersisted(): Promise<void>;
176
+ getDirtyValues(): Partial<T>;
177
+ hasValidationsInProgress(scopeFields?: string[]): boolean;
178
+ getScopeFields(scopeName: string): string[];
179
+ getStepStatus(scopeName: string): ScopeStatus;
180
+ getStepErrors(scopeName: string): Record<string, string>;
181
+ subscribePersistMeta(listener: (meta: BitPersistMetadata) => void): () => void;
182
+ subscribeHistoryMeta(listener: (meta: BitHistoryMetadata) => void): () => void;
183
+ subscribeScopeStatus(scopeName: string, listener: (status: ScopeStatus) => void): () => void;
184
+ createArrayItemId(path: string, index?: number): string;
185
+ }
186
+
187
+ export type { BitArrayBindingApi as B, BitStoreHooksApi as a, BitFormBindingApi as b, BitHistoryMetadata as c, BitValidationOptions as d, BitFormMetaBindingApi as e, BitFormMeta as f, BitFieldBindingApi as g, BitEqualityFn as h, BitFrameworkConfig as i, BitSelector as j, BitSelectorSubscriptionOptions as k, BitStoreApi as l, BitStoreArrayFeatureApi as m, BitStoreFeatureApi as n, BitStoreHistoryFeatureApi as o, BitStoreObserveApi as p, BitStorePersistFeatureApi as q, BitStoreQueryApi as r, BitStoreRegistrationFeatureApi as s, BitStoreWriteApi as t };
@@ -24,4 +24,4 @@ interface DateMaskConfig extends PatternMaskOptions {
24
24
  format?: "DD/MM/YYYY" | "YYYY-MM-DD";
25
25
  }
26
26
 
27
- export type { BitMask as B, CurrencyMaskConfig as C, DateMaskConfig as D, PatternMaskOptions as P, BitMaskName as a, BitBuiltInMaskName as b };
27
+ export type { BitMask as B, CurrencyMaskConfig as C, DateMaskConfig as D, PatternMaskOptions as P, BitBuiltInMaskName as a, BitMaskName as b };
@@ -24,4 +24,4 @@ interface DateMaskConfig extends PatternMaskOptions {
24
24
  format?: "DD/MM/YYYY" | "YYYY-MM-DD";
25
25
  }
26
26
 
27
- export type { BitMask as B, CurrencyMaskConfig as C, DateMaskConfig as D, PatternMaskOptions as P, BitMaskName as a, BitBuiltInMaskName as b };
27
+ export type { BitMask as B, CurrencyMaskConfig as C, DateMaskConfig as D, PatternMaskOptions as P, BitBuiltInMaskName as a, BitMaskName as b };
@@ -1,14 +1,15 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React from 'react';
3
- import { e as BitStoreApi, f as BitStoreHooksApi, c as BitHistoryMetadata, d as BitValidationOptions } from './public-types-CVgFf_qY.js';
4
- import { f as BitPath, g as BitPathValue, j as BitPersistMetadata, S as ScopeStatus, n as ValidateScopeResult, i as BitErrors, H as BitTouched, h as DeepPartial, k as BitArrayPath, l as BitArrayItem } from './bus-B4zZmB9C.js';
5
- import { B as BitFieldInputEvent } from './field-binding-BXw0Ku2c.js';
3
+ import { a as BitStoreHooksApi, b as BitFormBindingApi, c as BitHistoryMetadata, d as BitValidationOptions } from './store-api-types-9ipdute1.js';
4
+ import { e as BitPath, b as BitPathValue, i as BitPersistMetadata, S as ScopeStatus, V as ValidateScopeResult, c as BitErrors, r as BitTouched, D as DeepPartial, B as BitArrayPath, a as BitArrayItem } from './bus-DgilLszS.js';
5
+ import { B as BitArrayBindingField } from './array-controller-DtkmcnUr.js';
6
+ import { B as BitFieldInputEvent } from './field-binding-Bi1g-D8X.js';
6
7
 
7
8
  declare const BitFormProvider: ({ store, children, }: {
8
- store: BitStoreApi<any>;
9
+ store: BitStoreHooksApi<any>;
9
10
  children: React.ReactNode;
10
11
  }) => react_jsx_runtime.JSX.Element;
11
- declare const useBitStore: <T extends object>() => BitStoreHooksApi<T>;
12
+ declare const useBitStore: <T extends object>() => BitFormBindingApi<T>;
12
13
 
13
14
  /**
14
15
  * Metadata describing the current state of a form field.
@@ -118,9 +119,10 @@ interface UseBitFormResult<T extends object = any> {
118
119
  transaction: <TResult>(callback: () => TResult) => TResult;
119
120
  setField: <P extends BitPath<T>>(path: P, value: BitPathValue<T, P>) => void;
120
121
  blurField: <P extends BitPath<T>>(path: P) => void;
121
- replaceValues: (values: T) => void;
122
- hydrate: (values: DeepPartial<T>) => void;
123
- rebase: (values: T) => void;
122
+ setValues: (values: T | DeepPartial<T>, options?: {
123
+ partial?: boolean;
124
+ rebase?: boolean;
125
+ }) => void;
124
126
  setError: (path: string, message: string | undefined) => void;
125
127
  setErrors: (errors: BitErrors<T>) => void;
126
128
  setServerErrors: (serverErrors: Record<string, string[] | string>) => void;
@@ -130,6 +132,8 @@ interface UseBitFormResult<T extends object = any> {
130
132
  declare function useBitForm<T extends object>(): UseBitFormResult<T>;
131
133
 
132
134
  declare function useBitArray<TForm extends object = any, P extends BitArrayPath<TForm> = BitArrayPath<TForm>>(path: P): {
135
+ fields: BitArrayBindingField<BitArrayItem<BitPathValue<TForm, P>>>[];
136
+ length: number;
133
137
  append: (value: BitArrayItem<BitPathValue<TForm, P>>) => void;
134
138
  prepend: (value: BitArrayItem<BitPathValue<TForm, P>>) => void;
135
139
  insert: (index: number, value: BitArrayItem<BitPathValue<TForm, P>>) => void;
@@ -138,12 +142,6 @@ declare function useBitArray<TForm extends object = any, P extends BitArrayPath<
138
142
  swap: (indexA: number, indexB: number) => void;
139
143
  replace: (items: BitArrayItem<BitPathValue<TForm, P>>[]) => void;
140
144
  clear: () => void;
141
- fields: {
142
- key: string;
143
- value: BitArrayItem<BitPathValue<TForm, P>>;
144
- index: number;
145
- }[];
146
- length: number;
147
145
  };
148
146
 
149
147
  declare function useBitScope(scopeName: string): {
@@ -1,14 +1,15 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React from 'react';
3
- import { e as BitStoreApi, f as BitStoreHooksApi, c as BitHistoryMetadata, d as BitValidationOptions } from './public-types-BQXaxmAE.cjs';
4
- import { f as BitPath, g as BitPathValue, j as BitPersistMetadata, S as ScopeStatus, n as ValidateScopeResult, i as BitErrors, H as BitTouched, h as DeepPartial, k as BitArrayPath, l as BitArrayItem } from './bus-BeAeZwWu.cjs';
5
- import { B as BitFieldInputEvent } from './field-binding-BXw0Ku2c.cjs';
3
+ import { a as BitStoreHooksApi, b as BitFormBindingApi, c as BitHistoryMetadata, d as BitValidationOptions } from './store-api-types-B6_bPoVI.cjs';
4
+ import { e as BitPath, b as BitPathValue, i as BitPersistMetadata, S as ScopeStatus, V as ValidateScopeResult, c as BitErrors, r as BitTouched, D as DeepPartial, B as BitArrayPath, a as BitArrayItem } from './bus-rcUiufS7.cjs';
5
+ import { B as BitArrayBindingField } from './array-controller-C1A5VKYd.cjs';
6
+ import { B as BitFieldInputEvent } from './field-binding-X5TkvfUt.cjs';
6
7
 
7
8
  declare const BitFormProvider: ({ store, children, }: {
8
- store: BitStoreApi<any>;
9
+ store: BitStoreHooksApi<any>;
9
10
  children: React.ReactNode;
10
11
  }) => react_jsx_runtime.JSX.Element;
11
- declare const useBitStore: <T extends object>() => BitStoreHooksApi<T>;
12
+ declare const useBitStore: <T extends object>() => BitFormBindingApi<T>;
12
13
 
13
14
  /**
14
15
  * Metadata describing the current state of a form field.
@@ -118,9 +119,10 @@ interface UseBitFormResult<T extends object = any> {
118
119
  transaction: <TResult>(callback: () => TResult) => TResult;
119
120
  setField: <P extends BitPath<T>>(path: P, value: BitPathValue<T, P>) => void;
120
121
  blurField: <P extends BitPath<T>>(path: P) => void;
121
- replaceValues: (values: T) => void;
122
- hydrate: (values: DeepPartial<T>) => void;
123
- rebase: (values: T) => void;
122
+ setValues: (values: T | DeepPartial<T>, options?: {
123
+ partial?: boolean;
124
+ rebase?: boolean;
125
+ }) => void;
124
126
  setError: (path: string, message: string | undefined) => void;
125
127
  setErrors: (errors: BitErrors<T>) => void;
126
128
  setServerErrors: (serverErrors: Record<string, string[] | string>) => void;
@@ -130,6 +132,8 @@ interface UseBitFormResult<T extends object = any> {
130
132
  declare function useBitForm<T extends object>(): UseBitFormResult<T>;
131
133
 
132
134
  declare function useBitArray<TForm extends object = any, P extends BitArrayPath<TForm> = BitArrayPath<TForm>>(path: P): {
135
+ fields: BitArrayBindingField<BitArrayItem<BitPathValue<TForm, P>>>[];
136
+ length: number;
133
137
  append: (value: BitArrayItem<BitPathValue<TForm, P>>) => void;
134
138
  prepend: (value: BitArrayItem<BitPathValue<TForm, P>>) => void;
135
139
  insert: (index: number, value: BitArrayItem<BitPathValue<TForm, P>>) => void;
@@ -138,12 +142,6 @@ declare function useBitArray<TForm extends object = any, P extends BitArrayPath<
138
142
  swap: (indexA: number, indexB: number) => void;
139
143
  replace: (items: BitArrayItem<BitPathValue<TForm, P>>[]) => void;
140
144
  clear: () => void;
141
- fields: {
142
- key: string;
143
- value: BitArrayItem<BitPathValue<TForm, P>>;
144
- index: number;
145
- }[];
146
- length: number;
147
145
  };
148
146
 
149
147
  declare function useBitScope(scopeName: string): {