Skip to content

Commit 7d2be81

Browse files
committed
chore: InMemoryEntityInSetMixin types
1 parent 8fba18f commit 7d2be81

File tree

3 files changed

+18
-94
lines changed

3 files changed

+18
-94
lines changed

dist/js/entity/other.d.ts

Lines changed: 7 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export declare const NamedDefaultableInMemoryEntity: {
118118
readonly defaultConfig: object | null;
119119
createDefault(): any;
120120
} & typeof InMemoryEntity;
121-
export declare const HasMetadataNamedDefaultableInMemoryEntity: {
121+
declare const HasMetadataNamedDefaultableInMemoryEntity_base: {
122122
new (...args: any[]): {
123123
metadata: object;
124124
updateMetadata(object: object): void;
@@ -204,7 +204,9 @@ export declare const HasMetadataNamedDefaultableInMemoryEntity: {
204204
readonly defaultConfig: object | null;
205205
createDefault(): any;
206206
} & typeof InMemoryEntity;
207-
export declare const HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity: {
207+
export declare class HasMetadataNamedDefaultableInMemoryEntity extends HasMetadataNamedDefaultableInMemoryEntity_base {
208+
}
209+
declare const HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity_base: {
208210
new (...args: any[]): {
209211
consistencyChecks: import("@mat3ra/esse/dist/js/types").ConsistencyCheck[];
210212
addConsistencyChecks(array: import("@mat3ra/esse/dist/js/types").ConsistencyCheck[]): void;
@@ -232,92 +234,9 @@ export declare const HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEnti
232234
readonly slug: string;
233235
readonly isSystemEntity: boolean;
234236
};
235-
} & {
236-
new (...args: any[]): {
237-
metadata: object;
238-
updateMetadata(object: object): void;
239-
_json: import("@mat3ra/esse/dist/js/esse/types").AnyObject;
240-
prop<T = undefined>(name: string, defaultValue: T): T;
241-
prop<T_1 = undefined>(name: string): T_1 | undefined;
242-
setProp(name: string, value: unknown): void;
243-
unsetProp(name: string): void;
244-
setProps(json?: import("@mat3ra/esse/dist/js/esse/types").AnyObject): any;
245-
toJSON(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
246-
toJSONSafe(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
247-
toJSONQuick(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
248-
clone(extraContext?: object | undefined): any;
249-
validate(): void;
250-
clean(config: import("@mat3ra/esse/dist/js/esse/types").AnyObject): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
251-
isValid(): boolean;
252-
readonly cls: string;
253-
getClsName(): string;
254-
getAsEntityReference(byIdOnly?: boolean): import("@mat3ra/esse/dist/js/types").EntityReferenceSchema;
255-
getEntityByName(entities: InMemoryEntity[], entity: string, name: string): InMemoryEntity;
256-
id: string;
257-
_id: string;
258-
schemaVersion: string;
259-
systemName: string;
260-
readonly slug: string;
261-
readonly isSystemEntity: boolean;
262-
};
263-
} & {
264-
new (...args: any[]): {
265-
name: string;
266-
setName(name: string): void;
267-
_json: import("@mat3ra/esse/dist/js/esse/types").AnyObject;
268-
prop<T = undefined>(name: string, defaultValue: T): T;
269-
prop<T_1 = undefined>(name: string): T_1 | undefined;
270-
setProp(name: string, value: unknown): void;
271-
unsetProp(name: string): void;
272-
setProps(json?: import("@mat3ra/esse/dist/js/esse/types").AnyObject): any;
273-
toJSON(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
274-
toJSONSafe(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
275-
toJSONQuick(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
276-
clone(extraContext?: object | undefined): any;
277-
validate(): void;
278-
clean(config: import("@mat3ra/esse/dist/js/esse/types").AnyObject): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
279-
isValid(): boolean;
280-
readonly cls: string;
281-
getClsName(): string;
282-
getAsEntityReference(byIdOnly?: boolean): import("@mat3ra/esse/dist/js/types").EntityReferenceSchema;
283-
getEntityByName(entities: InMemoryEntity[], entity: string, name: string): InMemoryEntity;
284-
id: string;
285-
_id: string;
286-
schemaVersion: string;
287-
systemName: string;
288-
readonly slug: string;
289-
readonly isSystemEntity: boolean;
290-
};
291-
} & {
292-
new (...args: any[]): {
293-
readonly isDefault: boolean;
294-
_json: import("@mat3ra/esse/dist/js/esse/types").AnyObject;
295-
prop<T = undefined>(name: string, defaultValue: T): T;
296-
prop<T_1 = undefined>(name: string): T_1 | undefined;
297-
setProp(name: string, value: unknown): void;
298-
unsetProp(name: string): void;
299-
setProps(json?: import("@mat3ra/esse/dist/js/esse/types").AnyObject): any;
300-
toJSON(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
301-
toJSONSafe(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
302-
toJSONQuick(exclude?: string[]): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
303-
clone(extraContext?: object | undefined): any;
304-
validate(): void;
305-
clean(config: import("@mat3ra/esse/dist/js/esse/types").AnyObject): import("@mat3ra/esse/dist/js/esse/types").AnyObject;
306-
isValid(): boolean;
307-
readonly cls: string;
308-
getClsName(): string;
309-
getAsEntityReference(byIdOnly?: boolean): import("@mat3ra/esse/dist/js/types").EntityReferenceSchema;
310-
getEntityByName(entities: InMemoryEntity[], entity: string, name: string): InMemoryEntity;
311-
id: string;
312-
_id: string;
313-
schemaVersion: string;
314-
systemName: string;
315-
readonly slug: string;
316-
readonly isSystemEntity: boolean;
317-
};
318-
readonly defaultConfig: object | null;
319-
createDefault(): any;
320-
} & typeof InMemoryEntity;
237+
} & typeof HasMetadataNamedDefaultableInMemoryEntity;
238+
export declare class HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity extends HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity_base {
239+
}
321240
export declare const NamedDefaultableRepetitionImportantSettingsInMemoryEntity: {
322241
new (...args: any[]): {
323242
readonly important: any;

dist/js/entity/other.js

Lines changed: 6 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/js/entity/other.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,13 @@ export const NamedInMemoryEntity = NamedEntityMixin(InMemoryEntity);
1616

1717
export const NamedDefaultableInMemoryEntity = NamedEntityMixin(DefaultableMixin(InMemoryEntity));
1818

19-
export const HasMetadataNamedDefaultableInMemoryEntity = HasMetadataMixin(
19+
export class HasMetadataNamedDefaultableInMemoryEntity extends HasMetadataMixin(
2020
NamedEntityMixin(DefaultableMixin(InMemoryEntity)),
21-
);
21+
) {}
2222

23-
export const HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity =
24-
HasConsistencyChecksMixin(HasMetadataNamedDefaultableInMemoryEntity);
23+
export class HasConsistencyChecksHasMetadataNamedDefaultableInMemoryEntity extends HasConsistencyChecksMixin(
24+
HasMetadataNamedDefaultableInMemoryEntity,
25+
) {}
2526

2627
export const NamedDefaultableRepetitionImportantSettingsInMemoryEntity =
2728
ImportantSettingsProviderMixin(

0 commit comments

Comments
 (0)