@medplum/core 5.1.7 → 5.1.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.
- package/dist/cjs/index.cjs +3 -3
- package/dist/cjs/index.cjs.map +3 -3
- package/dist/cjs/index.d.ts +21 -8
- package/dist/esm/index.d.ts +21 -8
- package/dist/esm/index.mjs +3 -3
- package/dist/esm/index.mjs.map +3 -3
- package/package.json +6 -5
package/dist/cjs/index.d.ts
CHANGED
|
@@ -309,7 +309,8 @@ export declare class AsAtom extends InfixOperatorAtom {
|
|
|
309
309
|
eval(context: AtomContext, input: TypedValue[]): TypedValue[];
|
|
310
310
|
}
|
|
311
311
|
|
|
312
|
-
|
|
312
|
+
declare function assert_2(condition: unknown, msg?: string): asserts condition;
|
|
313
|
+
export { assert_2 as assert }
|
|
313
314
|
|
|
314
315
|
export declare function assertContextVersionOptional(event: string): asserts event is FhircastEventVersionOptional;
|
|
315
316
|
|
|
@@ -526,7 +527,7 @@ export declare interface CdsCard {
|
|
|
526
527
|
readonly uuid?: string;
|
|
527
528
|
readonly summary: string;
|
|
528
529
|
readonly detail?: string;
|
|
529
|
-
readonly indicator: 'info' | 'warning' | '
|
|
530
|
+
readonly indicator: 'info' | 'warning' | 'critical';
|
|
530
531
|
readonly source?: CdsSource;
|
|
531
532
|
readonly suggestions?: CdsSuggestion[];
|
|
532
533
|
readonly links?: CdsLink[];
|
|
@@ -2814,9 +2815,9 @@ export declare class IsAtom extends BooleanInfixOperatorAtom {
|
|
|
2814
2815
|
}
|
|
2815
2816
|
|
|
2816
2817
|
/**
|
|
2817
|
-
* Environment detection utilities that can be mocked in tests.
|
|
2818
|
+
* Environment detection utilities that can be mocked in tests (e.g. `vi.mock` in Vitest).
|
|
2818
2819
|
* These functions replace direct checks of global objects to avoid
|
|
2819
|
-
*
|
|
2820
|
+
* manipulating non-configurable `globalThis.window` under JSDOM 23+.
|
|
2820
2821
|
*/
|
|
2821
2822
|
/**
|
|
2822
2823
|
* Returns true if running in a browser environment with window available.
|
|
@@ -3232,8 +3233,8 @@ export declare class LiteralAtom implements Atom {
|
|
|
3232
3233
|
export declare function loadDataType(sd: StructureDefinition): void;
|
|
3233
3234
|
|
|
3234
3235
|
/**
|
|
3235
|
-
* Location
|
|
3236
|
-
*
|
|
3236
|
+
* Location helpers that can be mocked alongside the rest of this module.
|
|
3237
|
+
* Centralizes `location` access to work around JSDOM 23+ behavior in test environments.
|
|
3237
3238
|
*/
|
|
3238
3239
|
export declare const locationUtils: {
|
|
3239
3240
|
assign(url: string): void;
|
|
@@ -4702,6 +4703,14 @@ export declare class MedplumClient extends TypedEventTarget<MedplumClientEventMa
|
|
|
4702
4703
|
* @returns Promise to the response body as a blob.
|
|
4703
4704
|
*/
|
|
4704
4705
|
download(url: URL | string, options?: MedplumRequestOptions): Promise<Blob>;
|
|
4706
|
+
/**
|
|
4707
|
+
* Downloads the URL as a Response. Can accept binary URLs in the form of `Binary/{id}` as well.
|
|
4708
|
+
* @category Read
|
|
4709
|
+
* @param url - The URL to request. Can be a standard URL or one in the form of `Binary/{id}`.
|
|
4710
|
+
* @param options - Optional fetch request init options.
|
|
4711
|
+
* @returns Promise to the response body as a Response.
|
|
4712
|
+
*/
|
|
4713
|
+
downloadResponse(url: URL | string, options?: MedplumRequestOptions): Promise<Response>;
|
|
4705
4714
|
/**
|
|
4706
4715
|
* Creates a FHIR Media resource with the provided data content.
|
|
4707
4716
|
*
|
|
@@ -5667,6 +5676,10 @@ export declare interface MedplumRequestOptions extends RequestInit {
|
|
|
5667
5676
|
* Only applies when the client is configured with auto-batching enabled.
|
|
5668
5677
|
*/
|
|
5669
5678
|
disableAutoBatch?: boolean;
|
|
5679
|
+
/**
|
|
5680
|
+
* See: https://developer.mozilla.org/en-US/docs/Web/API/Request/duplex
|
|
5681
|
+
*/
|
|
5682
|
+
duplex?: 'half';
|
|
5670
5683
|
}
|
|
5671
5684
|
|
|
5672
5685
|
export declare interface MedplumSourceInfraConfig {
|
|
@@ -6207,7 +6220,7 @@ export declare function parseLogLevel(level: string): LogLevel;
|
|
|
6207
6220
|
*/
|
|
6208
6221
|
export declare function parseMappingLanguage(input: string): StructureMap;
|
|
6209
6222
|
|
|
6210
|
-
export declare function parseParameter(searchParam: SearchParameter, modifier: string, value: string): Filter;
|
|
6223
|
+
export declare function parseParameter(searchParam: SearchParameter, operator: Operator, modifier: string, value: string): Filter;
|
|
6211
6224
|
|
|
6212
6225
|
export declare class Parser {
|
|
6213
6226
|
private tokens;
|
|
@@ -7467,7 +7480,7 @@ export declare class ParserBuilder {
|
|
|
7467
7480
|
|
|
7468
7481
|
export declare function validateTypedValue(typedValue: TypedValue, options?: ValidatorOptions): OperationOutcomeIssue[];
|
|
7469
7482
|
|
|
7470
|
-
export declare function validationError(details: string): OperationOutcome;
|
|
7483
|
+
export declare function validationError(details: string, expressions?: string[], code?: IssueType, diagnostics?: string): OperationOutcome;
|
|
7471
7484
|
|
|
7472
7485
|
export declare const validationRegexes: Record<string, RegExp>;
|
|
7473
7486
|
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -309,7 +309,8 @@ export declare class AsAtom extends InfixOperatorAtom {
|
|
|
309
309
|
eval(context: AtomContext, input: TypedValue[]): TypedValue[];
|
|
310
310
|
}
|
|
311
311
|
|
|
312
|
-
|
|
312
|
+
declare function assert_2(condition: unknown, msg?: string): asserts condition;
|
|
313
|
+
export { assert_2 as assert }
|
|
313
314
|
|
|
314
315
|
export declare function assertContextVersionOptional(event: string): asserts event is FhircastEventVersionOptional;
|
|
315
316
|
|
|
@@ -526,7 +527,7 @@ export declare interface CdsCard {
|
|
|
526
527
|
readonly uuid?: string;
|
|
527
528
|
readonly summary: string;
|
|
528
529
|
readonly detail?: string;
|
|
529
|
-
readonly indicator: 'info' | 'warning' | '
|
|
530
|
+
readonly indicator: 'info' | 'warning' | 'critical';
|
|
530
531
|
readonly source?: CdsSource;
|
|
531
532
|
readonly suggestions?: CdsSuggestion[];
|
|
532
533
|
readonly links?: CdsLink[];
|
|
@@ -2814,9 +2815,9 @@ export declare class IsAtom extends BooleanInfixOperatorAtom {
|
|
|
2814
2815
|
}
|
|
2815
2816
|
|
|
2816
2817
|
/**
|
|
2817
|
-
* Environment detection utilities that can be mocked in tests.
|
|
2818
|
+
* Environment detection utilities that can be mocked in tests (e.g. `vi.mock` in Vitest).
|
|
2818
2819
|
* These functions replace direct checks of global objects to avoid
|
|
2819
|
-
*
|
|
2820
|
+
* manipulating non-configurable `globalThis.window` under JSDOM 23+.
|
|
2820
2821
|
*/
|
|
2821
2822
|
/**
|
|
2822
2823
|
* Returns true if running in a browser environment with window available.
|
|
@@ -3232,8 +3233,8 @@ export declare class LiteralAtom implements Atom {
|
|
|
3232
3233
|
export declare function loadDataType(sd: StructureDefinition): void;
|
|
3233
3234
|
|
|
3234
3235
|
/**
|
|
3235
|
-
* Location
|
|
3236
|
-
*
|
|
3236
|
+
* Location helpers that can be mocked alongside the rest of this module.
|
|
3237
|
+
* Centralizes `location` access to work around JSDOM 23+ behavior in test environments.
|
|
3237
3238
|
*/
|
|
3238
3239
|
export declare const locationUtils: {
|
|
3239
3240
|
assign(url: string): void;
|
|
@@ -4702,6 +4703,14 @@ export declare class MedplumClient extends TypedEventTarget<MedplumClientEventMa
|
|
|
4702
4703
|
* @returns Promise to the response body as a blob.
|
|
4703
4704
|
*/
|
|
4704
4705
|
download(url: URL | string, options?: MedplumRequestOptions): Promise<Blob>;
|
|
4706
|
+
/**
|
|
4707
|
+
* Downloads the URL as a Response. Can accept binary URLs in the form of `Binary/{id}` as well.
|
|
4708
|
+
* @category Read
|
|
4709
|
+
* @param url - The URL to request. Can be a standard URL or one in the form of `Binary/{id}`.
|
|
4710
|
+
* @param options - Optional fetch request init options.
|
|
4711
|
+
* @returns Promise to the response body as a Response.
|
|
4712
|
+
*/
|
|
4713
|
+
downloadResponse(url: URL | string, options?: MedplumRequestOptions): Promise<Response>;
|
|
4705
4714
|
/**
|
|
4706
4715
|
* Creates a FHIR Media resource with the provided data content.
|
|
4707
4716
|
*
|
|
@@ -5667,6 +5676,10 @@ export declare interface MedplumRequestOptions extends RequestInit {
|
|
|
5667
5676
|
* Only applies when the client is configured with auto-batching enabled.
|
|
5668
5677
|
*/
|
|
5669
5678
|
disableAutoBatch?: boolean;
|
|
5679
|
+
/**
|
|
5680
|
+
* See: https://developer.mozilla.org/en-US/docs/Web/API/Request/duplex
|
|
5681
|
+
*/
|
|
5682
|
+
duplex?: 'half';
|
|
5670
5683
|
}
|
|
5671
5684
|
|
|
5672
5685
|
export declare interface MedplumSourceInfraConfig {
|
|
@@ -6207,7 +6220,7 @@ export declare function parseLogLevel(level: string): LogLevel;
|
|
|
6207
6220
|
*/
|
|
6208
6221
|
export declare function parseMappingLanguage(input: string): StructureMap;
|
|
6209
6222
|
|
|
6210
|
-
export declare function parseParameter(searchParam: SearchParameter, modifier: string, value: string): Filter;
|
|
6223
|
+
export declare function parseParameter(searchParam: SearchParameter, operator: Operator, modifier: string, value: string): Filter;
|
|
6211
6224
|
|
|
6212
6225
|
export declare class Parser {
|
|
6213
6226
|
private tokens;
|
|
@@ -7467,7 +7480,7 @@ export declare class ParserBuilder {
|
|
|
7467
7480
|
|
|
7468
7481
|
export declare function validateTypedValue(typedValue: TypedValue, options?: ValidatorOptions): OperationOutcomeIssue[];
|
|
7469
7482
|
|
|
7470
|
-
export declare function validationError(details: string): OperationOutcome;
|
|
7483
|
+
export declare function validationError(details: string, expressions?: string[], code?: IssueType, diagnostics?: string): OperationOutcome;
|
|
7471
7484
|
|
|
7472
7485
|
export declare const validationRegexes: Record<string, RegExp>;
|
|
7473
7486
|
|