@ember-data/model 5.5.0-alpha.9 → 5.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/LICENSE.md +19 -7
  2. package/README.md +21 -2
  3. package/addon-main.cjs +5 -0
  4. package/blueprints/model/index.js +18 -5
  5. package/blueprints/model-test/index.js +16 -10
  6. package/blueprints/model-test/qunit-files/__root__/__path__/__test__.js +4 -5
  7. package/dist/-private.js +3 -0
  8. package/{addon → dist}/-private.js.map +1 -1
  9. package/dist/has-many-BXU96bZ9.js +682 -0
  10. package/dist/has-many-BXU96bZ9.js.map +1 -0
  11. package/dist/hooks-o1U_cEA3.js +75 -0
  12. package/dist/hooks-o1U_cEA3.js.map +1 -0
  13. package/dist/hooks.js +2 -0
  14. package/{addon → dist}/hooks.js.map +1 -1
  15. package/dist/index.js +5 -0
  16. package/{addon → dist}/index.js.map +1 -1
  17. package/dist/migration-support.js +388 -0
  18. package/dist/migration-support.js.map +1 -0
  19. package/{addon/model-5a9ec6a9.js → dist/model-Dkk-TZlL.js} +2566 -2433
  20. package/dist/model-Dkk-TZlL.js.map +1 -0
  21. package/dist/schema-provider-DyG6fJXt.js +259 -0
  22. package/dist/schema-provider-DyG6fJXt.js.map +1 -0
  23. package/logos/NCC-1701-a-blue.svg +4 -0
  24. package/logos/NCC-1701-a-gold.svg +4 -0
  25. package/logos/NCC-1701-a-gold_100.svg +1 -0
  26. package/logos/NCC-1701-a-gold_base-64.txt +1 -0
  27. package/logos/NCC-1701-a.svg +4 -0
  28. package/logos/README.md +4 -0
  29. package/logos/docs-badge.svg +2 -0
  30. package/logos/ember-data-logo-dark.svg +12 -0
  31. package/logos/ember-data-logo-light.svg +12 -0
  32. package/logos/github-header.svg +444 -0
  33. package/logos/social1.png +0 -0
  34. package/logos/social2.png +0 -0
  35. package/logos/warp-drive-logo-dark.svg +4 -0
  36. package/logos/warp-drive-logo-gold.svg +4 -0
  37. package/package.json +62 -58
  38. package/unstable-preview-types/-private/attr.d.ts +175 -0
  39. package/unstable-preview-types/-private/attr.d.ts.map +1 -0
  40. package/unstable-preview-types/-private/attr.type-test.d.ts +4 -0
  41. package/unstable-preview-types/-private/attr.type-test.d.ts.map +1 -0
  42. package/unstable-preview-types/-private/belongs-to.d.ts +181 -0
  43. package/unstable-preview-types/-private/belongs-to.d.ts.map +1 -0
  44. package/unstable-preview-types/-private/belongs-to.type-test.d.ts +4 -0
  45. package/unstable-preview-types/-private/belongs-to.type-test.d.ts.map +1 -0
  46. package/unstable-preview-types/-private/debug/assert-polymorphic-type.d.ts +8 -0
  47. package/unstable-preview-types/-private/debug/assert-polymorphic-type.d.ts.map +1 -0
  48. package/unstable-preview-types/-private/errors.d.ts +303 -0
  49. package/unstable-preview-types/-private/errors.d.ts.map +1 -0
  50. package/unstable-preview-types/-private/has-many.d.ts +169 -0
  51. package/unstable-preview-types/-private/has-many.d.ts.map +1 -0
  52. package/unstable-preview-types/-private/has-many.type-test.d.ts +4 -0
  53. package/unstable-preview-types/-private/has-many.type-test.d.ts.map +1 -0
  54. package/unstable-preview-types/-private/hooks.d.ts +13 -0
  55. package/unstable-preview-types/-private/hooks.d.ts.map +1 -0
  56. package/unstable-preview-types/-private/legacy-relationships-support.d.ts +60 -0
  57. package/unstable-preview-types/-private/legacy-relationships-support.d.ts.map +1 -0
  58. package/unstable-preview-types/-private/model-for-mixin.d.ts +6 -0
  59. package/unstable-preview-types/-private/model-for-mixin.d.ts.map +1 -0
  60. package/unstable-preview-types/-private/model-methods.d.ts +37 -0
  61. package/unstable-preview-types/-private/model-methods.d.ts.map +1 -0
  62. package/unstable-preview-types/-private/model.d.ts +1303 -0
  63. package/unstable-preview-types/-private/model.d.ts.map +1 -0
  64. package/unstable-preview-types/-private/model.type-test.d.ts +4 -0
  65. package/unstable-preview-types/-private/model.type-test.d.ts.map +1 -0
  66. package/unstable-preview-types/-private/notify-changes.d.ts +8 -0
  67. package/unstable-preview-types/-private/notify-changes.d.ts.map +1 -0
  68. package/unstable-preview-types/-private/promise-belongs-to.d.ts +46 -0
  69. package/unstable-preview-types/-private/promise-belongs-to.d.ts.map +1 -0
  70. package/unstable-preview-types/-private/promise-many-array.d.ts +136 -0
  71. package/unstable-preview-types/-private/promise-many-array.d.ts.map +1 -0
  72. package/unstable-preview-types/-private/promise-proxy-base.d.ts +5 -0
  73. package/unstable-preview-types/-private/promise-proxy-base.d.ts.map +1 -0
  74. package/unstable-preview-types/-private/record-state.d.ts +80 -0
  75. package/unstable-preview-types/-private/record-state.d.ts.map +1 -0
  76. package/unstable-preview-types/-private/references/belongs-to.d.ts +506 -0
  77. package/unstable-preview-types/-private/references/belongs-to.d.ts.map +1 -0
  78. package/unstable-preview-types/-private/references/has-many.d.ts +518 -0
  79. package/unstable-preview-types/-private/references/has-many.d.ts.map +1 -0
  80. package/unstable-preview-types/-private/schema-provider.d.ts +65 -0
  81. package/unstable-preview-types/-private/schema-provider.d.ts.map +1 -0
  82. package/unstable-preview-types/-private/type-utils.d.ts +64 -0
  83. package/unstable-preview-types/-private/type-utils.d.ts.map +1 -0
  84. package/unstable-preview-types/-private/util.d.ts +8 -0
  85. package/unstable-preview-types/-private/util.d.ts.map +1 -0
  86. package/unstable-preview-types/-private.d.ts +13 -0
  87. package/unstable-preview-types/-private.d.ts.map +1 -0
  88. package/unstable-preview-types/hooks.d.ts +5 -0
  89. package/unstable-preview-types/hooks.d.ts.map +1 -0
  90. package/unstable-preview-types/index.d.ts +77 -0
  91. package/unstable-preview-types/index.d.ts.map +1 -0
  92. package/unstable-preview-types/migration-support.d.ts +271 -0
  93. package/unstable-preview-types/migration-support.d.ts.map +1 -0
  94. package/unstable-preview-types/migration-support.type-test.d.ts +4 -0
  95. package/unstable-preview-types/migration-support.type-test.d.ts.map +1 -0
  96. package/addon/-private.js +0 -2
  97. package/addon/has-many-76406f33.js +0 -321
  98. package/addon/has-many-76406f33.js.map +0 -1
  99. package/addon/hooks-dde806e1.js +0 -157
  100. package/addon/hooks-dde806e1.js.map +0 -1
  101. package/addon/hooks.js +0 -1
  102. package/addon/index.js +0 -3
  103. package/addon/model-5a9ec6a9.js.map +0 -1
  104. package/addon-main.js +0 -93
