@medplum/core 0.9.0 → 0.9.3

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 (53) hide show
  1. package/README.md +158 -29
  2. package/dist/cjs/index.js +370 -251
  3. package/dist/cjs/index.js.map +1 -1
  4. package/dist/cjs/index.min.js +1 -15
  5. package/dist/cjs/index.min.js.map +1 -1
  6. package/dist/esm/index.js +357 -251
  7. package/dist/esm/index.js.map +1 -1
  8. package/dist/esm/index.min.js +1 -15
  9. package/dist/esm/index.min.js.map +1 -1
  10. package/dist/types/cache.d.ts +1 -0
  11. package/dist/types/client.d.ts +33 -8
  12. package/dist/types/hl7.d.ts +43 -0
  13. package/dist/types/index.d.ts +3 -1
  14. package/dist/types/readablepromise.d.ts +43 -0
  15. package/dist/types/search.d.ts +2 -1
  16. package/dist/types/utils.d.ts +33 -3
  17. package/package.json +2 -2
  18. package/dist/types/repo.d.ts +0 -116
  19. package/docs/.nojekyll +0 -1
  20. package/docs/assets/highlight.css +0 -92
  21. package/docs/assets/icons.css +0 -1043
  22. package/docs/assets/icons.png +0 -0
  23. package/docs/assets/icons@2x.png +0 -0
  24. package/docs/assets/main.js +0 -52
  25. package/docs/assets/search.js +0 -1
  26. package/docs/assets/style.css +0 -1414
  27. package/docs/assets/widgets.png +0 -0
  28. package/docs/assets/widgets@2x.png +0 -0
  29. package/docs/classes/LegacyRepositoryClient.html +0 -71
  30. package/docs/classes/MedplumClient.html +0 -324
  31. package/docs/classes/OperationOutcomeError.html +0 -6
  32. package/docs/enums/Operator.html +0 -5
  33. package/docs/enums/PropertyType.html +0 -5
  34. package/docs/enums/SearchParameterType.html +0 -1
  35. package/docs/index.html +0 -89
  36. package/docs/interfaces/AddressFormatOptions.html +0 -1
  37. package/docs/interfaces/FetchLike.html +0 -1
  38. package/docs/interfaces/Filter.html +0 -1
  39. package/docs/interfaces/GoogleCredentialResponse.html +0 -1
  40. package/docs/interfaces/HumanNameFormatOptions.html +0 -1
  41. package/docs/interfaces/IndexedStructureDefinition.html +0 -19
  42. package/docs/interfaces/LoginAuthenticationResponse.html +0 -1
  43. package/docs/interfaces/LoginProfileResponse.html +0 -1
  44. package/docs/interfaces/LoginScopeResponse.html +0 -1
  45. package/docs/interfaces/LoginState.html +0 -1
  46. package/docs/interfaces/MedplumClientOptions.html +0 -33
  47. package/docs/interfaces/RegisterRequest.html +0 -1
  48. package/docs/interfaces/SearchParameterDetails.html +0 -1
  49. package/docs/interfaces/SearchRequest.html +0 -1
  50. package/docs/interfaces/SortRule.html +0 -1
  51. package/docs/interfaces/TokenResponse.html +0 -1
  52. package/docs/interfaces/TypeSchema.html +0 -10
  53. package/docs/modules.html +0 -138
@@ -8,4 +8,5 @@ export declare class LRUCache<T> {
8
8
  clear(): void;
9
9
  get(key: string): T | undefined;
10
10
  set(key: string, val: T): void;
11
+ delete(key: string): void;
11
12
  }
@@ -1,6 +1,7 @@
1
1
  import { Binary, Bundle, Project, ProjectMembership, Reference, Resource, UserConfiguration, ValueSet } from '@medplum/fhirtypes';
2
- import { Operation } from 'fast-json-patch';
2
+ import type { Operation } from 'fast-json-patch';
3
3
  import { EventTarget } from './eventtarget';
4
+ import { ReadablePromise } from './readablepromise';
4
5
  import { SearchRequest } from './search';
5
6
  import { IndexedStructureDefinition } from './types';
6
7
  import { ProfileResource } from './utils';
