@smile-cdr/fhirts 1.3.1 → 1.4.2

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.
@@ -7,6 +7,9 @@ on:
7
7
  push:
8
8
  branches:
9
9
  - master
10
+ paths-ignore:
11
+ - '**.md'
12
+ - '**.yml'
10
13
 
11
14
  jobs:
12
15
  release:
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.4.2
4
+
5
+ ### Updates (R3)
6
+
7
+ * Removed `Id` type used by `Meta.versionId` and changed to `string`.
8
+
9
+ ## 1.4.1
10
+
11
+ ### Updates (R3)
12
+
13
+ * Added support for nested `QuestionnaireResponseItem` in `QuestionnaireResponse.item` and `QuestionnaireResponse.item.answer`.
14
+
15
+ ## 1.4.0
16
+ ---
17
+ ### Updates (R3)
18
+
19
+ * The `Participant` class has been re-tooled to only be used in the `Appointment` class
20
+ * Droped the `Period` field in the `Participant` class as it is not used in `Appointment.participant`
21
+ * Added `EncounterParticipant` to replace the class type in `Encounter.participant`
22
+ * `EncounterParticipant` follows the STU3 spec for `Encounter.participant`
23
+
24
+ This release introduces a breaking change for Encounter.If you're using `Encounter` in your code, the `participant` field will have a new type, `EncounterParticipant` with the appropriate changes. This will break existing implementations, unless they are updated to take advantage of the new `EncounterParticipant` class. The `Period` in the `Participant` class has been removed as it's not using by the `Appointment.participant` field.
25
+
3
26
  ## 1.3.1
4
27
  ---
5
28
  ### Updates (R3)
@@ -149,4 +172,4 @@
149
172
 
150
173
  ### Updates (R4)
151
174
 