@@ -0,0 +1,518 @@
1
+ declare module '@ember-data/model/-private/references/has-many' {
2
+ import type { CollectionEdge, Graph } from '@ember-data/graph/-private';
3
+ import type Store from '@ember-data/store';
4
+ import type { RelatedCollection as ManyArray } from '@ember-data/store/-private';
5
+ import type { BaseFinderOptions } from '@ember-data/store/types';
6
+ import type { StableRecordIdentifier } from '@warp-drive/core-types';
7
+ import type { TypeFromInstanceOrString } from '@warp-drive/core-types/record';
8
+ import type { CollectionResourceDocument, CollectionResourceRelationship, ExistingResourceObject, LinkObject, Meta, PaginationLinks } from '@warp-drive/core-types/spec/json-api-raw';
9
+ import type { IsUnknown } from '@ember-data/model/-private/belongs-to';
10
+ import type { MaybeHasManyFields } from '@ember-data/model/-private/type-utils';
11
+ /**
12
+ @module @ember-data/model
13
+ */
14
+ interface ResourceIdentifier {
15
+ links?: {
16
+ related?: string | LinkObject;
17
+ };
18
+ meta?: Meta;
19
+ }
20
+ type ArrayItemType<T> = T extends (infer U)[] ? U : never;
21
+ /**
22
+ A `HasManyReference` is a low-level API that allows access
23
+ and manipulation of a hasMany relationship.
24
+
25
+ It is especially useful when you're dealing with `async` relationships
26
+ from `@ember-data/model` as it allows synchronous access to
27
+ the relationship data if loaded, as well as APIs for loading, reloading
28
+ the data or accessing available information without triggering a load.
29
+
30
+ It may also be useful when using `sync` relationships with `@ember-data/model`
31
+ that need to be loaded/reloaded with more precise timing than marking the
32
+ relationship as `async` and relying on autofetch would have allowed.
33
+
34
+ However,keep in mind that marking a relationship as `async: false` will introduce
35
+ bugs into your application if the data is not always guaranteed to be available
36
+ by the time the relationship is accessed. Ergo, it is recommended when using this
37
+ approach to utilize `links` for unloaded relationship state instead of identifiers.
38
+
39
+ Reference APIs are entangled with the relationship's underlying state,
40
+ thus any getters or cached properties that utilize these will properly
41
+ invalidate if the relationship state changes.
42
+
43
+ References are "stable", meaning that multiple calls to retrieve the reference
44
+ for a given relationship will always return the same HasManyReference.
45
+
46
+ @class HasManyReference
47
+ @public
48
+ */
49
+ export default class HasManyReference<T = unknown, K extends string = IsUnknown<T> extends true ? string : MaybeHasManyFields<T>, Related = K extends keyof T ? ArrayItemType<Awaited<T[K]>> : unknown> {
50
+ graph: Graph;
51
+ store: Store;
52
+ hasManyRelationship: CollectionEdge;
53
+ /**
54
+ * The field name on the parent record for this has-many relationship.
55
+ *
56
+ * @property key
57
+ * @type {String}
58
+ * @public
59
+ */
60
+ key: K;
61
+ /**
62
+ * The type of resource this relationship will contain.
63
+ *
64
+ * @property type
65
+ * @type {String}
66
+ * @public
67
+ */
68
+ type: TypeFromInstanceOrString<Related>;
69
+ ___token: object;
70
+ ___identifier: StableRecordIdentifier<TypeFromInstanceOrString<T>>;
71
+ ___relatedTokenMap: Map<StableRecordIdentifier, object>;
72
+ _ref: number;
73
+ constructor(store: Store, graph: Graph, parentIdentifier: StableRecordIdentifier<TypeFromInstanceOrString<T>>, hasManyRelationship: CollectionEdge, key: K);
74
+ /**
75
+ * This method should never be called by user code.
76
+ *
77
+ * @internal
78
+ */
79
+ destroy(): void;
80
+ /**
81
+ * An array of identifiers for the records that this reference refers to.
82
+ *
83
+ * @property identifiers
84
+ * @type {StableRecordIdentifier[]}
85
+ * @public
86
+ */
87
+ get identifiers(): StableRecordIdentifier<TypeFromInstanceOrString<Related>>[];
88
+ _resource(): CollectionResourceRelationship;
89
+ /**
90
+ This returns a string that represents how the reference will be
91
+ looked up when it is loaded. If the relationship has a link it will
92
+ use the "link" otherwise it defaults to "id".
93
+
94
+ Example
95
+
96
+ ```app/models/post.js
97
+ import Model, { hasMany } from '@ember-data/model';
98
+
99
+ export default class PostModel extends Model {
100
+ @hasMany('comment', { async: true, inverse: null }) comments;
101
+ }
102
+ ```
103
+
104
+ ```javascript
105
+ let post = store.push({
106
+ data: {
107
+ type: 'post',
108
+ id: 1,
109
+ relationships: {
110
+ comments: {
111
+ data: [{ type: 'comment', id: 1 }]
112
+ }
113
+ }
114
+ }
115
+ });
116
+
117
+ let commentsRef = post.hasMany('comments');
118
+
119
+ // get the identifier of the reference
120
+ if (commentsRef.remoteType() === "ids") {
121
+ let ids = commentsRef.ids();
122
+ } else if (commentsRef.remoteType() === "link") {
123
+ let link = commentsRef.link();
124
+ }
125
+ ```
126
+
127
+ @method remoteType
128
+ @public
129
+ @return {String} The name of the remote type. This should either be `link` or `ids`
130
+ */
131
+ remoteType(): 'link' | 'ids';
132
+ /**
133
+ `ids()` returns an array of the record IDs in this relationship.
134
+
135
+ Example
136
+
137
+ ```app/models/post.js
138
+ import Model, { hasMany } from '@ember-data/model';
139
+
140
+ export default class PostModel extends Model {
141
+ @hasMany('comment', { async: true, inverse: null }) comments;
142
+ }
143
+ ```
144
+
145
+ ```javascript
146
+ let post = store.push({
147
+ data: {
148
+ type: 'post',
149
+ id: 1,
150
+ relationships: {
151
+ comments: {
152
+ data: [{ type: 'comment', id: 1 }]
153
+ }
154
+ }
155
+ }
156
+ });
157
+
158
+ let commentsRef = post.hasMany('comments');
159
+
160
+ commentsRef.ids(); // ['1']
161
+ ```
162
+
163
+ @method ids
164
+ @public
165
+ @return {Array} The ids in this has-many relationship
166
+ */
167
+ ids(): Array<string | null>;
168
+ /**
169
+ The link Ember Data will use to fetch or reload this belongs-to
170
+ relationship. By default it uses only the "related" resource linkage.
171
+
172
+ Example
173
+
174
+ ```javascript
175
+ // models/blog.js
176
+ import Model, { belongsTo } from '@ember-data/model';
177
+ export default Model.extend({
178
+ user: belongsTo('user', { async: true, inverse: null })
179
+ });
180
+
181
+ let blog = store.push({
182
+ data: {
183
+ type: 'blog',
184
+ id: 1,
185
+ relationships: {
186
+ user: {
187
+ links: {
188
+ related: '/articles/1/author'
189
+ }
190
+ }
191
+ }
192
+ }
193
+ });
194
+ let userRef = blog.belongsTo('user');
195
+
196
+ // get the identifier of the reference
197
+ if (userRef.remoteType() === "link") {
198
+ let link = userRef.link();
199
+ }
200
+ ```
201
+
202
+ @method link
203
+ @public
204
+ @return {String} The link Ember Data will use to fetch or reload this belongs-to relationship.
205
+ */
206
+ link(): string | null;
207
+ /**
208
+ * any links that have been received for this relationship
209
+ *
210
+ * @method links
211
+ * @public
212
+ * @return
213
+ */
214
+ links(): PaginationLinks | null;
215
+ /**
216
+ The meta data for the has-many relationship.
217
+
218
+ Example
219
+
220
+ ```javascript
221
+ // models/blog.js
222
+ import Model, { hasMany } from '@ember-data/model';
223
+ export default Model.extend({
224
+ users: hasMany('user', { async: true, inverse: null })
225
+ });
226
+
227
+ let blog = store.push({
228
+ data: {
229
+ type: 'blog',
230
+ id: 1,
231
+ relationships: {
232
+ users: {
233
+ links: {
234
+ related: {
235
+ href: '/articles/1/authors'
236
+ },
237
+ },
238
+ meta: {
239
+ lastUpdated: 1458014400000
240
+ }
241
+ }
242
+ }
243
+ }
244
+ });
245
+
246
+ let usersRef = blog.hasMany('user');
247
+
248
+ usersRef.meta() // { lastUpdated: 1458014400000 }
249
+ ```
250
+
251
+ @method meta
252
+ @public
253
+ @return {Object|null} The meta information for the belongs-to relationship.
254
+ */
255
+ meta(): Meta | null;
256
+ /**
257
+ `push` can be used to update the data in the relationship and EmberData
258
+ will treat the new data as the canonical value of this relationship on
259
+ the backend. An empty array will signify the canonical value should be
260
+ empty.
261
+
262
+ Example model
263
+
264
+ ```app/models/post.js
265
+ import Model, { hasMany } from '@ember-data/model';
266
+
267
+ export default class PostModel extends Model {
268
+ @hasMany('comment', { async: true, inverse: null }) comments;
269
+ }
270
+ ```
271
+
272
+ Setup some initial state, note we haven't loaded the comments yet:
273
+
274
+ ```js
275
+ const post = store.push({
276
+ data: {
277
+ type: 'post',
278
+ id: '1',
279
+ relationships: {
280
+ comments: {
281
+ data: [{ type: 'comment', id: '1' }]
282
+ }
283
+ }
284
+ }
285
+ });
286
+
287
+ const commentsRef = post.hasMany('comments');
288
+ commentsRef.ids(); // ['1']
289
+ ```
290
+
291
+ Update the state using `push`, note we can do this even without
292
+ having loaded these comments yet by providing resource identifiers.
293
+
294
+ Both full resources and resource identifiers are supported.
295
+
296
+ ```js
297
+ await commentsRef.push({
298
+ data: [
299
+ { type: 'comment', id: '2' },
300
+ { type: 'comment', id: '3' },
301
+ ]
302
+ });
303
+
304
+ commentsRef.ids(); // ['2', '3']
305
+ ```
306
+
307
+ For convenience, you can also pass in an array of resources or resource identifiers
308
+ without wrapping them in the `data` property:
309
+
310
+ ```js
311
+ await commentsRef.push([
312
+ { type: 'comment', id: '4' },
313
+ { type: 'comment', id: '5' },
314
+ ]);
315
+
316
+ commentsRef.ids(); // ['4', '5']
317
+ ```
318
+
319
+ When using the `data` property, you may also include other resource data via included,
320
+ as well as provide new links and meta to the relationship.
321
+
322
+ ```js
323
+ await commentsRef.push({
324
+ links: {
325
+ related: '/posts/1/comments'
326
+ },
327
+ meta: {
328
+ total: 2
329
+ },
330
+ data: [
331
+ { type: 'comment', id: '4' },
332
+ { type: 'comment', id: '5' },
333
+ ],
334
+ included: [
335
+ { type: 'other-thing', id: '1', attributes: { foo: 'bar' },
336
+ ]
337
+ });
338
+ ```
339
+
340
+ By default, the store will attempt to fetch any unloaded records before resolving
341
+ the returned promise with the ManyArray.
342
+
343
+ Alternatively, pass `true` as the second argument to avoid fetching unloaded records
344
+ and instead the promise will resolve with void without attempting to fetch. This is
345
+ particularly useful if you want to update the state of the relationship without
346
+ forcing the load of all of the associated records.
347
+
348
+ @method push
349
+ @public
350
+ @param {Array|Object} doc a JSONAPI document object describing the new value of this relationship.
351
+ @param {Boolean} [skipFetch] if `true`, do not attempt to fetch unloaded records
352
+ @return {Promise<ManyArray | void>}
353
+ */
354
+ push(doc: ExistingResourceObject[] | CollectionResourceDocument, skipFetch?: boolean): Promise<ManyArray<Related> | void>;
355
+ _isLoaded(): boolean | undefined;
356
+ /**
357
+ `value()` synchronously returns the current value of the has-many
358
+ relationship. Unlike `record.relationshipName`, calling
359
+ `value()` on a reference does not trigger a fetch if the async
360
+ relationship is not yet loaded. If the relationship is not loaded
361
+ it will always return `null`.
362
+
363
+ Example
364
+
365
+ ```app/models/post.js
366
+ import Model, { hasMany } from '@ember-data/model';
367
+
368
+ export default class PostModel extends Model {
369
+ @hasMany('comment', { async: true, inverse: null }) comments;
370
+ }
371
+ ```
372
+
373
+ ```javascript
374
+ let post = store.push({
375
+ data: {
376
+ type: 'post',
377
+ id: 1,
378
+ relationships: {
379
+ comments: {
380
+ data: [{ type: 'comment', id: 1 }]
381
+ }
382
+ }
383
+ }
384
+ });
385
+
386
+ let commentsRef = post.hasMany('comments');
387
+
388
+ post.comments.then(function(comments) {
389
+ commentsRef.value() === comments
390
+ })
391
+ ```
392
+
393
+ @method value
394
+ @public
395
+ @return {ManyArray}
396
+ */
397
+ value(): ManyArray<Related> | null;
398
+ /**
399
+ Loads the relationship if it is not already loaded. If the
400
+ relationship is already loaded this method does not trigger a new
401
+ load. This causes a request to the specified
402
+ relationship link or reloads all items currently in the relationship.
403
+
404
+ Example
405
+
406
+ ```app/models/post.js
407
+ import Model, { hasMany } from '@ember-data/model';
408
+
409
+ export default class PostModel extends Model {
410
+ @hasMany('comment', { async: true, inverse: null }) comments;
411
+ }
412
+ ```
413
+
414
+ ```javascript
415
+ let post = store.push({
416
+ data: {
417
+ type: 'post',
418
+ id: 1,
419
+ relationships: {
420
+ comments: {
421
+ data: [{ type: 'comment', id: 1 }]
422
+ }
423
+ }
424
+ }
425
+ });
426
+
427
+ let commentsRef = post.hasMany('comments');
428
+
429
+ commentsRef.load().then(function(comments) {
430
+ //...
431
+ });
432
+ ```
433
+
434
+ You may also pass in an options object whose properties will be
435
+ fed forward. This enables you to pass `adapterOptions` into the
436
+ request given to the adapter via the reference.
437
+
438
+ Example
439
+
440
+ ```javascript
441
+ commentsRef.load({ adapterOptions: { isPrivate: true } })
442
+ .then(function(comments) {
443
+ //...
444
+ });
445
+ ```
446
+
447
+ ```app/adapters/comment.js
448
+ export default ApplicationAdapter.extend({
449
+ findMany(store, type, id, snapshots) {
450
+ // In the adapter you will have access to adapterOptions.
451
+ let adapterOptions = snapshots[0].adapterOptions;
452
+ }
453
+ });
454
+ ```
455
+
456
+ @method load
457
+ @public
458
+ @param {Object} options the options to pass in.
459
+ @return {Promise} a promise that resolves with the ManyArray in
460
+ this has-many relationship.
461
+ */
462
+ load(options?: BaseFinderOptions): Promise<ManyArray<Related>>;
463
+ /**
464
+ Reloads this has-many relationship. This causes a request to the specified
465
+ relationship link or reloads all items currently in the relationship.
466
+
467
+ Example
468
+
469
+ ```app/models/post.js
470
+ import Model, { hasMany } from '@ember-data/model';
471
+
472
+ export default class PostModel extends Model {
473
+ @hasMany('comment', { async: true, inverse: null }) comments;
474
+ }
475
+ ```
476
+
477
+ ```javascript
478
+ let post = store.push({
479
+ data: {
480
+ type: 'post',
481
+ id: 1,
482
+ relationships: {
483
+ comments: {
484
+ data: [{ type: 'comment', id: 1 }]
485
+ }
486
+ }
487
+ }
488
+ });
489
+
490
+ let commentsRef = post.hasMany('comments');
491
+
492
+ commentsRef.reload().then(function(comments) {
493
+ //...
494
+ });
495
+ ```
496
+
497
+ You may also pass in an options object whose properties will be
498
+ fed forward. This enables you to pass `adapterOptions` into the
499
+ request given to the adapter via the reference. A full example
500
+ can be found in the `load` method.
501
+
502
+ Example
503
+
504
+ ```javascript
505
+ commentsRef.reload({ adapterOptions: { isPrivate: true } })
506
+ ```
507
+
508
+ @method reload
509
+ @public
510
+ @param {Object} options the options to pass in.
511
+ @return {Promise} a promise that resolves with the ManyArray in this has-many relationship.
512
+ */
513
+ reload(options?: BaseFinderOptions): Promise<ManyArray<Related>>;
514
+ }
515
+ export function isMaybeResource(object: ExistingResourceObject | ResourceIdentifier): object is ExistingResourceObject;
516
+ export {};
517
+ }
518
+ //# sourceMappingURL=has-many.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"has-many.d.ts","sourceRoot":"","sources":["../../../src/-private/references/has-many.ts"],"names":[],"mappings":"AAAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAiGE;IACI,IAAI,CACR,GAAG,EAAE,sBAAsB,EAAE,GAAG,0BAA0B,EAC1D,SAAS,CAAC,EAAE,OAAO,GAClB,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;IAiDrC,SAAS;IAaT;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwCG;IACH,KAAK,IAAI,SAAS,CAAC,OAAO,CAAC,GAAG,IAAI;IAclC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA+DG;IACG,IAAI,CAAC,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;IAapE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiDG;IACH,MAAM,CAAC,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;CAMjE;AAGD,wBAAgB,eAAe,CAAC,MAAM,EAAE,sBAAsB,GAAG,kBAAkB,GAAG,MAAM,IAAI,sBAAsB,CAGrH"}
@@ -0,0 +1,65 @@
1
+ declare module '@ember-data/model/-private/schema-provider' {
2
+ import type Store from '@ember-data/store';
3
+ import type { SchemaService } from '@ember-data/store/types';
4
+ import type { RecordIdentifier, StableRecordIdentifier } from '@warp-drive/core-types/identifier';
5
+ import type { ObjectValue } from '@warp-drive/core-types/json/raw';
6
+ import type { Derivation, HashFn, Transformation } from '@warp-drive/core-types/schema/concepts';
7
+ import type { ArrayField, DerivedField, GenericField, HashField, LegacyAttributeField, LegacyField, LegacyRelationshipField, ObjectField, ObjectSchema, ResourceSchema } from '@warp-drive/core-types/schema/fields';
8
+ import type { ModelFactory, ModelStore } from '@ember-data/model/-private/model';
9
+ type AttributesSchema = ReturnType<Exclude<SchemaService['attributesDefinitionFor'], undefined>>;
10
+ type RelationshipsSchema = ReturnType<Exclude<SchemaService['relationshipsDefinitionFor'], undefined>>;
11
+ type InternalSchema = {
12
+ schema: ResourceSchema;
13
+ fields: Map<string, LegacyAttributeField | LegacyRelationshipField>;
14
+ attributes: Record<string, LegacyAttributeField>;
15
+ relationships: Record<string, LegacyRelationshipField>;
16
+ };
17
+ export interface ModelSchemaProvider {
18
+ attributesDefinitionFor(resource: RecordIdentifier | {
19
+ type: string;
20
+ }): AttributesSchema;
21
+ relationshipsDefinitionFor(resource: RecordIdentifier | {
22
+ type: string;
23
+ }): RelationshipsSchema;
24
+ doesTypeExist(type: string): boolean;
25
+ }
26
+ export class ModelSchemaProvider implements SchemaService {
27
+ store: ModelStore;
28
+ _schemas: Map<string, InternalSchema>;
29
+ _typeMisses: Set<string>;
30
+ constructor(store: ModelStore);
31
+ resourceTypes(): Readonly<string[]>;
32
+ hasTrait(type: string): boolean;
33
+ resourceHasTrait(resource: StableRecordIdentifier | {
34
+ type: string;
35
+ }, trait: string): boolean;
36
+ transformation(field: GenericField | ObjectField | ArrayField | {
37
+ type: string;
38
+ }): Transformation;
39
+ derivation(field: DerivedField | {
40
+ type: string;
41
+ }): Derivation;
42
+ hashFn(field: HashField | {
43
+ type: string;
44
+ }): HashFn;
45
+ resource(resource: StableRecordIdentifier | {
46
+ type: string;
47
+ }): ResourceSchema | ObjectSchema;
48
+ registerResources(schemas: Array<ResourceSchema | ObjectSchema>): void;
49
+ registerResource(schema: ResourceSchema | ObjectSchema): void;
50
+ registerTransformation(transform: Transformation): void;
51
+ registerDerivation<R, T, FM extends ObjectValue | null>(derivation: Derivation<R, T, FM>): void;
52
+ registerHashFn(hashFn: HashFn): void;
53
+ _loadModelSchema(type: string): InternalSchema;
54
+ fields(resource: RecordIdentifier | {
55
+ type: string;
56
+ }): Map<string, LegacyField>;
57
+ hasResource(resource: {
58
+ type: string;
59
+ }): boolean;
60
+ }
61
+ export function buildSchema(store: Store): SchemaService;
62
+ export function getModelFactory(store: ModelStore, type: string): ModelFactory | null;
63
+ export {};
64
+ }
65
+ //# sourceMappingURL=schema-provider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema-provider.d.ts","sourceRoot":"","sources":["../../src/-private/schema-provider.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAC3C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAG7D,OAAO,KAAK,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;AAClG,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AACjG,OAAO,KAAK,EACV,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,SAAS,EACT,oBAAoB,EACpB,WAAW,EACX,uBAAuB,EACvB,WAAW,EACX,YAAY,EACZ,cAAc,EACf,MAAM,sCAAsC,CAAC;AAE9C,OAAO,KAAK,EAAuB,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAI7E,KAAK,gBAAgB,GAAG,UAAU,CAAC,OAAO,CAAC,aAAa,CAAC,yBAAyB,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC;AACjG,KAAK,mBAAmB,GAAG,UAAU,CAAC,OAAO,CAAC,aAAa,CAAC,4BAA4B,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC;AAEvG,KAAK,cAAc,GAAG;IACpB,MAAM,EAAE,cAAc,CAAC;IACvB,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,oBAAoB,GAAG,uBAAuB,CAAC,CAAC;IACpE,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC,CAAC;IACjD,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,uBAAuB,CAAC,CAAC;CACxD,CAAC;AAEF,MAAM,WAAW,mBAAmB;IAClC,uB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AI;IAG7D,sBAAsB,CAAC,SAAS,EAAE,cAAc,GAAG,IAAI;IAGvD,kBAAkB,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,SAAS,WAAW,GAAG,IAAI,EAAE,UAAU,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,GAAG,IAAI;IAG/F,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAGpC,gBAAgB,CAAC,IAAI,EAAE,MAAM;IAoC7B,MAAM,CAAC,QAAQ,EAAE,gBAAgB,GAAG;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,GAAG,CAAC,MAAM,EAAE,WAAW,CAAC;IAU/E,WAAW,CAAC,QAAQ,EAAE;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO;CAqBjD;AA2DD,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,GAAG,aAAa,CAEvD;AAED,wBAAgB,eAAe,CAAC,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,GAAG,YAAY,GAAG,IAAI,CAkCpF"}
@@ -0,0 +1,64 @@
1
+ declare module '@ember-data/model/-private/type-utils' {
2
+ import type { RelatedCollection } from '@ember-data/store/-private';
3
+ import type { TypedRecordInstance } from '@warp-drive/core-types/record';
4
+ import type { Type } from '@warp-drive/core-types/symbols';
5
+ import type { Model } from '@ember-data/model/-private/model';
6
+ import type { PromiseBelongsTo } from '@ember-data/model/-private/promise-belongs-to';
7
+ import type { PromiseManyArray } from '@ember-data/model/-private/promise-many-array';
8
+ type ExcludeNull<T> = Exclude<T, null> extends never ? T : Exclude<T, null>;
9
+ type GetMappedKey<M, V> = {
10
+ [K in keyof M]-?: ExcludeNull<M[K]> extends V ? K : never;
11
+ }[keyof M] & string;
12
+ /**
13
+ * Get the keys of fields that are maybe defined as `belongsTo` relationships
14
+ *
15
+ * "Maybe" because getter/computed fields might be returning values that look
16
+ * like relationships, but are not.
17
+ *
18
+ * @typedoc
19
+ */
20
+ export type MaybeBelongsToFields<ThisType> = _TrueKeys<ThisType> extends never ? string : _MaybeBelongsToFields<ThisType>;
21
+ export type _MaybeBelongsToFields<ThisType> = GetMappedKey<ThisType, PromiseBelongsTo | TypedRecordInstance>;
22
+ /**
23
+ * Get the keys of fields that are maybe defined as `hasMany` relationships
24
+ *
25
+ * "Maybe" because getter/computed fields might be returning values that look
26
+ * like relationships, but are not.
27
+ *
28
+ * @typedoc
29
+ */
30
+ export type MaybeHasManyFields<ThisType> = _TrueKeys<ThisType> extends never ? string : _MaybeHasManyFields<ThisType>;
31
+ type _MaybeHasManyFields<ThisType> = GetMappedKey<ThisType, RelatedCollection | PromiseManyArray>;
32
+ /**
33
+ * Get the keys of fields that are maybe defined as `attr` fields
34
+ *
35
+ * "Maybe" because getter/computed fields might be returning values that look
36
+ * like attributes, but are not.
37
+ *
38
+ * This is computed by excluding the keys that are defined as `belongsTo` or `hasMany`
39
+ * as well as the keys on EmberObject and the Model base class
40
+ *
41
+ * @typedoc
42
+ */
43
+ export type MaybeAttrFields<ThisType> = Exclude<_TrueKeys<ThisType>, _MaybeBelongsToFields<ThisType> | _MaybeHasManyFields<ThisType>>;
44
+ /**
45
+ * Get the keys of fields that are maybe defined as relationships
46
+ *
47
+ * "Maybe" because getter/computed fields might be returning values that look
48
+ * like relationships, but are not.
49
+ *
50
+ * @typedoc
51
+ */
52
+ export type MaybeRelationshipFields<ThisType> = _TrueKeys<ThisType> extends never ? string : _MaybeBelongsToFields<ThisType> | _MaybeHasManyFields<ThisType>;
53
+ type _TrueKeys<ThisType> = Exclude<keyof ThisType & string, (keyof Model & string) | typeof Type>;
54
+ export type isSubClass<ThisType> = _TrueKeys<ThisType> extends never ? false : true;
55
+ /**
56
+ * Get the keys of all fields defined on the given subclass of Model
57
+ * that don't exist on EmberObject or Model.
58
+ *
59
+ * @typedoc
60
+ */
61
+ export type SubclassKeys<ThisType> = _TrueKeys<ThisType> extends never ? string : _TrueKeys<ThisType>;
62
+ export {};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G,mBAAmB,CAAC,QAAQ,CAAC,CAAC;AACtH,KAAK,mBAAmB,CAAC,QAAQ,IAAI,YAAY,CAAC,QAAQ,EAAE,iBAAiB,GAAG,gBAAgB,CAAC,CAAC;AAElG;;;;;;;;;;GAUG;AACH,MAAM,MAAM,eAAe,CAAC,QAAQ,IAAI,OAAO,CAC7C,SAAS,CAAC,QAAQ,CAAC,EACnB,qBAAqB,CAAC,QAAQ,CAAC,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAChE,CAAC;AAEF;;;;;;;GAOG;AACH,MAAM,MAAM,uBAAuB,CAAC,QAAQ,IAC1C,SAAS,CAAC,QAAQ,CAAC,SAAS,KAAK,GAAG,MAAM,GAAG,qBAAqB,CAAC,QAAQ,CAAC,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAAC;AAE/G,KAAK,SAAS,CAAC,QAAQ,IAAI,OAAO,CAAC,MAAM,QAAQ,GAAG,MAAM,EAAE,CAAC,MAAM,KAAK,GAAG,MAAM,CAAC,GAAG,OAAO,IAAI,CAAC,CAAC;AAClG,MAAM,MAAM,UAAU,CAAC,QAAQ,IAAI,SAAS,CAAC,QAAQ,CAAC,SAAS,KAAK,GAAG,KAAK,GAAG,IAAI,CAAC;AACpF;;;;;GAKG;AACH,MAAM,MAAM,YAAY,CAAC,QAAQ,IAAI,SAAS,CAAC,QAAQ,CAAC,SAAS,KAAK,GAAG,MAAM,GAAG,SAAS,CAAC,QAAQ,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ declare module '@ember-data/model/-private/util' {
2
+ export type DecoratorPropertyDescriptor = (PropertyDescriptor & {
3
+ initializer?: () => unknown;
4
+ }) | undefined;
5
+ export function isElementDescriptor(args: unknown[]): args is [object, string, DecoratorPropertyDescriptor];
6
+ export function normalizeModelName(type: string): string;
7
+ }
8
+ //# sourceMappingURL=util.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../src/-private/util.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,2BAA2B,GAAG,CAAC,kBAAkB,GAAG;IAAE,WAAW,CAAC,EAAE,MAAM,OAAO,CAAA;CAAE,CAAC,GAAG,SAAS,CAAC;AAE7G,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,2BAA2B,CAAC,CAkB1G;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAsBvD"}