@@ -164,7 +165,7 @@ export declare class MedplumClient extends EventTarget {
164
165
  * @param options Optional fetch options.
165
166
  * @returns Promise to the response content.
166
167
  */
167
- get(url: string, options?: RequestInit): Promise<any>;
168
+ get<T = any>(url: string, options?: RequestInit): ReadablePromise<T>;
168
169
  /**
169
170
  * Makes an HTTP POST request to the specified URL.
170
171
  *
@@ -396,7 +397,7 @@ export declare class MedplumClient extends EventTarget {
396
397
  * @param id The resource ID.
397
398
  * @returns The resource if available; undefined otherwise.
398
399
  */
399
- readResource<T extends Resource>(resourceType: string, id: string): Promise<T>;
400
+ readResource<T extends Resource>(resourceType: string, id: string): ReadablePromise<T>;
400
401
  /**
401
402
  * Reads a resource by resource type and ID using the in-memory resource cache.
402
403
  *
@@ -415,7 +416,7 @@ export declare class MedplumClient extends EventTarget {
415
416
  * @param id The resource ID.
416
417
  * @returns The resource if available; undefined otherwise.
417
418
  */
418
- readCached<T extends Resource>(resourceType: string, id: string): Promise<T>;
419
+ readCached<T extends Resource>(resourceType: string, id: string): ReadablePromise<T>;
419
420
  /**
420
421
  * Reads a resource by `Reference`.
421
422
  *
@@ -434,7 +435,7 @@ export declare class MedplumClient extends EventTarget {
434
435
  * @param reference The FHIR reference object.
435
436
  * @returns The resource if available; undefined otherwise.
436
437
  */
437
- readReference<T extends Resource>(reference: Reference<T>): Promise<T>;
438
+ readReference<T extends Resource>(reference: Reference<T>): ReadablePromise<T>;
438
439
  /**
439
440
  * Reads a resource by `Reference` using the in-memory resource cache.
440
441
  *
@@ -455,7 +456,7 @@ export declare class MedplumClient extends EventTarget {
455
456
  * @param reference The FHIR reference object.
456
457
  * @returns The resource if available; undefined otherwise.
457
458
  */
458
- readCachedReference<T extends Resource>(reference: Reference<T>): Promise<T>;
459
+ readCachedReference<T extends Resource>(reference: Reference<T>): ReadablePromise<T>;
459
460
  /**
460
461
  * Returns a cached schema for a resource type.
461
462
  * If the schema is not cached, returns undefined.
@@ -550,10 +551,34 @@ export declare class MedplumClient extends EventTarget {
550
551
  *
551
552
  * See the FHIR "create" operation for full details: https://www.hl7.org/fhir/http.html#create
552
553
  *
553
- * @param resource The FHIR resource to create.
554
+ * @param data The binary data to upload.
555
+ * @param filename Optional filename for the binary.
556
+ * @param contentType Content type for the binary.
557
+ * @returns The result of the create operation.
558
+ */
559
+ createBinary(data: string | File, filename: string | undefined, contentType: string): Promise<Binary>;
560
+ /**
561
+ * Creates a PDF as a FHIR `Binary` resource based on pdfmake document definition.
562
+ *
563
+ * The return value is the newly created resource, including the ID and meta.
564
+ *
565
+ * The `docDefinition` parameter is a pdfmake document definition.
566
+ *
567
+ * Example:
568
+ *
569
+ * ```typescript
570
+ * const result = await medplum.createPdf({
571
+ * content: ['Hello world']
572
+ * });
573
+ * console.log(result.id);
574
+ * ```
575
+ *
576
+ * See the pdfmake document definition for full details: https://pdfmake.github.io/docs/0.1/document-definition-object/
577
+ *
578
+ * @param docDefinition The FHIR resource to create.
554
579
  * @returns The result of the create operation.
555
580
  */
556
- createBinary(data: any, filename: string, contentType: string): Promise<Binary>;
581
+ createPdf(docDefinition: Record<string, unknown>, filename?: string): Promise<Binary>;
557
582
  /**
558
583
  * Updates a FHIR resource.
559
584
  *
@@ -0,0 +1,43 @@
1
+ export declare const SEGMENT_SEPARATOR = "\r";
2
+ export declare const FIELD_SEPARATOR = "|";
3
+ export declare const COMPONENT_SEPARATOR = "^";
4
+ /**
5
+ * The Hl7Message class represents one HL7 message.
6
+ * A message is a collection of segments.
7
+ * Note that we do not strictly parse messages, and only use default delimeters.
8
+ */
9
+ export declare class Hl7Message {
10
+ readonly segments: Hl7Segment[];
11
+ constructor(segments: Hl7Segment[]);
12
+ get(index: number | string): Hl7Segment | undefined;
13
+ getAll(name: string): Hl7Segment[];
14
+ toString(): string;
15
+ buildAck(): Hl7Message;
16
+ static parse(text: string): Hl7Message;
17
+ }
18
+ /**
19
+ * The Hl7Segment class represents one HL7 segment.
20
+ * A segment is a collection of fields.
21
+ * The name field is the first field.
22
+ * Note that we do not strictly parse messages, and only use default delimeters.
23
+ */
24
+ export declare class Hl7Segment {
25
+ readonly name: string;
26
+ readonly fields: Hl7Field[];
27
+ constructor(fields: Hl7Field[] | string[]);
28
+ get(index: number): Hl7Field;
29
+ toString(): string;
30
+ static parse(text: string): Hl7Segment;
31
+ }
32
+ /**
33
+ * The Hl7Field class represents one HL7 field.
34
+ * A field is a collection of components.
35
+ * Note that we do not strictly parse messages, and only use default delimeters.
36
+ */
37
+ export declare class Hl7Field {
38
+ readonly components: string[];
39
+ constructor(components: string[]);
40
+ get(index: number): string;
41
+ toString(): string;
42
+ static parse(text: string): Hl7Field;
43
+ }
@@ -1,7 +1,9 @@
1
+ export * from './cache';
1
2
  export * from './client';
2
3
  export * from './format';
4
+ export * from './hl7';
3
5
  export * from './outcomes';
4
- export * from './repo';
6
+ export * from './readablepromise';
5
7
  export * from './search';
6
8
  export * from './searchparams';
7
9
  export * from './types';
@@ -0,0 +1,43 @@
1
+ /**
2
+ * The ReadablePromise class wraps a request promise suitable for React Suspense.
3
+ * See: https://blog.logrocket.com/react-suspense-data-fetching/#wrappromise-js
4
+ * See: https://github.com/ovieokeh/suspense-data-fetching/blob/master/lib/api/wrapPromise.js
5
+ */
6
+ export declare class ReadablePromise<T> implements Promise<T> {
7
+ #private;
8
+ readonly [Symbol.toStringTag]: string;
9
+ constructor(requestPromise: Promise<T>);
10
+ /**
11
+ * Returns true if the promise is pending.
12
+ * @returns True if the Promise is pending.
13
+ */
14
+ isPending(): boolean;
15
+ /**
16
+ * Attempts to read the value of the promise.
17
+ * If the promise is pending, this method will throw a promise.
18
+ * If the promise rejected, this method will throw the rejection reason.
19
+ * If the promise resolved, this method will return the resolved value.
20
+ * @returns The resolved value of the Promise.
21
+ */
22
+ read(): T;
23
+ /**
24
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
25
+ * @param onfulfilled The callback to execute when the Promise is resolved.
26
+ * @param onrejected The callback to execute when the Promise is rejected.
27
+ * @returns A Promise for the completion of which ever callback is executed.
28
+ */
29
+ then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): Promise<TResult1 | TResult2>;
30
+ /**
31
+ * Attaches a callback for only the rejection of the Promise.
32
+ * @param onrejected The callback to execute when the Promise is rejected.
33
+ * @returns A Promise for the completion of the callback.
34
+ */
35
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): Promise<T | TResult>;
36
+ /**
37
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
38
+ * resolved value cannot be modified from the callback.
39
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
40
+ * @returns A Promise for the completion of the callback.
41
+ */
42
+ finally(onfinally?: (() => void) | undefined | null): Promise<T>;
43
+ }
@@ -1,8 +1,9 @@
1
+ export declare const DEFAULT_SEARCH_COUNT = 20;
1
2
  export interface SearchRequest {
2
3
  readonly resourceType: string;
3
4
  filters?: Filter[];
4
5
  sortRules?: SortRule[];
5
- page?: number;
6
+ offset?: number;
6
7
  count?: number;
7
8
  fields?: string[];
8
9
  name?: string;
@@ -1,4 +1,4 @@
1
- import { Patient, Practitioner, Reference, RelatedPerson, Resource } from '@medplum/fhirtypes';
1
+ import { Patient, Practitioner, QuestionnaireResponse, QuestionnaireResponseItemAnswer, Reference, RelatedPerson, Resource } from '@medplum/fhirtypes';
2
2
  export declare type ProfileResource = Patient | Practitioner | RelatedPerson;
3
3
  /**
4
4
  * Creates a reference resource.
@@ -65,6 +65,19 @@ export declare function calculateAge(birthDateStr: string, endDateStr?: string):
65
65
  * @returns The age string.
66
66
  */
67
67
  export declare function calculateAgeString(birthDateStr: string, endDateStr?: string): string | undefined;
68
+ /**
69
+ * Returns all questionnaire answers as a map by link ID.
70
+ * @param response The questionnaire response resource.
71
+ * @returns Questionnaire answers mapped by link ID.
72
+ */
73
+ export declare function getQuestionnaireAnswers(response: QuestionnaireResponse): Record<string, QuestionnaireResponseItemAnswer>;
74
+ /**
75
+ * Returns an extension value by extension URLs.
76
+ * @param resource The base resource.
77
+ * @param urls Array of extension URLs. Each entry represents a nested extension.
78
+ * @returns The extension value if found; undefined otherwise.
79
+ */
80
+ export declare function getExtensionValue(resource: Resource, ...urls: string[]): string | undefined;
68
81
  /**
69
82
  * FHIR JSON stringify.
70
83
  * Removes properties with empty string values.
@@ -78,12 +91,29 @@ export declare function stringify(value: any, pretty?: boolean): string;
78
91
  /**
79
92
  * Resource equality.
80
93
  * Ignores meta.versionId and meta.lastUpdated.
81
- * See: https://dmitripavlutin.com/how-to-compare-objects-in-javascript/#4-deep-equality
82
94
  * @param object1 The first object.
83
95
  * @param object2 The second object.
84
96
  * @returns True if the objects are equal.
85
97
  */
86
- export declare function deepEquals(object1: any, object2: any, path?: string): boolean;
98
+ export declare function deepEquals(object1: unknown, object2: unknown, path?: string): boolean;
99
+ /**
100
+ * Returns true if the input string is a UUID.
101
+ * @param input The input string.
102
+ * @returns True if the input string matches the UUID format.
103
+ */
104
+ export declare function isUUID(input: string): boolean;
105
+ /**
106
+ * Returns true if the input is an object.
107
+ * @param object The candidate object.
108
+ * @returns True if the input is a non-null non-undefined object.
109
+ */
110
+ export declare function isObject(obj: unknown): obj is Record<string, unknown>;
111
+ /**
112
+ * Returns true if the input array is an array of strings.
113
+ * @param arr Input array.
114
+ * @returns True if the input array is an array of strings.
115
+ */
116
+ export declare function isStringArray(arr: any[]): arr is string[];
87
117
  /**
88
118
  * Converts an ArrayBuffer to hex string.
89
119
  * See: https://stackoverflow.com/a/55200387
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@medplum/core",
3
- "version": "0.9.0",
3
+ "version": "0.9.3",
4
4
  "description": "Medplum TS/JS Library",
5
5
  "author": "Medplum <hello@medplum.com>",
6
6
  "license": "Apache-2.0",
@@ -17,7 +17,7 @@
17
17
  "test": "jest"
18
18
  },
19
19
  "devDependencies": {
20
- "@medplum/fhirtypes": "0.9.0",
20
+ "@medplum/fhirtypes": "0.9.3",
21
21
  "fast-json-patch": "3.1.1"
22
22
  },
23
23
  "main": "dist/cjs/index.js",
@@ -1,116 +0,0 @@
1
- import { Bundle, OperationOutcome, Reference, Resource } from '@medplum/fhirtypes';
2
- import { Operation } from 'fast-json-patch';
3
- import { MedplumClient } from './client';
4
- import { SearchRequest } from './search';
5
- /**
6
- * The LegacyRepositoryResult type is a tuple of operation outcome and optional resource.
7
- * @deprecated
8
- */
9
- export declare type LegacyRepositoryResult<T extends Resource | undefined> = Promise<[OperationOutcome, T | undefined]>;
10
- /**
11
- * The LegacyRepositoryClient is a supplementary API client that matches the legacy "Repository" API.
12
- * The "Repository" API is deprecated and will be removed in a future release.
13
- * This LegacyRepositoryClient is also deprecated and will be removed in a future release.
14
- * @deprecated
15
- */
16
- export declare class LegacyRepositoryClient {
17
- #private;
18
- constructor(client: MedplumClient);
19
- /**
20
- * Creates a resource.
21
- *
22
- * See: https://www.hl7.org/fhir/http.html#create
23
- *
24
- * @param resource The resource to create.
25
- * @returns Operation outcome and the new resource.
26
- * @deprecated
27
- */
28
- createResource<T extends Resource>(resource: T): LegacyRepositoryResult<T>;
29
- /**
30
- * Returns a resource.
31
- *
32
- * See: https://www.hl7.org/fhir/http.html#read
33
- *
34
- * @param resourceType The FHIR resource type.
35
- * @param id The FHIR resource ID.
36
- * @returns Operation outcome and a resource.
37
- * @deprecated
38
- */
39
- readResource<T extends Resource>(resourceType: string, id: string): LegacyRepositoryResult<T>;
40
- /**
41
- * Returns a resource by FHIR reference.
42
- *
43
- * See: https://www.hl7.org/fhir/http.html#read
44
- *
45
- * @param reference The FHIR reference.
46
- * @returns Operation outcome and a resource.
47
- * @deprecated
48
- */
49
- readReference<T extends Resource>(reference: Reference<T>): LegacyRepositoryResult<T>;
50
- /**
51
- * Returns resource history.
52
- *
53
- * See: https://www.hl7.org/fhir/http.html#history
54
- *
55
- * @param resourceType The FHIR resource type.
56
- * @param id The FHIR resource ID.
57
- * @returns Operation outcome and a history bundle.
58
- * @deprecated
59
- */
60
- readHistory<T extends Resource>(resourceType: string, id: string): LegacyRepositoryResult<Bundle<T>>;
61
- /**
62
- * Returns a resource version.
63
- *
64
- * See: https://www.hl7.org/fhir/http.html#vread
65
- *
66
- * @param resourceType The FHIR resource type.
67
- * @param id The FHIR resource ID.
68
- * @param vid The version ID.
69
- * @returns Operation outcome and a resource.
70
- * @deprecated
71
- */
72
- readVersion<T extends Resource>(resourceType: string, id: string, vid: string): LegacyRepositoryResult<T>;
73
- /**
74
- * Updates a resource.
75
- *
76
- * See: https://www.hl7.org/fhir/http.html#update
77
- *
78
- * @param resource The resource to update.
79
- * @returns Operation outcome and the updated resource.
80
- * @deprecated
81
- */
82
- updateResource<T extends Resource>(resource: T): LegacyRepositoryResult<T>;
83
- /**
84
- * Deletes a resource.
85
- *
86
- * See: https://www.hl7.org/fhir/http.html#delete
87
- *
88
- * @param resourceType The FHIR resource type.
89
- * @param id The resource ID.
90
- * @returns Operation outcome.
91
- * @deprecated
92
- */
93
- deleteResource(resourceType: string, id: string): LegacyRepositoryResult<undefined>;
94
- /**
95
- * Patches a resource.
96
- *
97
- * See: https://www.hl7.org/fhir/http.html#patch
98
- *
99
- * @param resourceType The FHIR resource type.
100
- * @param id The resource ID.
101
- * @param patch Array of JSONPatch operations.
102
- * @returns Operation outcome and the resource.
103
- * @deprecated
104
- */
105
- patchResource(resourceType: string, id: string, patch: Operation[]): LegacyRepositoryResult<Resource>;
106
- /**
107
- * Searches for resources.
108
- *
109
- * See: https://www.hl7.org/fhir/http.html#search
110
- *
111
- * @param searchRequest The search request.
112
- * @returns The search result bundle.
113
- * @deprecated
114
- */
115
- search<T extends Resource>(query: SearchRequest | string): LegacyRepositoryResult<Bundle<T>>;
116
- }
package/docs/.nojekyll DELETED
@@ -1 +0,0 @@
1
- TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.
@@ -1,92 +0,0 @@
1
- :root {
2
- --light-hl-0: #001080;
3
- --dark-hl-0: #9CDCFE;
4
- --light-hl-1: #000000;
5
- --dark-hl-1: #D4D4D4;
6
- --light-hl-2: #AF00DB;
7
- --dark-hl-2: #C586C0;
8
- --light-hl-3: #A31515;
9
- --dark-hl-3: #CE9178;
10
- --light-hl-4: #0000FF;
11
- --dark-hl-4: #569CD6;
12
- --light-hl-5: #0070C1;
13
- --dark-hl-5: #4FC1FF;
14
- --light-hl-6: #795E26;
15
- --dark-hl-6: #DCDCAA;
16
- --light-hl-7: #008000;
17
- --dark-hl-7: #6A9955;
18
- --light-hl-8: #098658;
19
- --dark-hl-8: #B5CEA8;
20
- --light-hl-9: #0451A5;
21
- --dark-hl-9: #9CDCFE;
22
- --light-code-background: #F5F5F5;
23
- --dark-code-background: #1E1E1E;
24
- }
25
-
26
- @media (prefers-color-scheme: light) { :root {
27
- --hl-0: var(--light-hl-0);
28
- --hl-1: var(--light-hl-1);
29
- --hl-2: var(--light-hl-2);
30
- --hl-3: var(--light-hl-3);
31
- --hl-4: var(--light-hl-4);
32
- --hl-5: var(--light-hl-5);
33
- --hl-6: var(--light-hl-6);
34
- --hl-7: var(--light-hl-7);
35
- --hl-8: var(--light-hl-8);
36
- --hl-9: var(--light-hl-9);
37
- --code-background: var(--light-code-background);
38
- } }
39
-
40
- @media (prefers-color-scheme: dark) { :root {
41
- --hl-0: var(--dark-hl-0);
42
- --hl-1: var(--dark-hl-1);
43
- --hl-2: var(--dark-hl-2);
44
- --hl-3: var(--dark-hl-3);
45
- --hl-4: var(--dark-hl-4);
46
- --hl-5: var(--dark-hl-5);
47
- --hl-6: var(--dark-hl-6);
48
- --hl-7: var(--dark-hl-7);
49
- --hl-8: var(--dark-hl-8);
50
- --hl-9: var(--dark-hl-9);
51
- --code-background: var(--dark-code-background);
52
- } }
53
-
54
- body.light {
55
- --hl-0: var(--light-hl-0);
56
- --hl-1: var(--light-hl-1);
57
- --hl-2: var(--light-hl-2);
58
- --hl-3: var(--light-hl-3);
59
- --hl-4: var(--light-hl-4);
60
- --hl-5: var(--light-hl-5);
61
- --hl-6: var(--light-hl-6);
62
- --hl-7: var(--light-hl-7);
63
- --hl-8: var(--light-hl-8);
64
- --hl-9: var(--light-hl-9);
65
- --code-background: var(--light-code-background);
66
- }
67
-
68
- body.dark {
69
- --hl-0: var(--dark-hl-0);
70
- --hl-1: var(--dark-hl-1);
71
- --hl-2: var(--dark-hl-2);
72
- --hl-3: var(--dark-hl-3);
73
- --hl-4: var(--dark-hl-4);
74
- --hl-5: var(--dark-hl-5);
75
- --hl-6: var(--dark-hl-6);
76
- --hl-7: var(--dark-hl-7);
77
- --hl-8: var(--dark-hl-8);
78
- --hl-9: var(--dark-hl-9);
79
- --code-background: var(--dark-code-background);
80
- }
81
-
82
- .hl-0 { color: var(--hl-0); }
83
- .hl-1 { color: var(--hl-1); }
84
- .hl-2 { color: var(--hl-2); }
85
- .hl-3 { color: var(--hl-3); }
86
- .hl-4 { color: var(--hl-4); }
87
- .hl-5 { color: var(--hl-5); }
88
- .hl-6 { color: var(--hl-6); }
89
- .hl-7 { color: var(--hl-7); }
90
- .hl-8 { color: var(--hl-8); }
91
- .hl-9 { color: var(--hl-9); }
92
- pre, code { background: var(--code-background); }