@ember-data/model 5.4.0-alpha.64 → 5.4.0-alpha.70
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/addon-main.cjs +5 -0
- package/blueprints/model/index.js +18 -5
- package/blueprints/model-test/index.js +16 -10
- package/blueprints/model-test/qunit-files/__root__/__path__/__test__.js +4 -5
- package/{addon → dist}/-private.js +2 -2
- package/{addon/has-many-BuTJfT5a.js → dist/has-many-CR10J-rp.js} +49 -26
- package/dist/has-many-CR10J-rp.js.map +1 -0
- package/dist/hooks-BNw6VdLr.js +75 -0
- package/dist/hooks-BNw6VdLr.js.map +1 -0
- package/dist/hooks.js +2 -0
- package/{addon → dist}/hooks.js.map +1 -1
- package/dist/index.js +4 -0
- package/{addon → dist}/index.js.map +1 -1
- package/dist/migration-support.js +211 -0
- package/dist/migration-support.js.map +1 -0
- package/{addon/model-DJ9C4aZ-.js → dist/model-CsbDNxap.js} +821 -250
- package/dist/model-CsbDNxap.js.map +1 -0
- package/dist/schema-provider-C5vR7TBr.js +256 -0
- package/dist/schema-provider-C5vR7TBr.js.map +1 -0
- package/package.json +39 -59
- package/unstable-preview-types/-private/attr.d.ts.map +1 -1
- package/unstable-preview-types/-private/belongs-to.d.ts.map +1 -1
- package/unstable-preview-types/-private/debug/assert-polymorphic-type.d.ts +2 -2
- package/unstable-preview-types/-private/debug/assert-polymorphic-type.d.ts.map +1 -1
- package/unstable-preview-types/-private/errors.d.ts +2 -5
- package/unstable-preview-types/-private/errors.d.ts.map +1 -1
- package/unstable-preview-types/-private/has-many.d.ts.map +1 -1
- package/unstable-preview-types/-private/hooks.d.ts.map +1 -1
- package/unstable-preview-types/-private/legacy-relationships-support.d.ts +16 -20
- package/unstable-preview-types/-private/legacy-relationships-support.d.ts.map +1 -1
- package/unstable-preview-types/-private/many-array.d.ts +11 -13
- package/unstable-preview-types/-private/many-array.d.ts.map +1 -1
- package/unstable-preview-types/-private/model-methods.d.ts +6 -5
- package/unstable-preview-types/-private/model-methods.d.ts.map +1 -1
- package/unstable-preview-types/-private/model.d.ts +38 -35
- package/unstable-preview-types/-private/model.d.ts.map +1 -1
- package/unstable-preview-types/-private/notify-changes.d.ts +1 -1
- package/unstable-preview-types/-private/notify-changes.d.ts.map +1 -1
- package/unstable-preview-types/-private/promise-belongs-to.d.ts +1 -2
- package/unstable-preview-types/-private/promise-belongs-to.d.ts.map +1 -1
- package/unstable-preview-types/-private/promise-many-array.d.ts +4 -4
- package/unstable-preview-types/-private/promise-many-array.d.ts.map +1 -1
- package/unstable-preview-types/-private/record-state.d.ts +3 -4
- package/unstable-preview-types/-private/record-state.d.ts.map +1 -1
- package/unstable-preview-types/-private/references/belongs-to.d.ts +4 -4
- package/unstable-preview-types/-private/references/belongs-to.d.ts.map +1 -1
- package/unstable-preview-types/-private/references/has-many.d.ts +7 -7
- package/unstable-preview-types/-private/references/has-many.d.ts.map +1 -1
- package/unstable-preview-types/-private/schema-provider.d.ts +46 -15
- package/unstable-preview-types/-private/schema-provider.d.ts.map +1 -1
- package/unstable-preview-types/-private/type-utils.d.ts +64 -0
- package/unstable-preview-types/-private/type-utils.d.ts.map +1 -0
- package/unstable-preview-types/-private.d.ts +4 -3
- package/unstable-preview-types/-private.d.ts.map +1 -1
- package/unstable-preview-types/index.d.ts +20 -20
- package/unstable-preview-types/index.d.ts.map +1 -1
- package/unstable-preview-types/migration-support.d.ts +45 -6
- package/unstable-preview-types/migration-support.d.ts.map +1 -1
- package/addon/has-many-BuTJfT5a.js.map +0 -1
- package/addon/hooks-BMoEt0SI.js +0 -176
- package/addon/hooks-BMoEt0SI.js.map +0 -1
- package/addon/hooks.js +0 -1
- package/addon/index.js +0 -3
- package/addon/migration-support.js +0 -118
- package/addon/migration-support.js.map +0 -1
- package/addon/model-DJ9C4aZ-.js.map +0 -1
- package/addon/util-CSYkrwfb.js +0 -35
- package/addon/util-CSYkrwfb.js.map +0 -1
- package/addon-main.js +0 -94
- package/unstable-preview-types/-private/promise-proxy-base.d.ts +0 -35
- /package/{addon → dist}/-private.js.map +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"legacy-relationships-support.d.ts","sourceRoot":"","sources":["../../src/-private/legacy-relationships-support.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"legacy-relationships-support.d.ts","sourceRoot":"","sources":["../../src/-private/legacy-relationships-support.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,KAAK,EAAa,YAAY,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/G,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAC3C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAS5D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAGjE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAErE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACxF,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;AAC/E,OAAO,KAAK,EAAE,oBAAoB,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACpG,OAAO,KAAK,EACV,8BAA8B,EAC9B,yBAAyB,EACzB,0BAA0B,EAC3B,MAAM,0CAA0C,CAAC;AAElD,OAAO,EAAE,iBAAiB,IAAI,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,KAAK,EAAE,wBAAwB,EAAsB,MAAM,sBAAsB,CAAC;AACzF,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACxD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAE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OAAO,EAAE,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC,CAAA;KAAE,GACtD,gBAAgB;IAiCnB,YAAY,CAAC,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,GAAG,kBAAkB;IACjE,YAAY,CAAC,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,GAAG,gBAAgB;IAuC7D,6BAA6B,CAC3B,QAAQ,EAAE,8BAA8B,EACxC,gBAAgB,EAAE,sBAAsB,EACxC,YAAY,EAAE,cAAc,EAC5B,OAAO,GAAE,iBAAsB,GAC9B,OAAO,CAAC,IAAI,GAAG,OAAO,EAAE,CAAC,GAAG,IAAI;IA2EnC,+BAA+B,CAC7B,QAAQ,EAAE,0BAA0B,EACpC,gBAAgB,EAAE,sBAAsB,EACxC,YAAY,EAAE,YAAY,EAC1B,OAAO,GAAE,iBAAsB,GAC9B,OAAO,CAAC,sBAAsB,GAAG,IAAI,CAAC;IA8FzC,OAAO;CAyBR;AA0GD,wBAAgB,0BAA0B,CAAC,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,yBAAyB,GAAG,OAAO,CAgBrG"}
|
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
declare module '@ember-data/model/-private/many-array' {
|
|
2
2
|
import type Store from '@ember-data/store';
|
|
3
|
-
import type { NativeProxy } from '@ember-data/store/-private';
|
|
4
|
-
import {
|
|
5
|
-
import type {
|
|
6
|
-
import type { Cache } from '@ember-data/store/-types/q/cache';
|
|
7
|
-
import type { ModelSchema } from '@ember-data/store/-types/q/ds-model';
|
|
8
|
-
import type { BaseFinderOptions } from '@ember-data/store/-types/q/store';
|
|
3
|
+
import type { CreateRecordProperties, NativeProxy } from '@ember-data/store/-private';
|
|
4
|
+
import { LiveArray, MUTATE } from '@ember-data/store/-private';
|
|
5
|
+
import type { BaseFinderOptions, ModelSchema } from '@ember-data/store/types';
|
|
9
6
|
import type { Signal } from '@ember-data/tracking/-private';
|
|
10
7
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
11
|
-
import type {
|
|
12
|
-
import type {
|
|
8
|
+
import type { Cache } from '@warp-drive/core-types/cache';
|
|
9
|
+
import type { TypedRecordInstance, TypeFromInstance, TypeFromInstanceOrString } from '@warp-drive/core-types/record';
|
|
10
|
+
import type { Links, PaginationLinks } from '@warp-drive/core-types/spec/json-api-raw';
|
|
13
11
|
import type { LegacySupport } from '@ember-data/model/-private/legacy-relationships-support';
|
|
14
|
-
export interface ManyArrayCreateArgs {
|
|
15
|
-
identifiers: StableRecordIdentifier[];
|
|
16
|
-
type:
|
|
12
|
+
export interface ManyArrayCreateArgs<T> {
|
|
13
|
+
identifiers: StableRecordIdentifier<TypeFromInstanceOrString<T>>[];
|
|
14
|
+
type: TypeFromInstanceOrString<T>;
|
|
17
15
|
store: Store;
|
|
18
16
|
allowMutation: boolean;
|
|
19
17
|
manager: LegacySupport;
|
|
@@ -70,7 +68,7 @@ declare module '@ember-data/model/-private/many-array' {
|
|
|
70
68
|
@class ManyArray
|
|
71
69
|
@public
|
|
72
70
|
*/
|
|
73
|
-
export
|
|
71
|
+
export class RelatedCollection<T = unknown> extends LiveArray<T> {
|
|
74
72
|
isAsync: boolean;
|
|
75
73
|
/**
|
|
76
74
|
The loading state of this array
|
|
@@ -139,7 +137,7 @@ declare module '@ember-data/model/-private/many-array' {
|
|
|
139
137
|
key: string;
|
|
140
138
|
type: ModelSchema;
|
|
141
139
|
modelName: T extends TypedRecordInstance ? TypeFromInstance<T> : string;
|
|
142
|
-
constructor(options: ManyArrayCreateArgs);
|
|
140
|
+
constructor(options: ManyArrayCreateArgs<T>);
|
|
143
141
|
[MUTATE](target: StableRecordIdentifier[], receiver: typeof NativeProxy<StableRecordIdentifier[], T[]>, prop: string, args: unknown[], _SIGNAL: Signal): unknown;
|
|
144
142
|
notify(): void;
|
|
145
143
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"many-array.d.ts","sourceRoot":"","sources":["../../src/-private/many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E,MAAM,GACd,OAAO;IA4MV,MAAM;IAMN;;;;;;;;;;;;;;;;;;;;;MAqBE;IACF,MAAM,CAAC,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,IAAI,CAAC;IAKlD;;;;;;;;;;;;;;;;;MAiBE;IAEF;;;;;;;MAOE;IACF,YAAY,CAAC,IAAI,EAAE,sBAAsB,CAAC,CAAC,CAAC,GAAG,CAAC;IAShD,OAAO;CAGR"}
|
|
@@ -3,10 +3,11 @@ declare module '@ember-data/model/-private/model-methods' {
|
|
|
3
3
|
import type Store from '@ember-data/store';
|
|
4
4
|
import type { ChangedAttributesHash } from '@warp-drive/core-types/cache';
|
|
5
5
|
import { RecordStore } from '@warp-drive/core-types/symbols';
|
|
6
|
-
import type Errors from '@ember-data/model/-private/errors';
|
|
6
|
+
import type { Errors } from '@ember-data/model/-private/errors';
|
|
7
7
|
import type RecordState from '@ember-data/model/-private/record-state';
|
|
8
8
|
import type BelongsToReference from '@ember-data/model/-private/references/belongs-to';
|
|
9
9
|
import type HasManyReference from '@ember-data/model/-private/references/has-many';
|
|
10
|
+
import type { MaybeBelongsToFields, MaybeHasManyFields } from '@ember-data/model/-private/type-utils';
|
|
10
11
|
export interface MinimalLegacyRecord {
|
|
11
12
|
errors: Errors;
|
|
12
13
|
___recordState: RecordState;
|
|
@@ -18,13 +19,13 @@ declare module '@ember-data/model/-private/model-methods' {
|
|
|
18
19
|
[RecordStore]: Store;
|
|
19
20
|
deleteRecord(): void;
|
|
20
21
|
unloadRecord(): void;
|
|
21
|
-
save<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<
|
|
22
|
-
destroyRecord<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<
|
|
22
|
+
save<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<this>;
|
|
23
|
+
destroyRecord<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<this>;
|
|
23
24
|
}
|
|
24
25
|
export function rollbackAttributes<T extends MinimalLegacyRecord>(this: T): void;
|
|
25
26
|
export function unloadRecord<T extends MinimalLegacyRecord>(this: T): void;
|
|
26
|
-
export function belongsTo<T extends MinimalLegacyRecord, K extends
|
|
27
|
-
export function hasMany<T extends MinimalLegacyRecord, K extends
|
|
27
|
+
export function belongsTo<T extends MinimalLegacyRecord, K extends MaybeBelongsToFields<T>>(this: T, prop: K): BelongsToReference<T, K>;
|
|
28
|
+
export function hasMany<T extends MinimalLegacyRecord, K extends MaybeHasManyFields<T>>(this: T, prop: K): HasManyReference<T, K>;
|
|
28
29
|
export function reload<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<T>;
|
|
29
30
|
export function changedAttributes<T extends MinimalLegacyRecord>(this: T): ChangedAttributesHash;
|
|
30
31
|
export function serialize<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): unknown;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"model-methods.d.ts","sourceRoot":"","sources":["../../src/-private/model-methods.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"model-methods.d.ts","sourceRoot":"","sources":["../../src/-private/model-methods.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AAEnE,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAI3C,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAC1E,OAAO,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAE7D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,OAAO,KAAK,WAAW,MAAM,gBAAgB,CAAC;AAC9C,OAAO,KAAK,kBAAkB,MAAM,yBAAyB,CAAC;AAC9D,OAAO,KAAK,gBAAgB,MAAM,uBAAuB,CAAC;AAC1D,OAAO,KAAK,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AA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mBAAmB,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GAAG,OAAO,CAAC,CAAC,CAAC,CAsBhH;AAED,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,GAAG,qBAAqB,CAE/F;AAED,wBAAgB,SAAS,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAG5G;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,GAAG,IAAI,CAKzE;AAED,wBAAgB,IAAI,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAW1G;AAED,wBAAgB,aAAa,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAUnH;AAED,wBAAgB,cAAc,CAAC,CAAC,SAAS,mBAAmB,EAAE,IAAI,EAAE,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAalF"}
|
|
@@ -4,15 +4,18 @@ declare module '@ember-data/model/-private/model' {
|
|
|
4
4
|
*/
|
|
5
5
|
/// <reference types="ember-source/types" />
|
|
6
6
|
import EmberObject from '@ember/object';
|
|
7
|
+
import type { Snapshot } from '@ember-data/legacy-compat/-private';
|
|
7
8
|
import type Store from '@ember-data/store';
|
|
8
9
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
9
|
-
import type { Cache } from '@warp-drive/core-types/cache';
|
|
10
|
-
import type {
|
|
10
|
+
import type { Cache, ChangedAttributesHash } from '@warp-drive/core-types/cache';
|
|
11
|
+
import type { LegacyAttributeField, LegacyRelationshipSchema } from '@warp-drive/core-types/schema/fields';
|
|
11
12
|
import { RecordStore } from '@warp-drive/core-types/symbols';
|
|
12
|
-
import Errors from '@ember-data/model/-private/errors';
|
|
13
|
+
import { Errors } from '@ember-data/model/-private/errors';
|
|
13
14
|
import type { MinimalLegacyRecord } from '@ember-data/model/-private/model-methods';
|
|
14
|
-
import { belongsTo, changedAttributes, createSnapshot, deleteRecord, destroyRecord, hasMany, reload, rollbackAttributes, save, serialize, unloadRecord } from '@ember-data/model/-private/model-methods';
|
|
15
15
|
import RecordState from '@ember-data/model/-private/record-state';
|
|
16
|
+
import type BelongsToReference from '@ember-data/model/-private/references/belongs-to';
|
|
17
|
+
import type HasManyReference from '@ember-data/model/-private/references/has-many';
|
|
18
|
+
import type { _MaybeBelongsToFields, isSubClass, MaybeAttrFields, MaybeHasManyFields, MaybeRelationshipFields } from '@ember-data/model/-private/type-utils';
|
|
16
19
|
export type ModelCreateArgs = {
|
|
17
20
|
_createProps: Record<string, unknown>;
|
|
18
21
|
_secretInit: {
|
|
@@ -51,15 +54,26 @@ declare module '@ember-data/model/-private/model' {
|
|
|
51
54
|
@public
|
|
52
55
|
@extends Ember.EmberObject
|
|
53
56
|
*/
|
|
57
|
+
interface Model {
|
|
58
|
+
serialize<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown> | undefined): unknown;
|
|
59
|
+
destroyRecord<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<this>;
|
|
60
|
+
unloadRecord<T extends MinimalLegacyRecord>(this: T): void;
|
|
61
|
+
changedAttributes<T extends MinimalLegacyRecord>(this: T): ChangedAttributesHash;
|
|
62
|
+
rollbackAttributes<T extends MinimalLegacyRecord>(this: T): void;
|
|
63
|
+
_createSnapshot<T extends MinimalLegacyRecord>(this: T): Snapshot<T>;
|
|
64
|
+
save<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<this>;
|
|
65
|
+
reload<T extends MinimalLegacyRecord>(this: T, options?: Record<string, unknown>): Promise<T>;
|
|
66
|
+
belongsTo<T extends Model, K extends keyof T & string>(this: T, prop: K & (K extends _MaybeBelongsToFields<T> ? K : never)): BelongsToReference<T, K>;
|
|
67
|
+
hasMany<T extends MinimalLegacyRecord, K extends MaybeHasManyFields<T>>(this: T, prop: K): HasManyReference<T, K>;
|
|
68
|
+
deleteRecord<T extends MinimalLegacyRecord>(this: T): void;
|
|
69
|
+
}
|
|
54
70
|
class Model extends EmberObject implements MinimalLegacyRecord {
|
|
55
71
|
store: Store;
|
|
56
72
|
___recordState: RecordState;
|
|
57
73
|
___private_notifications: object;
|
|
58
|
-
_createProps: null;
|
|
59
|
-
_secretInit: null;
|
|
60
74
|
[RecordStore]: Store;
|
|
61
75
|
init(options: ModelCreateArgs): void;
|
|
62
|
-
destroy():
|
|
76
|
+
destroy(): this;
|
|
63
77
|
/**
|
|
64
78
|
If this property is `true` the record is in the `empty`
|
|
65
79
|
state. Empty is the first state all records enter after they have
|
|
@@ -409,8 +423,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
409
423
|
@param {Object} options
|
|
410
424
|
@return {Object} an object whose values are primitive JSON values only
|
|
411
425
|
*/
|
|
412
|
-
|
|
413
|
-
notifyPropertyChange(prop: string): void;
|
|
426
|
+
notifyPropertyChange(prop: string): this;
|
|
414
427
|
/**
|
|
415
428
|
Marks the record as deleted but does not save it. You must call
|
|
416
429
|
`save` afterwards if you want to persist it. You might use this
|
|
@@ -440,7 +453,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
440
453
|
@method deleteRecord
|
|
441
454
|
@public
|
|
442
455
|
*/
|
|
443
|
-
deleteRecord: typeof deleteRecord;
|
|
444
456
|
/**
|
|
445
457
|
Same as `deleteRecord`, but saves the record immediately.
|
|
446
458
|
|
|
@@ -484,7 +496,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
484
496
|
@return {Promise} a promise that will be resolved when the adapter returns
|
|
485
497
|
successfully or rejected if the adapter returns with an error.
|
|
486
498
|
*/
|
|
487
|
-
destroyRecord: typeof destroyRecord;
|
|
488
499
|
/**
|
|
489
500
|
Unloads the record from the store. This will not send a delete request
|
|
490
501
|
to your server, it just unloads the record from memory.
|
|
@@ -492,7 +503,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
492
503
|
@method unloadRecord
|
|
493
504
|
@public
|
|
494
505
|
*/
|
|
495
|
-
unloadRecord: typeof unloadRecord;
|
|
496
506
|
/**
|
|
497
507
|
Returns an object, whose keys are changed properties, and value is
|
|
498
508
|
an [oldProp, newProp] array.
|
|
@@ -539,7 +549,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
539
549
|
@return {Object} an object, whose keys are changed properties,
|
|
540
550
|
and value is an [oldProp, newProp] array.
|
|
541
551
|
*/
|
|
542
|
-
changedAttributes: typeof changedAttributes;
|
|
543
552
|
/**
|
|
544
553
|
If the model `hasDirtyAttributes` this function will discard any unsaved
|
|
545
554
|
changes. If the model `isNew` it will be removed from the store.
|
|
@@ -558,12 +567,10 @@ declare module '@ember-data/model/-private/model' {
|
|
|
558
567
|
@method rollbackAttributes
|
|
559
568
|
@public
|
|
560
569
|
*/
|
|
561
|
-
rollbackAttributes: typeof rollbackAttributes;
|
|
562
570
|
/**
|
|
563
571
|
@method _createSnapshot
|
|
564
572
|
@private
|
|
565
573
|
*/
|
|
566
|
-
_createSnapshot: typeof createSnapshot;
|
|
567
574
|
/**
|
|
568
575
|
Save the record and persist any changes to the record to an
|
|
569
576
|
external source via the adapter.
|
|
@@ -605,7 +612,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
605
612
|
@return {Promise} a promise that will be resolved when the adapter returns
|
|
606
613
|
successfully or rejected if the adapter returns with an error.
|
|
607
614
|
*/
|
|
608
|
-
save: typeof save;
|
|
609
615
|
/**
|
|
610
616
|
Reload the record from the adapter.
|
|
611
617
|
|
|
@@ -632,7 +638,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
632
638
|
adapter returns successfully or rejected if the adapter returns
|
|
633
639
|
with an error.
|
|
634
640
|
*/
|
|
635
|
-
reload: typeof reload;
|
|
636
641
|
attr(): void;
|
|
637
642
|
/**
|
|
638
643
|
Get the reference for the specified belongsTo relationship.
|
|
@@ -684,7 +689,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
684
689
|
@since 2.5.0
|
|
685
690
|
@return {BelongsToReference} reference for this relationship
|
|
686
691
|
*/
|
|
687
|
-
belongsTo: typeof belongsTo;
|
|
688
692
|
/**
|
|
689
693
|
Get the reference for the specified hasMany relationship.
|
|
690
694
|
|
|
@@ -735,7 +739,6 @@ declare module '@ember-data/model/-private/model' {
|
|
|
735
739
|
@since 2.5.0
|
|
736
740
|
@return {HasManyReference} reference for this relationship
|
|
737
741
|
*/
|
|
738
|
-
hasMany: typeof hasMany;
|
|
739
742
|
/**
|
|
740
743
|
Given a callback, iterates over each of the relationships in the model,
|
|
741
744
|
invoking the callback with the name of each relationship and its relationship
|
|
@@ -789,10 +792,10 @@ declare module '@ember-data/model/-private/model' {
|
|
|
789
792
|
@param {Function} callback the callback to invoke
|
|
790
793
|
@param {any} binding the value to which the callback's `this` should be bound
|
|
791
794
|
*/
|
|
792
|
-
eachRelationship<T>(callback: (this: NoInfer<T> | undefined, key:
|
|
793
|
-
relationshipFor(name: string):
|
|
794
|
-
inverseFor(name: string):
|
|
795
|
-
eachAttribute<T>(callback: (this: NoInfer<T> | undefined, key:
|
|
795
|
+
eachRelationship<T>(callback: (this: NoInfer<T> | undefined, key: MaybeRelationshipFields<this>, meta: LegacyRelationshipSchema) => void, binding?: T): void;
|
|
796
|
+
relationshipFor(name: string): LegacyRelationshipSchema | undefined;
|
|
797
|
+
inverseFor(name: string): LegacyRelationshipSchema | null;
|
|
798
|
+
eachAttribute<T>(callback: (this: NoInfer<T> | undefined, key: isSubClass<this> extends true ? MaybeAttrFields<this> : string, meta: LegacyAttributeField) => void, binding?: T): void;
|
|
796
799
|
static isModel: boolean;
|
|
797
800
|
/**
|
|
798
801
|
Create should only ever be called by the store. To create an instance of a
|
|
@@ -858,8 +861,8 @@ declare module '@ember-data/model/-private/model' {
|
|
|
858
861
|
@param {store} store an instance of Store
|
|
859
862
|
@return {Model} the type of the relationship, or undefined
|
|
860
863
|
*/
|
|
861
|
-
static typeForRelationship(name: string, store: Store): import("@ember-data/store
|
|
862
|
-
static get inverseMap(): Record<string,
|
|
864
|
+
static typeForRelationship(name: string, store: Store): import("@ember-data/store/types").ModelSchema<unknown> | undefined;
|
|
865
|
+
static get inverseMap(): Record<string, LegacyRelationshipSchema | null>;
|
|
863
866
|
/**
|
|
864
867
|
Find the relationship which is the inverse of the one asked for.
|
|
865
868
|
|
|
@@ -893,8 +896,8 @@ declare module '@ember-data/model/-private/model' {
|
|
|
893
896
|
@param {Store} store
|
|
894
897
|
@return {Object} the inverse relationship, or null
|
|
895
898
|
*/
|
|
896
|
-
static inverseFor(name: string, store: Store):
|
|
897
|
-
static _findInverseFor(name: string, store: Store):
|
|
899
|
+
static inverseFor(name: string, store: Store): LegacyRelationshipSchema | null;
|
|
900
|
+
static _findInverseFor(name: string, store: Store): LegacyRelationshipSchema | null;
|
|
898
901
|
/**
|
|
899
902
|
The model's relationships as a map, keyed on the type of the
|
|
900
903
|
relationship. The value of each entry is an array containing a descriptor
|
|
@@ -935,7 +938,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
935
938
|
@type Map
|
|
936
939
|
@readOnly
|
|
937
940
|
*/
|
|
938
|
-
static get relationships(): Map<string,
|
|
941
|
+
static get relationships(): Map<string, LegacyRelationshipSchema[]>;
|
|
939
942
|
/**
|
|
940
943
|
A hash containing lists of the model's relationships, grouped
|
|
941
944
|
by the relationship kind. For example, given a model with this
|
|
@@ -1044,8 +1047,8 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1044
1047
|
@type Map
|
|
1045
1048
|
@readOnly
|
|
1046
1049
|
*/
|
|
1047
|
-
static get relationshipsByName(): Map<string,
|
|
1048
|
-
static get relationshipsObject(): Record<string,
|
|
1050
|
+
static get relationshipsByName(): Map<string, LegacyRelationshipSchema>;
|
|
1051
|
+
static get relationshipsObject(): Record<string, LegacyRelationshipSchema>;
|
|
1049
1052
|
/**
|
|
1050
1053
|
A map whose keys are the fields of the model and whose values are strings
|
|
1051
1054
|
describing the kind of the field. A model's fields are the union of all of its
|
|
@@ -1087,7 +1090,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1087
1090
|
@type Map
|
|
1088
1091
|
@readOnly
|
|
1089
1092
|
*/
|
|
1090
|
-
static get fields(): Map<
|
|
1093
|
+
static get fields(): Map<string, 'attribute' | 'belongsTo' | 'hasMany'>;
|
|
1091
1094
|
/**
|
|
1092
1095
|
Given a callback, iterates over each of the relationships in the model,
|
|
1093
1096
|
invoking the callback with the name of each relationship and its relationship
|
|
@@ -1099,7 +1102,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1099
1102
|
@param {Function} callback the callback to invoke
|
|
1100
1103
|
@param {any} binding the value to which the callback's `this` should be bound
|
|
1101
1104
|
*/
|
|
1102
|
-
static eachRelationship<T, Schema extends Model>(callback: (this: T | undefined, key:
|
|
1105
|
+
static eachRelationship<T, Schema extends Model>(callback: (this: T | undefined, key: MaybeRelationshipFields<Schema>, relationship: LegacyRelationshipSchema) => void, binding?: T): void;
|
|
1103
1106
|
/**
|
|
1104
1107
|
Given a callback, iterates over each of the types related to a model,
|
|
1105
1108
|
invoking the callback with the related type's class. Each type will be
|
|
@@ -1119,7 +1122,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1119
1122
|
* @private
|
|
1120
1123
|
* @deprecated
|
|
1121
1124
|
*/
|
|
1122
|
-
static determineRelationshipType(knownSide:
|
|
1125
|
+
static determineRelationshipType(knownSide: LegacyRelationshipSchema, store: Store): 'oneToOne' | 'oneToMany' | 'manyToOne' | 'manyToMany' | 'oneToNone' | 'manyToNone';
|
|
1123
1126
|
/**
|
|
1124
1127
|
A map whose keys are the attributes of the model (properties
|
|
1125
1128
|
described by attr) and whose values are the meta object for the
|
|
@@ -1158,7 +1161,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1158
1161
|
@type {Map}
|
|
1159
1162
|
@readOnly
|
|
1160
1163
|
*/
|
|
1161
|
-
static get attributes(): Map<
|
|
1164
|
+
static get attributes(): Map<string, LegacyAttributeField>;
|
|
1162
1165
|
/**
|
|
1163
1166
|
A map whose keys are the attributes of the model (properties
|
|
1164
1167
|
described by attr) and whose values are type of transformation
|
|
@@ -1242,7 +1245,7 @@ declare module '@ember-data/model/-private/model' {
|
|
|
1242
1245
|
@param {Object} [binding] the value to which the callback's `this` should be bound
|
|
1243
1246
|
@static
|
|
1244
1247
|
*/
|
|
1245
|
-
static eachAttribute<T, Schema extends Model>(callback: (this: T | undefined, key:
|
|
1248
|
+
static eachAttribute<T, Schema extends Model>(callback: (this: T | undefined, key: MaybeAttrFields<Schema>, attribute: LegacyAttributeField) => void, binding?: T): void;
|
|
1246
1249
|
/**
|
|
1247
1250
|
Iterates through the transformedAttributes of the model, calling
|
|
1248
1251
|
the passed function on each attribute. Note the callback will not be
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/-private/model.ts"],"names":[],"mappings":"AAAA;;GAEG;;
|
|
1
|
+
{"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/-private/model.ts"],"names":[],"mappings":"AAAA;;GAEG;;AAEH,OAAO,WAAW,MAAM,eAAe,CAAC;AAExC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAQ3C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AACrE,OAAO,KAAK,EAAE,KAAK,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,KAAK,EAAE,oBAAoB,EAAE,wBAAwB,EAAE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AyBrF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAqCG;IAEH,MAAM,KAAK,UAAU,IAAI,GAAG,CAAC,MAAM,EAAE,oBAAoB,CAAC,CAwBzD;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAqCG;IAEH,MAAM,KAAK,qBAAqB,wBAe/B;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2CG;IACH,MAAM,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,SAAS,KAAK,EAC1C,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,SAAS,EAAE,GAAG,EAAE,eAAe,CAAC,MAAM,CAAC,EAAE,SAAS,EAAE,oBAAoB,KAAK,IAAI,EACtG,OAAO,CAAC,EAAE,CAAC,GACV,IAAI;IAWP;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA4CG;IACH,MAAM,CAAC,wBAAwB,CAAC,CAAC,EAAE,MAAM,SAAS,KAAK,EACrD,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,SAAS,EAAE,GAAG,EAAE,OAAO,CAAC,MAAM,MAAM,GAAG,MAAM,EAAE,MAAM,KAAK,GAAG,MAAM,CAAC,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,EAChH,OAAO,CAAC,EAAE,CAAC,GACV,IAAI;IAWP;;;;;;OAMG;IACH,MAAM,CAAC,QAAQ;CAQhB;AA6ED,OAAO,EAAE,KAAK,EAAE,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare module '@ember-data/model/-private/notify-changes' {
|
|
2
2
|
import type Store from '@ember-data/store';
|
|
3
|
-
import type { NotificationType } from '@ember-data/store
|
|
3
|
+
import type { NotificationType } from '@ember-data/store';
|
|
4
4
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
5
5
|
import type { Model } from '@ember-data/model/-private/model';
|
|
6
6
|
export default function notifyChanges(identifier: StableRecordIdentifier, value: NotificationType, key: string | undefined, record: Model, store: Store): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notify-changes.d.ts","sourceRoot":"","sources":["../../src/-private/notify-changes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"notify-changes.d.ts","sourceRoot":"","sources":["../../src/-private/notify-changes.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAC3C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAE1D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAIrE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAErC,MAAM,CAAC,OAAO,UAAU,aAAa,CACnC,UAAU,EAAE,sBAAsB,EAClC,KAAK,EAAE,gBAAgB,EACvB,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,MAAM,EAAE,KAAK,EACb,KAAK,EAAE,KAAK,QAuBb"}
|
|
@@ -4,8 +4,7 @@ declare module '@ember-data/model/-private/promise-belongs-to' {
|
|
|
4
4
|
import type PromiseProxyMixin from '@ember/object/promise-proxy-mixin';
|
|
5
5
|
import type ObjectProxy from '@ember/object/proxy';
|
|
6
6
|
import type Store from '@ember-data/store';
|
|
7
|
-
import type { OpaqueRecordInstance } from '@
|
|
8
|
-
import type { TypeFromInstanceOrString } from '@warp-drive/core-types/record';
|
|
7
|
+
import type { OpaqueRecordInstance, TypeFromInstanceOrString } from '@warp-drive/core-types/record';
|
|
9
8
|
import type { LegacySupport } from '@ember-data/model/-private/legacy-relationships-support';
|
|
10
9
|
export interface BelongsToProxyMeta<T = unknown> {
|
|
11
10
|
key: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"promise-belongs-to.d.ts","sourceRoot":"","sources":["../../src/-private/promise-belongs-to.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,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CAAC;IAC7C,eAAe,EAAE,kBAAkB,CAAC,CAAC,CAAC,CAAC;IAE/C,IACI,EAAE,IAAI,MAAM,GAAG,IAAI,CAKtB;IAKD,IACI,IAAI,SAWP;IAEK,MAAM,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAO7D,CAAC,kBAAkB,CAAC,OAAiB;CACtC;AAED,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare module '@ember-data/model/-private/promise-many-array' {
|
|
2
|
-
import type { BaseFinderOptions } from '@ember-data/store
|
|
3
|
-
import type ManyArray from '@ember-data/model/-private/many-array';
|
|
2
|
+
import type { BaseFinderOptions } from '@ember-data/store/types';
|
|
3
|
+
import type { RelatedCollection as ManyArray } from '@ember-data/model/-private/many-array';
|
|
4
4
|
import { LegacyPromiseProxy } from '@ember-data/model/-private/promise-belongs-to';
|
|
5
5
|
export interface HasManyProxyCreateArgs<T = unknown> {
|
|
6
6
|
promise: Promise<ManyArray<T>>;
|
|
@@ -25,7 +25,7 @@ declare module '@ember-data/model/-private/promise-many-array' {
|
|
|
25
25
|
@class PromiseManyArray
|
|
26
26
|
@public
|
|
27
27
|
*/
|
|
28
|
-
export
|
|
28
|
+
export class PromiseManyArray<T = unknown> {
|
|
29
29
|
promise: Promise<ManyArray<T>> | null;
|
|
30
30
|
isDestroyed: boolean;
|
|
31
31
|
content: ManyArray<T> | null;
|
|
@@ -116,7 +116,7 @@ declare module '@ember-data/model/-private/promise-many-array' {
|
|
|
116
116
|
* @property links
|
|
117
117
|
* @public
|
|
118
118
|
*/
|
|
119
|
-
get links(): import("@warp-drive/core-types/spec/raw").Links | null | undefined;
|
|
119
|
+
get links(): import("@warp-drive/core-types/spec/json-api-raw").Links | null | undefined;
|
|
120
120
|
/**
|
|
121
121
|
* Retrieve the meta for this relationship
|
|
122
122
|
* @property meta
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"promise-many-array.d.ts","sourceRoot":"","sources":["../../src/-private/promise-many-array.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"promise-many-array.d.ts","sourceRoot":"","sources":["../../src/-private/promise-many-array.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAMjE,OAAO,KAAK,EAAE,iBAAiB,IAAI,SAAS,EAAE,MAAM,cAAc,CAAC;AACnE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,MAAM,WAAW,sBAAsB,CAAC,CAAC,GAAG,OAAO;IACjD,OAAO,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;IAC/B,OAAO,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC;CACxB;AAED;;GAEG;AACH;;;;;;;;;;;;;;;EAeE;AACF,qBAAa,gBAAgB,CAAC,CAAC,GAAG,OAAO;IAC/B,OAAO,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;IACtC,WAAW,EAAE,OAAO,CAAC;IACrB,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;gBAEzB,OAAO,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC;IAKlE;;;;OAIG;IACH,IACI,MAAM,IAAI,MAAM,CAOnB;IAED;;;;;;;;;OASG;IACH,OAAO,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,IAAI;IAMxD;;;;;;OAMG;IACH,MAAM,CAAC,OAAO,EAAE,IAAI,CAAC,iBAAiB,EAAE,EAAE,CAAC;IAQ3C;;;;;OAKG;IACK,SAAS,EAAE,OAAO,CAAC;IAC3B;;;;;OAKG;IACK,UAAU,EAAE,OAAO,CAAC;IAC5B;;;;;OAKG;IACK,WAAW,EAAE,OAAO,CAAC;IAC7B;;;;;OAKG;IACK,SAAS,EAAE,OAAO,CAAC;IAE3B;;;;;;;;OAQG;IACH,IAAI,CAAC,CAAC,EAAE,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;IAItG;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,EAAE,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;IAIvD;;;;;;;OAOG;IACH,OAAO,CAAC,EAAE,EAAE,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;IAM3D,OAAO;IAQP;;;;OAIG;IACH,IACI,KAAK,gFAER;IAED;;;;OAIG;IACH,IACI,IAAI,+CAEP;IAID,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC;IAQ9D,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,EAAE,OAAO,EAAE,OAAO,EAAE,EAAE,sBAAsB,CAAC,CAAC,CAAC,GAAG,gBAAgB,CAAC,CAAC,CAAC;IAItF,CAAC,kBAAkB,CAAC,OAAiB;CACtC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
declare module '@ember-data/model/-private/record-state' {
|
|
2
2
|
import type Store from '@ember-data/store';
|
|
3
|
-
import type RequestStateService from '@ember-data/store/-private
|
|
4
|
-
import type { RequestState } from '@ember-data/store/-private/network/request-cache';
|
|
5
|
-
import type { Cache } from '@ember-data/store/-types/q/cache';
|
|
3
|
+
import type { RequestState, RequestStateService } from '@ember-data/store/-private';
|
|
6
4
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
7
|
-
import type
|
|
5
|
+
import type { Cache } from '@warp-drive/core-types/cache';
|
|
6
|
+
import type { Errors } from '@ember-data/model/-private/errors';
|
|
8
7
|
import type { MinimalLegacyRecord } from '@ember-data/model/-private/model-methods';
|
|
9
8
|
/**
|
|
10
9
|
* A decorator that caches a getter while
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"record-state.d.ts","sourceRoot":"","sources":["../../src/-private/record-state.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"record-state.d.ts","sourceRoot":"","sources":["../../src/-private/record-state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAG3C,OAAO,KAAK,EAAE,YAAY,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAKpF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AACrE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAE1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAgB3D;;;;;;;GAOG;AACH,wBAAgB,MAAM,CAAC,CAAC,SAAS,MAAM,EAAE,CAAC,SAAS,MAAM,CAAC,GAAG,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE,kBAAkB,sBAwBhH;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,MAAM,EAAE,CAAC,SAAS,MAAM,CAAC,GAAG,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,QAMxF;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsCE;AACF,MAAM,CAAC,OAAO,OAAO,WAAW;IACtB,KAAK,EAAE,KAAK,CAAC;IACb,UAAU,EAAE,sBAAsB,CAAC;IACnC,MAAM,EAAE,mBAAmB,CAAC;IAC5B,EAAE,EAAE,mBAAmB,CAAC;IAExB,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC;IACb,cAAc,EAAE,YAAY,EAAE,CAAC;IAC/B,UAAU,EAAE,YAAY,GAAG,IAAI,CAAC;IAChC,OAAO,EAAE,MAAM,CAAC;gBAEZ,MAAM,EAAE,mBAAmB;IAoGvC,OAAO;IAIP,MAAM,CAAC,GAAG,EAAE,MAAM,IAAI,GAAG,MAAM;IAI/B,mBAAmB,CAAC,MAAM,EAAE,MAAM;IA+BlC,kBAAkB;IAQV,QAAQ,EAAE,OAAO,CAAC;IAE1B,IACI,SAAS,YAEZ;IAED,IACI,QAAQ,YAKX;IAED,IACI,OAAO,YAUV;IAED,IACI,OAAO,YAMV;IAED,IACI,KAAK,YAIR;IAED,IACI,SAAS,YAIZ;IAED,IACI,OAAO,YAEV;IAED,IACI,OAAO,YAMV;IAED,IACI,OAAO,YAOV;IAED,IACI,YAAY,YAMf;IAED,IACI,WAAW,YAEd;IAED,IACI,SAAS,yWA2CZ;IAED,IACI,SAAS,2CAqBZ;CACF"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
declare module '@ember-data/model/-private/references/belongs-to' {
|
|
2
|
-
import type { ResourceEdge } from '@ember-data/graph/-private
|
|
3
|
-
import type { Graph } from '@ember-data/graph/-private/graph';
|
|
2
|
+
import type { Graph, ResourceEdge } from '@ember-data/graph/-private';
|
|
4
3
|
import type Store from '@ember-data/store';
|
|
5
4
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
6
5
|
import type { TypeFromInstance, TypeFromInstanceOrString } from '@warp-drive/core-types/record';
|
|
7
|
-
import type { Links, Meta, SingleResourceDocument, SingleResourceRelationship } from '@warp-drive/core-types/spec/raw';
|
|
6
|
+
import type { Links, Meta, SingleResourceDocument, SingleResourceRelationship } from '@warp-drive/core-types/spec/json-api-raw';
|
|
8
7
|
import type { IsUnknown } from '@ember-data/model/-private/belongs-to';
|
|
8
|
+
import type { MaybeBelongsToFields } from '@ember-data/model/-private/type-utils';
|
|
9
9
|
/**
|
|
10
10
|
A `BelongsToReference` is a low-level API that allows access
|
|
11
11
|
and manipulation of a belongsTo relationship.
|
|
@@ -34,7 +34,7 @@ declare module '@ember-data/model/-private/references/belongs-to' {
|
|
|
34
34
|
@class BelongsToReference
|
|
35
35
|
@public
|
|
36
36
|
*/
|
|
37
|
-
export default class BelongsToReference<T = unknown, K extends string = IsUnknown<T> extends true ? string :
|
|
37
|
+
export default class BelongsToReference<T = unknown, K extends string = IsUnknown<T> extends true ? string : MaybeBelongsToFields<T>, Related = K extends keyof T ? Exclude<Awaited<T[K]>, null> : unknown> {
|
|
38
38
|
graph: Graph;
|
|
39
39
|
store: Store;
|
|
40
40
|
belongsToRelationship: ResourceEdge;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"belongs-to.d.ts","sourceRoot":"","sources":["../../../src/-private/references/belongs-to.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"belongs-to.d.ts","sourceRoot":"","sources":["../../../src/-private/references/belongs-to.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AACtE,OAAO,KAAK,KAAK,MAAM,mBAAmB,CAAC;AAK3C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAErE,OAAO,KAAK,EAAE,gBAAgB,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAChG,OAAO,K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-data/graph/-private
|
|
3
|
-
import type { Graph } from '@ember-data/graph/-private/graph';
|
|
2
|
+
import type { CollectionEdge, Graph } from '@ember-data/graph/-private';
|
|
4
3
|
import type Store from '@ember-data/store';
|
|
5
|
-
import type { BaseFinderOptions } from '@ember-data/store
|
|
4
|
+
import type { BaseFinderOptions } from '@ember-data/store/types';
|
|
6
5
|
import type { StableRecordIdentifier } from '@warp-drive/core-types';
|
|
7
6
|
import type { TypeFromInstanceOrString } from '@warp-drive/core-types/record';
|
|
8
|
-
import type { CollectionResourceDocument, CollectionResourceRelationship, ExistingResourceObject, LinkObject, Meta, PaginationLinks } from '@warp-drive/core-types/spec/raw';
|
|
7
|
+
import type { CollectionResourceDocument, CollectionResourceRelationship, ExistingResourceObject, LinkObject, Meta, PaginationLinks } from '@warp-drive/core-types/spec/json-api-raw';
|
|
9
8
|
import type { IsUnknown } from '@ember-data/model/-private/belongs-to';
|
|
10
|
-
import type ManyArray from '@ember-data/model/-private/many-array';
|
|
9
|
+
import type { RelatedCollection as ManyArray } from '@ember-data/model/-private/many-array';
|
|
10
|
+
import type { MaybeHasManyFields } from '@ember-data/model/-private/type-utils';
|
|
11
11
|
/**
|
|
12
12
|
@module @ember-data/model
|
|
13
13
|
*/
|
|
@@ -46,7 +46,7 @@ declare module '@ember-data/model/-private/references/has-many' {
|
|
|
46
46
|
@class HasManyReference
|
|
47
47
|
@public
|
|
48
48
|
*/
|
|
49
|
-
export default class HasManyReference<T = unknown, K extends string = IsUnknown<T> extends true ? string :
|
|
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
50
|
graph: Graph;
|
|
51
51
|
store: Store;
|
|
52
52
|
hasManyRelationship: CollectionEdge;
|
|
@@ -82,7 +82,7 @@ declare module '@ember-data/model/-private/references/has-many' {
|
|
|
82
82
|
* @public
|
|
83
83
|
*/
|
|
84
84
|
get identifiers(): StableRecordIdentifier<TypeFromInstanceOrString<Related>>[];
|
|
85
|
-
_resource(): CollectionResourceRelationship<import("@warp-drive/core-types/spec/raw").ExistingResourceIdentifierObject<string> | import("@warp-drive/core-types/spec/raw").NewResourceIdentifierObject<string>>;
|
|
85
|
+
_resource(): CollectionResourceRelationship<import("@warp-drive/core-types/spec/json-api-raw").ExistingResourceIdentifierObject<string> | import("@warp-drive/core-types/spec/json-api-raw").NewResourceIdentifierObject<string>>;
|
|
86
86
|
/**
|
|
87
87
|
This returns a string that represents how the reference will be
|
|
88
88
|
looked up when it is loaded. If the relationship has a link it will
|