atom.io 0.6.8 → 0.6.9

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 (130) hide show
  1. package/dist/index.d.mts +226 -258
  2. package/dist/index.d.ts +226 -258
  3. package/dist/index.js +28 -1917
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.mjs +5 -1877
  6. package/dist/index.mjs.map +1 -1
  7. package/introspection/dist/index.d.mts +117 -171
  8. package/introspection/dist/index.d.ts +117 -171
  9. package/introspection/dist/index.js +6 -346
  10. package/introspection/dist/index.js.map +1 -1
  11. package/introspection/dist/index.mjs +5 -324
  12. package/introspection/dist/index.mjs.map +1 -1
  13. package/json/dist/index.d.mts +32 -1
  14. package/json/dist/index.d.ts +32 -1
  15. package/json/dist/index.js +31 -48
  16. package/json/dist/index.js.map +1 -1
  17. package/json/dist/index.mjs +6 -14
  18. package/json/dist/index.mjs.map +1 -1
  19. package/package.json +22 -14
  20. package/react/dist/index.js +34 -83
  21. package/react/dist/index.js.map +1 -1
  22. package/react/dist/index.mjs +7 -43
  23. package/react/dist/index.mjs.map +1 -1
  24. package/react-devtools/dist/index.css +1 -50
  25. package/react-devtools/dist/index.css.map +1 -1
  26. package/react-devtools/dist/index.d.mts +124 -188
  27. package/react-devtools/dist/index.d.ts +124 -188
  28. package/react-devtools/dist/index.js +56 -4674
  29. package/react-devtools/dist/index.js.map +1 -1
  30. package/react-devtools/dist/index.mjs +19 -4642
  31. package/react-devtools/dist/index.mjs.map +1 -1
  32. package/realtime/dist/index.d.mts +1 -3
  33. package/realtime/dist/index.d.ts +1 -3
  34. package/realtime/dist/index.js +26 -184
  35. package/realtime/dist/index.js.map +1 -1
  36. package/realtime/dist/index.mjs +4 -148
  37. package/realtime/dist/index.mjs.map +1 -1
  38. package/realtime-react/dist/index.d.mts +2 -4
  39. package/realtime-react/dist/index.d.ts +2 -4
  40. package/realtime-react/dist/index.js +41 -214
  41. package/realtime-react/dist/index.js.map +1 -1
  42. package/realtime-react/dist/index.mjs +9 -169
  43. package/realtime-react/dist/index.mjs.map +1 -1
  44. package/src/atom.ts +4 -3
  45. package/src/index.ts +12 -9
  46. package/src/logger.ts +5 -5
  47. package/src/selector.ts +3 -3
  48. package/src/silo.ts +36 -39
  49. package/src/subscribe.ts +24 -19
  50. package/src/timeline.ts +9 -4
  51. package/src/transaction.ts +3 -4
  52. package/src/internal/atom-internal.ts +0 -54
  53. package/src/internal/families-internal.ts +0 -144
  54. package/src/internal/get.ts +0 -129
  55. package/src/internal/index.ts +0 -15
  56. package/src/internal/is-default.ts +0 -35
  57. package/src/internal/operation.ts +0 -139
  58. package/src/internal/selector/create-read-write-selector.ts +0 -68
  59. package/src/internal/selector/create-readonly-selector.ts +0 -48
  60. package/src/internal/selector/index.ts +0 -4
  61. package/src/internal/selector/lookup-selector-sources.ts +0 -16
  62. package/src/internal/selector/register-selector.ts +0 -57
  63. package/src/internal/selector/trace-selector-atoms.ts +0 -43
  64. package/src/internal/selector/update-selector-atoms.ts +0 -33
  65. package/src/internal/selector-internal.ts +0 -58
  66. package/src/internal/set.ts +0 -99
  67. package/src/internal/store.ts +0 -151
  68. package/src/internal/subscribe-internal.ts +0 -88
  69. package/src/internal/time-travel-internal.ts +0 -91
  70. package/src/internal/timeline/add-atom-to-timeline.ts +0 -168
  71. package/src/internal/timeline/index.ts +0 -1
  72. package/src/internal/timeline-internal.ts +0 -107
  73. package/src/internal/transaction/abort-transaction.ts +0 -12
  74. package/src/internal/transaction/apply-transaction.ts +0 -57
  75. package/src/internal/transaction/build-transaction.ts +0 -33
  76. package/src/internal/transaction/index.ts +0 -25
  77. package/src/internal/transaction/redo-transaction.ts +0 -23
  78. package/src/internal/transaction/undo-transaction.ts +0 -23
  79. package/src/internal/transaction-internal.ts +0 -61
  80. package/src/introspection/attach-atom-index.ts +0 -73
  81. package/src/introspection/attach-introspection-states.ts +0 -42
  82. package/src/introspection/attach-selector-index.ts +0 -77
  83. package/src/introspection/attach-timeline-family.ts +0 -59
  84. package/src/introspection/attach-timeline-index.ts +0 -36
  85. package/src/introspection/attach-transaction-index.ts +0 -38
  86. package/src/introspection/attach-transaction-logs.ts +0 -40
  87. package/src/introspection/index.ts +0 -20
  88. package/src/json/index.ts +0 -1
  89. package/src/json/select-json.ts +0 -18
  90. package/src/react/index.ts +0 -2
  91. package/src/react/store-context.tsx +0 -13
  92. package/src/react/store-hooks.ts +0 -47
  93. package/src/react-devtools/AtomIODevtools.tsx +0 -107
  94. package/src/react-devtools/Button.tsx +0 -24
  95. package/src/react-devtools/StateEditor.tsx +0 -74
  96. package/src/react-devtools/StateIndex.tsx +0 -156
  97. package/src/react-devtools/TimelineIndex.tsx +0 -92
  98. package/src/react-devtools/TransactionIndex.tsx +0 -70
  99. package/src/react-devtools/Updates.tsx +0 -145
  100. package/src/react-devtools/devtools.scss +0 -310
  101. package/src/react-devtools/index.ts +0 -72
  102. package/src/react-explorer/AtomIOExplorer.tsx +0 -218
  103. package/src/react-explorer/explorer-effects.ts +0 -20
  104. package/src/react-explorer/explorer-states.ts +0 -217
  105. package/src/react-explorer/index.ts +0 -23
  106. package/src/react-explorer/space-states.ts +0 -72
  107. package/src/react-explorer/view-states.ts +0 -41
  108. package/src/realtime/README.md +0 -33
  109. package/src/realtime/hook-composition/expose-family.ts +0 -101
  110. package/src/realtime/hook-composition/expose-single.ts +0 -38
  111. package/src/realtime/hook-composition/expose-timeline.ts +0 -60
  112. package/src/realtime/hook-composition/index.ts +0 -12
  113. package/src/realtime/hook-composition/receive-state.ts +0 -29
  114. package/src/realtime/hook-composition/receive-transaction.ts +0 -18
  115. package/src/realtime/index.ts +0 -1
  116. package/src/realtime-react/index.ts +0 -3
  117. package/src/realtime-react/realtime-context.tsx +0 -30
  118. package/src/realtime-react/realtime-hooks.ts +0 -39
  119. package/src/realtime-react/realtime-state.ts +0 -10
  120. package/src/realtime-react/use-pull-family-member.ts +0 -26
  121. package/src/realtime-react/use-pull-family.ts +0 -24
  122. package/src/realtime-react/use-pull.ts +0 -24
  123. package/src/realtime-react/use-push.ts +0 -27
  124. package/src/realtime-react/use-server-action.ts +0 -33
  125. package/src/realtime-testing/index.ts +0 -1
  126. package/src/realtime-testing/setup-realtime-test.tsx +0 -159
  127. package/src/tracker/index.ts +0 -3
  128. package/src/tracker/tracker.ts +0 -61
  129. package/src/web-effects/index.ts +0 -1
  130. package/src/web-effects/storage.ts +0 -30