152
- * All classes previously created have been replaced with classes generated from swagger
175
+ * All classes previously created have been replaced with classes generated from swagger
package/dist/FHIR-R3.d.ts CHANGED
@@ -5,10 +5,6 @@ export declare class FHIRElement {
5
5
  export declare class BackboneElement extends FHIRElement {
6
6
  modifierExtension: any;
7
7
  }
8
- export declare class Id {
9
- private id;
10
- constructor(input?: string);
11
- }
12
8
  export declare class DomainResource {
13
9
  text: Narrative;
14
10
  contained: Resource[];
@@ -83,7 +79,7 @@ export declare class Address extends FHIRElement {
83
79
  period: Period;
84
80
  }
85
81
  export declare class Meta extends FHIRElement {
86
- versionId: Id;
82
+ versionId: string;
87
83
  lastUpdated: string;
88
84
  profile: string;
89
85
  security: Coding;
@@ -236,6 +232,7 @@ export declare class Answer extends BackboneElement {
236
232
  valueQuantity: Quantity;
237
233
  valueBoolean: boolean;
238
234
  valueReference: Reference;
235
+ item: QuestionnaireResponseItem[];
239
236
  }
240
237
  export declare class FHIROption extends BackboneElement {
241
238
  value: any;
@@ -273,6 +270,10 @@ export declare class Participant extends BackboneElement {
273
270
  actor: Reference;
274
271
  required: string;
275
272
  status: string;
273
+ }
274
+ export declare class EncounterParticipant extends BackboneElement {
275
+ type: CodeableConcept[];
276
+ individual: Reference;
276
277
  period: Period;
277
278
  }
278
279
  export declare class Activity extends BackboneElement {
@@ -420,6 +421,7 @@ export declare class QuestionnaireResponseItem extends BackboneElement {
420
421
  definition: string;
421
422
  text: string;
422
423
  answer: Answer[];
424
+ item: QuestionnaireResponseItem[];
423
425
  }
424
426
  export declare class Item extends BackboneElement {
425
427
  linkId: string;
@@ -649,7 +651,7 @@ export declare class Encounter extends Resource {
649
651
  status: string;
650
652
  episodeOfCare: Reference[];
651
653
  subject: Reference;
652
- participant: Participant[];
654
+ participant: EncounterParticipant[];
653
655
  }
654
656
  export declare class CareTeamParticipant extends BackboneElement {
655
657
  role: CodeableConcept;
package/dist/FHIR-R3.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Restriction = exports.SampledData = exports.Output = exports.Input = exports.Range = exports.Ratio = exports.Component = exports.Timing = exports.Activity = exports.Participant = exports.ReferenceRange = exports.Context = exports.ContextRelated = exports.Annotation = exports.FHIROption = exports.Answer = exports.EnableWhen = exports.Network = exports.Payload = exports.Identifier = exports.Reference = exports.ContactDetail = exports.ContactPoint = exports.Contact = exports.PatientCommunication = exports.Link = exports.Content = exports.Qualification = exports.Attachment = exports.VaccinationProtocol = exports.ImmunizationReaction = exports.ImmunizationExplaination = exports.PractitionerForImmunization = exports.UsageContext = exports.Quantity = exports.Period = exports.CodeableConcept = exports.Meta = exports.Address = exports.Extension = exports.HumanName = exports.DoseCoding = exports.Coding = exports.Code = exports.Narrative = exports.Resource = exports.DomainResource = exports.Id = exports.BackboneElement = exports.FHIRElement = void 0;
3
+ exports.Restriction = exports.SampledData = exports.Output = exports.Input = exports.Range = exports.Ratio = exports.Component = exports.Timing = exports.Activity = exports.EncounterParticipant = exports.Participant = exports.ReferenceRange = exports.Context = exports.ContextRelated = exports.Annotation = exports.FHIROption = exports.Answer = exports.EnableWhen = exports.Network = exports.Payload = exports.Identifier = exports.Reference = exports.ContactDetail = exports.ContactPoint = exports.Contact = exports.PatientCommunication = exports.Link = exports.Content = exports.Qualification = exports.Attachment = exports.VaccinationProtocol = exports.ImmunizationReaction = exports.ImmunizationExplaination = exports.PractitionerForImmunization = exports.UsageContext = exports.Quantity = exports.Period = exports.CodeableConcept = exports.Meta = exports.Address = exports.Extension = exports.HumanName = exports.DoseCoding = exports.Coding = exports.Code = exports.Narrative = exports.Resource = exports.DomainResource = exports.BackboneElement = exports.FHIRElement = void 0;
4
4
  exports.ClinicalImpressionFinding = exports.ClinicalImpressionInvestigation = exports.ClinicalImpression = exports.Slot = exports.Schedule = exports.HealthcareService = exports.Bundle = exports.AuditEvent = exports.CommunicationRequest = exports.Immunization = exports.Observation = exports.Device = exports.Practitioner = exports.PractitionerRole = exports.ProcedureRequest = exports.Task = exports.Communication = exports.CarePlan = exports.EpisodeOfCare = exports.CareTeam = exports.CareTeamParticipant = exports.Encounter = exports.ProcessRequest = exports.Account = exports.Location = exports.Organization = exports.AppointmentResponse = exports.Appointment = exports.DocumentReference = exports.Patient = exports.Questionnaire = exports.QuestionnaireResponse = exports.Udi = exports.Entity = exports.EntityDetail = exports.Source = exports.Agent = exports.Item = exports.QuestionnaireResponseItem = exports.Requester = exports.Position = exports.ActivityDetail = exports.BundleEntry = exports.BundleResponse = exports.BundleRequest = exports.Search = exports.BundleSignature = exports.BundleLink = exports.NotAvailable = exports.AvailableTime = void 0;
5
5
  /* This is base class from which other elements are derived */
6
6
  class FHIRElement {
@@ -10,18 +10,6 @@ class BackboneElement extends FHIRElement {
10
10
  }
11
11
  exports.BackboneElement = BackboneElement;
12
12
  /* FHIR classes used in resources */
13
- class Id {
14
- constructor(input) {
15
- const re = new RegExp('[A-Za-z0-9\\-\\.]{1,64}');
16
- if (re.test(input)) {
17
- this.id = input;
18
- }
19
- else {
20
- throw new RangeError('Not a valid Id string - must match reg exp [A-Za-z0-9\\-\\.]{1,64} Was provided: ' + input);
21
- }
22
- }
23
- }
24
- exports.Id = Id;
25
13
  class DomainResource {
26
14
  }
27
15
  exports.DomainResource = DomainResource;
@@ -211,6 +199,9 @@ exports.ReferenceRange = ReferenceRange;
211
199
  class Participant extends BackboneElement {
212
200
  }
213
201
  exports.Participant = Participant;
202
+ class EncounterParticipant extends BackboneElement {
203
+ }
204
+ exports.EncounterParticipant = EncounterParticipant;
214
205
  class Activity extends BackboneElement {
215
206
  }
216
207
  exports.Activity = Activity;
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smile-cdr/fhirts",
3
- "version": "1.3.1",
3
+ "version": "1.4.2",
4
4
  "description": "Fhir ts/js library for frontend apps",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/index.js",
@@ -10,7 +10,6 @@
10
10
  "build": "tsc"
11
11
  },
12
12
  "devDependencies": {
13
- "@changesets/cli": "^2.21.0",
14
13
  "typescript": "^4.0.2"
15
14
  }
16
15
  }
package/src/FHIR-R3.ts CHANGED
@@ -8,19 +8,6 @@ export class BackboneElement extends FHIRElement {
8
8
  modifierExtension: any;
9
9
  }
10
10
  /* FHIR classes used in resources */
11
- export class Id {
12
- private id: string;
13
-
14
- constructor(input?: string) {
15
- const re = new RegExp('[A-Za-z0-9\\-\\.]{1,64}');
16
-
17
- if (re.test(input)) {
18
- this.id = input;
19
- } else {
20
- throw new RangeError('Not a valid Id string - must match reg exp [A-Za-z0-9\\-\\.]{1,64} Was provided: ' + input);
21
- }
22
- }
23
- }
24
11
 
25
12
  export class DomainResource {
26
13
  text: Narrative;
@@ -127,7 +114,7 @@ export class Address extends FHIRElement {
127
114
  }
128
115
 
129
116
  export class Meta extends FHIRElement {
130
- versionId: Id;
117
+ versionId: string;
131
118
  lastUpdated: string;
132
119
  profile: string;
133
120
  security: Coding;
@@ -339,6 +326,7 @@ export class Answer extends BackboneElement {
339
326
  valueQuantity: Quantity;
340
327
  valueBoolean: boolean;
341
328
  valueReference: Reference;
329
+ item: QuestionnaireResponseItem[];
342
330
  }
343
331
 
344
332
 
@@ -391,8 +379,14 @@ export class Participant extends BackboneElement {
391
379
  actor: Reference;
392
380
  required: string;
393
381
  status: string;
382
+ }
383
+
384
+ export class EncounterParticipant extends BackboneElement {
385
+ type: CodeableConcept[];
386
+ individual: Reference;
394
387
  period: Period;
395
388
  }
389
+
396
390
  export class Activity extends BackboneElement {
397
391
  outcomeCodeableConcept: CodeableConcept[];
398
392
  outcomeReference: Reference[];
@@ -560,6 +554,7 @@ export class QuestionnaireResponseItem extends BackboneElement {
560
554
  definition: string;
561
555
  text: string;
562
556
  answer: Answer[];
557
+ item: QuestionnaireResponseItem[];
563
558
  }
564
559
 
565
560
  export class Item extends BackboneElement {
@@ -810,7 +805,7 @@ export class Encounter extends Resource {
810
805
  status: string;
811
806
  episodeOfCare: Reference[];
812
807
  subject: Reference;
813
- participant: Participant[];
808
+ participant: EncounterParticipant[];
814
809
  }
815
810
 
816
811
  export class CareTeamParticipant extends BackboneElement {
@@ -1,8 +0,0 @@
1
- # Changesets
2
-
3
- Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
4
- with multi-package repos, or single-package repos to help you version and publish your code. You can
5
- find the full documentation for it [in our repository](https://github.com/changesets/changesets)
6
-
7
- We have a quick list of common questions to get you started engaging with this project in
8
- [our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
@@ -1,8 +0,0 @@
1
- ---
2
- "@smile-cdr/fhirts": patch
3
- ---
4
- # 1.3.1
5
- ---
6
- ### Updates (R3)
7
-
8
- - Added class for `ClinicalImpression` resource.
@@ -1,11 +0,0 @@
1
- {
2
- "$schema": "https://unpkg.com/@changesets/config@1.7.0/schema.json",
3
- "changelog": "@changesets/cli/changelog",
4
- "commit": false,
5
- "fixed": [],
6
- "linked": [],
7
- "access": "restricted",
8
- "baseBranch": "master",
9
- "updateInternalDependencies": "patch",
10
- "ignore": []
11
- }