@planning-inspectorate/data-model 2.20.0 → 2.21.1

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 (29) hide show
  1. package/README.md +8 -8
  2. package/package.json +4 -2
  3. package/pins_data_model/models/model_appeal_document.py +1 -1
  4. package/pins_data_model/models/model_appeal_event.py +1 -1
  5. package/pins_data_model/models/model_appeal_event_estimate.py +1 -1
  6. package/pins_data_model/models/model_appeal_has.py +1 -1
  7. package/pins_data_model/models/model_appeal_representation.py +1 -1
  8. package/pins_data_model/models/model_appeal_s78.py +1 -1
  9. package/pins_data_model/models/model_dart_response.py +1 -1
  10. package/pins_data_model/models/model_entraid.py +1 -1
  11. package/pins_data_model/models/model_folder.py +1 -1
  12. package/pins_data_model/models/model_gettimesheets_response.py +1 -1
  13. package/pins_data_model/models/model_listed_building.py +1 -1
  14. package/pins_data_model/models/model_listed_buildings.py +1 -1
  15. package/pins_data_model/models/model_nsip_document.py +1 -1
  16. package/pins_data_model/models/model_nsip_exam_timetable.py +1 -1
  17. package/pins_data_model/models/model_nsip_invoice.py +1 -1
  18. package/pins_data_model/models/model_nsip_meeting.py +1 -1
  19. package/pins_data_model/models/model_nsip_project.py +1 -1
  20. package/pins_data_model/models/model_nsip_project_update.py +1 -1
  21. package/pins_data_model/models/model_nsip_representation.py +1 -1
  22. package/pins_data_model/models/model_nsip_subscription.py +1 -1
  23. package/pins_data_model/models/model_pins_inspector.py +1 -1
  24. package/pins_data_model/models/model_pins_lpa.py +1 -1
  25. package/pins_data_model/models/model_s51_advice.py +1 -1
  26. package/pins_data_model/models/model_service_user.py +1 -1
  27. package/schemas/commands/appeals-components/lpa-questionnaire-enforcement.schema.json +8 -4
  28. package/src/index.d.ts +2 -2
  29. package/src/schemas.d.ts +8 -2
package/README.md CHANGED
@@ -164,30 +164,30 @@ The schemas in this repository are written in jsonc (JSON with comments), and ca
164
164
 
165
165
  ## Node.js Usage
166
166
 
167
- To use these schemas in a Node project, add this repo as a dependency (with a particular tag or commit as the version):
167
+ To use these schemas in a Node project, add this repo as a dependency:
168
168
 
169
- `npm i -s Planning-Inspectorate/data-model#some-tag-or-commit`
169
+ `npm i -s @planning-inspectorate/data-model`
170
+
171
+ As usual with npm you can optionally specify a version:
172
+
173
+ `npm i -s @planning-inspectorate/data-model@2.20.0`
170
174
 
171
175
  Then import as required:
172
176
 
173
177
  ```es6
174
- import {loadAllSchemas} from 'pins-data-model';
178
+ import {loadAllSchemas} from '@planning-inspectorate/data-model';
175
179
  ```
176
180
 
177
181
  or to import enum constants, for example:
178
182
 
179
183
  ```es6
180
- import { APPEAL_CASE_STATUS } from 'pins-data-model';
184
+ import { APPEAL_CASE_STATUS } from '@planning-inspectorate/data-model';
181
185
 
182
186
  if (someAppeal.status === APPEAL_CASE_STATUS.COMPLETE) {
183
187
  console.log(`we're done!`);
184
188
  }
185
189
  ```
186
190
 
187
- To upgrade to a different version, simply doing npm command does not seem to get the correct version, so we need to first uninstall and then reinstall. You can do this by running:
188
-
189
- `npm uninstall pins-data-model && npm prune && npm i -s github:Planning-Inspectorate/data-model#some-tag-or-commit`
190
-
191
191
  ### Tests
192
192
 
193
193
  We are starting to add js tests to the models using node test runner
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@planning-inspectorate/data-model",
3
- "version": "2.20.0",
3
+ "version": "2.21.1",
4
4
  "description": "JSON Schemas for the Planning Inspectorate's Data Model",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -32,11 +32,13 @@
32
32
  "@adobe/jsonschema2md": "^8.0.3",
33
33
  "@commitlint/cli": "^20.1.0",
34
34
  "@commitlint/config-conventional": "^20.0.0",
35
+ "@eslint/js": "^10.0.1",
35
36
  "ajv": "^8.17.1",
36
37
  "ajv-formats": "^3.0.1",
37
38
  "conventional-changelog-conventionalcommits": "^9.1.0",
38
- "eslint": "^9.31.0",
39
+ "eslint": "^10.0.0",
39
40
  "eslint-config-prettier": "^10.1.5",
41
+ "globals": "^17.3.0",
40
42
  "husky": "^9.1.7",
41
43
  "json-schema-to-typescript": "^15.0.4",
42
44
  "lint-staged": "^16.1.2",
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-document.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-event.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-event-estimate.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-has.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-representation.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: appeal-s78.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: dart-response.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: entraid.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: folder.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: gettimesheets-response.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: listed-building.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: listed-buildings.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-document.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-exam-timetable.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-invoice.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-meeting.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-project.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-project-update.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-representation.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: nsip-subscription.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: pins-inspector.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: pins-lpa.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: s51-advice.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -1,6 +1,6 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: service-user.schema.json
3
- # timestamp: 2026-02-09T10:43:16+00:00
3
+ # timestamp: 2026-02-12T13:24:53+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
@@ -31,11 +31,15 @@
31
31
  "examples": [45.7],
32
32
  "description": "The site area, in square meters"
33
33
  },
34
- "hasAllegedBreachArea": {
35
- "type": ["boolean", "null"]
34
+ "areaOfAllegedBreachInSquareMetres": {
35
+ "type": ["number", "null"],
36
+ "examples": [45.7],
37
+ "description": "Area of the alleged breach, in square meters"
36
38
  },
37
- "doesAllegedBreachCreateFloorSpace": {
38
- "type": ["boolean", "null"]
39
+ "floorSpaceCreatedByBreachInSquareMetres": {
40
+ "type": ["number", "null"],
41
+ "examples": [45.7],
42
+ "description": "Floor space created by the breach, in square meters"
39
43
  },
40
44
  "changeOfUseRefuseOrWaste": {
41
45
  "type": ["boolean", "null"]
package/src/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import * as Schemas from './schemas';
2
- export * from './enums';
1
+ import * as Schemas from './schemas.js';
2
+ export * from './enums.js';
3
3
 
4
4
  export interface LoadedSchemas {
5
5
  schemas: {
package/src/schemas.d.ts CHANGED
@@ -4651,8 +4651,14 @@ export type LPAQEnforcementSubmissionProperties = {
4651
4651
  * The site area, in square meters
4652
4652
  */
4653
4653
  siteAreaSquareMetres?: number | null;
4654
- hasAllegedBreachArea?: boolean | null;
4655
- doesAllegedBreachCreateFloorSpace?: boolean | null;
4654
+ /**
4655
+ * Area of the alleged breach, in square meters
4656
+ */
4657
+ areaOfAllegedBreachInSquareMetres?: number | null;
4658
+ /**
4659
+ * Floor space created by the breach, in square meters
4660
+ */
4661
+ floorSpaceCreatedByBreachInSquareMetres?: number | null;
4656
4662
  changeOfUseRefuseOrWaste?: boolean | null;
4657
4663
  changeOfUseMineralExtraction?: boolean | null;
4658
4664
  changeOfUseMineralStorage?: boolean | null;