@@ -1,15 +1,9 @@
1
- import { Refinement } from 'fp-ts/Refinement';
2
- import { AtomToken as AtomToken$1, ReadonlySelectorToken as ReadonlySelectorToken$1, SelectorToken as SelectorToken$1 } from 'atom.io';
1
+ import * as atom_io from 'atom.io';
2
+ import { StateToken, FamilyMetadata, TimelineUpdate, StateUpdate, TransactionUpdate, ƒn, AtomToken, ReadonlySelectorToken, SelectorToken, TransactionToken, TimelineToken, Logger } from 'atom.io';
3
+ import { Refinement as Refinement$1 } from 'fp-ts/Refinement';
3
4
 
4
5
  type PlainObject = Record<keyof any, unknown>;
5
6
 
6
- type ƒn = (...parameters: any[]) => any;
7
-
8
- type JsonInterface<T, J extends Serializable = Serializable> = {
9
- toJson: (t: T) => J;
10
- fromJson: (json: J) => T;
11
- };
12
-
13
7
  type primitive = boolean | number | string | null;
14
8
 
15
9
  type Serializable = primitive | Readonly<{
@@ -17,163 +11,63 @@ type Serializable = primitive | Readonly<{
17
11
  }> | ReadonlyArray<Serializable>;
18
12
  type Object$1<Key extends string = string, Value extends Serializable = Serializable> = Record<Key, Value>;
19
13
 
20
- type Identified = {
21
- id: string;
22
- };
14
+ type Refinement<Unrefined, Refined extends Unrefined> = (value: Unrefined) => value is Refined;
15
+ type Cardinality = `1:1` | `1:n` | `n:n`;
23
16
 
24
- declare const RELATION_TYPES: readonly ["1:1", "1:n", "n:n"];
25
- type RelationType = typeof RELATION_TYPES[number];
26
- type RelationData<CONTENT extends Object$1 | null = null, A extends string = `from`, B extends string = `to`> = {
27
- contents: Object$1<string, CONTENT>;
28
- relations: Object$1<string, string[]>;
29
- relationType: RelationType;
30
- a: A;
31
- b: B;
32
- };
33
- type IsRelationDataOptions<CONTENT extends Object$1 | null = null, A extends string = `from`, B extends string = `to`> = {
34
- from?: A;
35
- to?: B;
36
- isContent?: (json: Serializable) => json is CONTENT;
37
- };
38
-
39
- type NullSafeUnion<Base, Extension> = Extension extends null ? Base : Base & Extension;
40
- type NullSafeRest<MaybeArg, IfArg = MaybeArg> = MaybeArg extends null ? [] | [undefined] : [IfArg];
41
-
42
- declare class Join<CONTENT extends Object$1 | null = null, A extends string = `from`, B extends string = `to`> implements RelationData<CONTENT, A, B> {
43
- readonly relationType: `1:1` | `1:n` | `n:n`;
44
- readonly a: A;
45
- readonly b: B;
46
- readonly relations: Record<string, string[]>;
47
- readonly contents: Record<string, CONTENT>;
48
- constructor(json?: Partial<RelationData<CONTENT, A, B>>);
49
- toJSON(): RelationData<CONTENT, A, B>;
50
- static fromJSON<CONTENT extends Object$1 | null, A extends string, B extends string>(json: Serializable, options?: IsRelationDataOptions<CONTENT, A, B>): Join<CONTENT, A, B>;
51
- from<AA extends string>(newA: AA): Join<CONTENT, AA, B>;
52
- to<BB extends string>(newB: BB): Join<CONTENT, A, BB>;
53
- makeJsonInterface: (...params: CONTENT extends null ? [
54
- ] : [Refinement<unknown, CONTENT>]) => JsonInterface<Join<CONTENT, A, B>, RelationData<CONTENT, A, B>>;
55
- getRelatedId(id: string): string | undefined;
56
- getRelatedIds(id: string): string[];
57
- getContent(idA: string, idB: string): CONTENT | undefined;
58
- getRelationEntries(id: string): [string, CONTENT][];
59
- getRelationRecord(id: string): Record<string, CONTENT>;
60
- getRelation(id: string): NullSafeUnion<Identified, CONTENT> | undefined;
61
- getRelations(id: string): NullSafeUnion<Identified, CONTENT>[];
62
- setRelations(subject: {
63
- [from in A]: string;
64
- } | {
65
- [to in B]: string;
66
- }, relations: NullSafeUnion<Identified, CONTENT>[]): Join<CONTENT, A, B>;
67
- set(relation: {
68
- [key in A | B]: string;
69
- }, ...rest: NullSafeRest<CONTENT>): Join<CONTENT, A, B>;
70
- remove(relation: Partial<Record<A | B, string>>): Join<CONTENT, A, B>;
17
+ interface JunctionEntries<Content extends Object$1 | null> extends Object$1 {
18
+ readonly relations: [string, string[]][];
19
+ readonly contents: [string, Content][];
71
20
  }
72
-
73
- type AtomFamily<T, K extends Serializable = Serializable> = ((key: K) => AtomToken<T>) & {
74
- key: string;
75
- type: `atom_family`;
76
- subject: Subject<AtomToken<T>>;
77
- };
78
-
79
- type Logger = Pick<Console, `error` | `info` | `warn`>;
80
-
81
- type TransactionToken<_> = {
82
- key: string;
83
- type: `transaction`;
84
- __brand?: _;
85
- };
86
- type TransactionUpdate<ƒ extends ƒn> = {
87
- key: string;
88
- atomUpdates: KeyedStateUpdate<unknown>[];
89
- params: Parameters<ƒ>;
90
- output: ReturnType<ƒ>;
91
- };
92
-
93
- type ReadonlySelectorFamily<T, K extends Serializable = Serializable> = ((key: K) => ReadonlySelectorToken<T>) & {
94
- key: string;
95
- type: `readonly_selector_family`;
96
- subject: Subject<ReadonlySelectorToken<T>>;
97
- };
98
-
99
- type StateUpdate<T> = {
100
- newValue: T;
101
- oldValue: T;
102
- };
103
- type KeyedStateUpdate<T> = StateUpdate<T> & {
104
- key: string;
105
- };
106
-
107
- type TimelineToken = {
108
- key: string;
109
- type: `timeline`;
110
- };
111
- type TimelineUpdate = TimelineAtomUpdate | TimelineSelectorUpdate | TimelineTransactionUpdate;
112
-
113
- type AtomToken<_> = {
114
- key: string;
115
- type: `atom`;
116
- family?: FamilyMetadata;
117
- __brand?: _;
118
- };
119
- type SelectorToken<_> = {
120
- key: string;
121
- type: `selector`;
122
- family?: FamilyMetadata;
123
- __brand?: _;
124
- };
125
- type StateToken<T> = AtomToken<T> | SelectorToken<T>;
126
- type ReadonlySelectorToken<_> = {
127
- key: string;
128
- type: `readonly_selector`;
129
- family?: FamilyMetadata;
130
- __brand?: _;
131
- };
132
- type FamilyMetadata = {
133
- key: string;
134
- subKey: string;
135
- };
136
-
137
- type StoreCore = Pick<Store, `atoms` | `atomsThatAreDefault` | `operation` | `readonlySelectors` | `selectorAtoms` | `selectorGraph` | `selectors` | `timelineAtoms` | `timelines` | `transactions` | `valueMap`>;
138
- interface Store {
139
- atoms: Map<string, Atom<any>>;
140
- atomsThatAreDefault: Set<string>;
141
- readonlySelectors: Map<string, ReadonlySelector<any>>;
142
- selectorAtoms: Join<null, `selectorKey`, `atomKey`>;
143
- selectorGraph: Join<{
144
- source: string;
145
- }>;
146
- selectors: Map<string, Selector<any>>;
147
- timelineAtoms: Join<null, `timelineKey`, `atomKey`>;
148
- timelines: Map<string, Timeline>;
149
- transactions: Map<string, Transaction<any>>;
150
- valueMap: Map<string, any>;
151
- subject: {
152
- atomCreation: Subject<AtomToken<unknown>>;
153
- selectorCreation: Subject<ReadonlySelectorToken<unknown> | SelectorToken<unknown>>;
154
- transactionCreation: Subject<TransactionToken<ƒn>>;
155
- timelineCreation: Subject<TimelineToken>;
156
- operationStatus: Subject<OperationProgress>;
157
- };
158
- operation: OperationProgress;
159
- transactionStatus: TransactionStatus<ƒn>;
160
- config: {
161
- name: string;
162
- logger: Logger | null;
163
- logger__INTERNAL: Logger;
164
- };
21
+ interface JunctionSchema<ASide extends string, BSide extends string> extends Object$1 {
22
+ readonly between: [a: ASide, b: BSide];
23
+ readonly cardinality: Cardinality;
165
24
  }
166
-
167
- type Atom<T> = {
168
- key: string;
169
- type: `atom`;
170
- family?: FamilyMetadata;
171
- subject: Subject<{
172
- newValue: T;
173
- oldValue: T;
174
- }>;
175
- default: T;
25
+ type JunctionAdvancedConfiguration<Content extends Object$1 | null> = {
26
+ externalStore?: (Content extends null ? {
27
+ getContent?: undefined;
28
+ setContent?: undefined;
29
+ deleteContent?: undefined;
30
+ } : {
31
+ getContent: (contentKey: string) => Content | undefined;
32
+ setContent: (contentKey: string, content: Content) => void;
33
+ deleteContent: (g: any) => void;
34
+ }) & {
35
+ addRelation: (a: string, b: string) => void;
36
+ deleteRelation: (a: string, b: string) => void;
37
+ getRelatedKeys: (key: string) => Set<string> | undefined;
38
+ has: (a: string, b?: string) => boolean;
39
+ };
40
+ isContent?: Refinement<unknown, Content>;
41
+ makeContentKey?: (a: string, b: string) => string;
176
42
  };
43
+ type JunctionJSON<ASide extends string, BSide extends string, Content extends Object$1 | null> = JunctionEntries<Content> & JunctionSchema<ASide, BSide>;
44
+ declare class Junction<ASide extends string, BSide extends string, Content extends Object$1 | null = null> {
45
+ readonly a: ASide;
46
+ readonly b: BSide;
47
+ readonly cardinality: Cardinality;
48
+ readonly relations: Map<string, Set<string>>;
49
+ readonly contents: Map<string, Content>;
50
+ isContent: Refinement<unknown, Content> | null;
51
+ makeContentKey: (a: string, b: string) => string;
52
+ getRelatedKeys(key: string): Set<string> | undefined;
53
+ protected addRelation(a: string, b: string): void;
54
+ protected deleteRelation(a: string, b: string): void;
55
+ protected getContentInternal(contentKey: string): Content | undefined;
56
+ protected setContent(contentKey: string, content: Content): void;
57
+ protected deleteContent(contentKey: string): void;
58
+ constructor(data: JunctionSchema<ASide, BSide> & Partial<JunctionEntries<Content>>, config?: JunctionAdvancedConfiguration<Content>);
59
+ toJSON(): JunctionJSON<ASide, BSide, Content>;
60
+ set(a: string, ...rest: Content extends null ? [b: string] : [b: string, content: Content]): this;
61
+ set(relation: {
62
+ [Key in ASide | BSide]: string;
63
+ }, ...rest: Content extends null ? [] | [b?: undefined] : [content: Content]): this;
64
+ delete(a: string, b?: string): this;
65
+ delete(relation: Record<ASide | BSide, string> | Record<ASide, string> | Record<BSide, string>, b?: undefined): this;
66
+ getRelatedKey(key: string): string | undefined;
67
+ getContent(a: string, b: string): Content | undefined;
68
+ getRelationEntries(input: Record<ASide, string> | Record<BSide, string>): [string, Content][];
69
+ has(a: string, b?: string): boolean;
70
+ }
177
71
 
178
72
  type OperationProgress = {
179
73
  open: false;
@@ -185,6 +79,14 @@ type OperationProgress = {
185
79
  token: StateToken<any>;
186
80
  };
187
81
 
82
+ type Subscriber<T> = (value: T) => void;
83
+ declare class Subject<T> {
84
+ subscribers: Map<string, Subscriber<T>>;
85
+ subscribe(key: string, subscriber: Subscriber<T>): () => void;
86
+ private unsubscribe;
87
+ next(value: T): void;
88
+ }
89
+
188
90
  type Selector<T> = {
189
91
  key: string;
190
92
  type: `selector`;
@@ -209,20 +111,11 @@ type ReadonlySelector<T> = {
209
111
  get: () => T;
210
112
  };
211
113
 
212
- type Subscriber<T> = (value: T) => void;
213
- declare class Subject<T> {
214
- subscribers: Subscriber<T>[];
215
- subscribe(subscriber: Subscriber<T>): {
216
- unsubscribe: () => void;
217
- };
218
- private unsubscribe;
219
- next(value: T): void;
220
- }
221
-
222
114
  type TimelineAtomUpdate = StateUpdate<unknown> & {
223
115
  key: string;
224
116
  type: `atom_update`;
225
117
  timestamp: number;
118
+ family?: FamilyMetadata;
226
119
  };
227
120
  type TimelineSelectorUpdate = {
228
121
  key: string;
@@ -236,6 +129,7 @@ type TimelineTransactionUpdate = TransactionUpdate<ƒn> & {
236
129
  timestamp: number;
237
130
  };
238
131
  type Timeline = {
132
+ type: `timeline`;
239
133
  key: string;
240
134
  at: number;
241
135
  timeTraveling: `into_future` | `into_past` | null;
@@ -264,20 +158,62 @@ type TransactionIdle = {
264
158
  };
265
159
  type TransactionStatus<ƒ extends ƒn> = TransactionIdle | TransactionUpdateInProgress<ƒ>;
266
160
 
267
- type AtomTokenIndex = StateTokenIndex<AtomToken$1<unknown>>;
161
+ type StoreCore = Pick<Store, `atoms` | `atomsThatAreDefault` | `operation` | `readonlySelectors` | `selectorAtoms` | `selectorGraph` | `selectors` | `timelineAtoms` | `timelines` | `transactions` | `valueMap`>;
162
+ declare class Store {
163
+ valueMap: Map<string, any>;
164
+ atoms: Map<string, Atom<any>>;
165
+ selectors: Map<string, Selector<any>>;
166
+ readonlySelectors: Map<string, ReadonlySelector<any>>;
167
+ timelines: Map<string, Timeline>;
168
+ transactions: Map<string, Transaction<ƒn>>;
169
+ atomsThatAreDefault: Set<string>;
170
+ timelineAtoms: Junction<"timelineKey", "atomKey", null>;
171
+ selectorAtoms: Junction<"selectorKey", "atomKey", null>;
172
+ selectorGraph: Junction<"upstreamSelectorKey", "downstreamSelectorKey", {
173
+ source: string;
174
+ }>;
175
+ subject: {
176
+ atomCreation: Subject<AtomToken<unknown>>;
177
+ selectorCreation: Subject<ReadonlySelectorToken<unknown> | SelectorToken<unknown>>;
178
+ transactionCreation: Subject<TransactionToken<ƒn>>;
179
+ timelineCreation: Subject<TimelineToken>;
180
+ operationStatus: Subject<OperationProgress>;
181
+ };
182
+ operation: OperationProgress;
183
+ transactionStatus: TransactionStatus<ƒn>;
184
+ config: {
185
+ name: string;
186
+ logger: Logger | null;
187
+ logger__INTERNAL: Logger;
188
+ };
189
+ constructor(name: string, store?: Store | null);
190
+ }
191
+
192
+ type Atom<T> = {
193
+ key: string;
194
+ type: `atom`;
195
+ family?: FamilyMetadata;
196
+ subject: Subject<{
197
+ newValue: T;
198
+ oldValue: T;
199
+ }>;
200
+ default: T;
201
+ };
202
+
203
+ type AtomTokenIndex = StateTokenIndex<AtomToken<unknown>>;
268
204
 
269
- type FamilyNode<Token extends AtomToken$1<unknown> | ReadonlySelectorToken$1<unknown> | SelectorToken$1<unknown>> = {
205
+ type FamilyNode<Token extends AtomToken<unknown> | ReadonlySelectorToken<unknown> | SelectorToken<unknown>> = {
270
206
  key: string;
271
207
  familyMembers: Record<string, Token>;
272
208
  };
273
- type StateTokenIndex<Token extends AtomToken$1<unknown> | ReadonlySelectorToken$1<unknown> | SelectorToken$1<unknown>> = Record<string, FamilyNode<Token> | Token>;
209
+ type StateTokenIndex<Token extends AtomToken<unknown> | ReadonlySelectorToken<unknown> | SelectorToken<unknown>> = Record<string, FamilyNode<Token> | Token>;
274
210
 
275
- type SelectorTokenIndex = StateTokenIndex<ReadonlySelectorToken$1<unknown> | SelectorToken$1<unknown>>;
211
+ type SelectorTokenIndex = StateTokenIndex<ReadonlySelectorToken<unknown> | SelectorToken<unknown>>;
276
212
 
277
213
  type ClassSignature = abstract new (...args: any) => any;
278
214
 
279
- type RefinementStrategy = ClassSignature | Refinement<unknown, any>;
280
- type Supported<Refine extends RefinementStrategy> = Refine extends Refinement<unknown, infer T> ? T : Refine extends ClassSignature ? InstanceType<Refine> : never;
215
+ type RefinementStrategy = ClassSignature | Refinement$1<unknown, any>;
216
+ type Supported<Refine extends RefinementStrategy> = Refine extends Refinement$1<unknown, infer T> ? T : Refine extends ClassSignature ? InstanceType<Refine> : never;
281
217
  type RefinementSupport = Record<string, RefinementStrategy>;
282
218
  declare class Refinery<SupportedTypes extends RefinementSupport> {
283
219
  supported: SupportedTypes;
@@ -317,17 +253,17 @@ declare class Differ<Leaf extends Record<string, any>, Tree extends Record<strin
317
253
 
318
254
  declare const AtomIODevtools: () => JSX.Element;
319
255
 
320
- declare const atomIndex: ReadonlySelectorToken<AtomTokenIndex>;
321
- declare const selectorIndex: ReadonlySelectorToken<SelectorTokenIndex>;
322
- declare const transactionIndex: ReadonlySelectorToken<TransactionTokenn>[]>;
323
- declare const findTransactionLogState: ReadonlySelectorFamily<TransactionUpdaten>[]>;
324
- declare const timelineIndex: ReadonlySelectorToken<TimelineToken[]>;
325
- declare const findTimelineState: ReadonlySelectorFamily<Timeline>;
326
- declare const devtoolsAreOpenState: AtomToken<boolean>;
256
+ declare const atomIndex: atom_io.ReadonlySelectorToken<AtomTokenIndex>;
257
+ declare const selectorIndex: atom_io.ReadonlySelectorToken<SelectorTokenIndex>;
258
+ declare const transactionIndex: atom_io.ReadonlySelectorToken<atom_io.TransactionToken<atom_io.ƒn>[]>;
259
+ declare const findTransactionLogState: atom_io.ReadonlySelectorFamily<atom_io.TransactionUpdate<atom_io.ƒn>[]>;
260
+ declare const timelineIndex: atom_io.ReadonlySelectorToken<atom_io.TimelineToken[]>;
261
+ declare const findTimelineState: atom_io.ReadonlySelectorFamily<Timeline>;
262
+ declare const devtoolsAreOpenState: atom_io.AtomToken<boolean>;
327
263
  type DevtoolsView = `atoms` | `selectors` | `timelines` | `transactions`;
328
- declare const devtoolsViewSelectionState: AtomToken<DevtoolsView>;
329
- declare const devtoolsViewOptionsState: AtomToken<DevtoolsView[]>;
330
- declare const findViewIsOpenState: AtomFamily<boolean, string>;
264
+ declare const devtoolsViewSelectionState: atom_io.AtomToken<DevtoolsView>;
265
+ declare const devtoolsViewOptionsState: atom_io.AtomToken<DevtoolsView[]>;
266
+ declare const findViewIsOpenState: atom_io.AtomFamily<boolean, string>;
331
267
  declare const primitiveRefinery: Refinery<{
332
268
  number: (input: unknown) => input is number;
333
269
  string: (input: unknown) => input is string;