diff --git a/editor.planx.uk/src/@planx/components/List/Editor.tsx b/editor.planx.uk/src/@planx/components/List/Editor.tsx index 72b01dc3b7..339c08ca9c 100644 --- a/editor.planx.uk/src/@planx/components/List/Editor.tsx +++ b/editor.planx.uk/src/@planx/components/List/Editor.tsx @@ -17,6 +17,9 @@ import { ICONS } from "../shared/icons"; import { EditorProps } from "../shared/types"; import { List, parseContent, validationSchema } from "./model"; import { ProposedAdvertisements } from "./schemas/Adverts"; +import { ExistingBuildingsCIL } from "./schemas/CIL/ExistingCIL"; +import { MezzanineCIL } from "./schemas/CIL/MezzanineCIL"; +import { UnoccupiedBuildingsCIL } from "./schemas/CIL/UnoccupiedCIL"; import { NonResidentialFloorspace } from "./schemas/Floorspace"; import { BuildingDetailsGLA } from "./schemas/GLA/BuildingDetails"; import { CommunalSpaceGLA } from "./schemas/GLA/CommunalSpace"; @@ -69,6 +72,9 @@ export const SCHEMAS = [ { name: "Proposed advertisements", schema: ProposedAdvertisements }, { name: "Parking details", schema: Parking }, { name: "Parking details (GLA)", schema: ParkingGLA }, + { name: "Existing buildings (CIL)", schema: ExistingBuildingsCIL }, + { name: "Unoccupied buildings (CIL)", schema: UnoccupiedBuildingsCIL }, + { name: "Mezzanine floors (CIL)", schema: MezzanineCIL }, { name: "Trees", schema: Trees }, { name: "Trees (Map first)", schema: TreesMapFirst }, ]; diff --git a/editor.planx.uk/src/@planx/components/List/schemas/CIL/ExistingCIL.ts b/editor.planx.uk/src/@planx/components/List/schemas/CIL/ExistingCIL.ts new file mode 100644 index 0000000000..3f69e83302 --- /dev/null +++ b/editor.planx.uk/src/@planx/components/List/schemas/CIL/ExistingCIL.ts @@ -0,0 +1,65 @@ +import { Schema } from "@planx/components/shared/Schema/model"; +import { TextInputType } from "@planx/components/TextInput/model"; + +export const ExistingBuildingsCIL: Schema = { + type: "Existing building or part of building", + fields: [ + { + type: "text", + data: { + title: "Describe the existing building or part", + fn: "descriptionExisting", + type: TextInputType.Short, + }, + }, + { + type: "number", + data: { + title: "How much of its floorspace will be retained?", + units: "m²", + fn: "area.retained", + allowNegatives: false, + }, + }, + { + type: "text", + data: { + title: "What will the retained floorspace be used for?", + description: "This can be identical to its current use.", + fn: "descriptionProposed", + type: TextInputType.Short, + }, + }, + { + type: "number", + data: { + title: "How much of its floorspace will be lost?", + units: "m²", + fn: "area.loss", + allowNegatives: false, + }, + }, + { + type: "question", + data: { + title: + "Has the building or part been lawfully occupied for 6 continuous months in the past 36 months?", + fn: "continuousOccupation", + options: [ + { id: "true", data: { text: "Yes", val: "true" } }, + { id: "false", data: { text: "No", val: "false" } }, + ], + }, + }, + { + type: "text", + data: { + title: "When was it last occupied for its lawful use?", + description: "Please enter a date or whether it is still in use.", + fn: "lastOccupation", + type: TextInputType.Short, + }, + }, + ], + min: 1, +} as const; diff --git a/editor.planx.uk/src/@planx/components/List/schemas/CIL/MezzanineCIL.ts b/editor.planx.uk/src/@planx/components/List/schemas/CIL/MezzanineCIL.ts new file mode 100644 index 0000000000..3c216892d6 --- /dev/null +++ b/editor.planx.uk/src/@planx/components/List/schemas/CIL/MezzanineCIL.ts @@ -0,0 +1,27 @@ +import { Schema } from "@planx/components/shared/Schema/model"; +import { TextInputType } from "@planx/components/TextInput/model"; + +export const MezzanineCIL: Schema = { + type: "New mezzanine floor", + fields: [ + { + type: "text", + data: { + title: "Describe the use of the mezzanine", + fn: "description", + type: TextInputType.Short, + }, + }, + { + type: "number", + data: { + title: + "What will be the Gross Internal Floor Area (GIA) of the mezzanine?", + units: "m²", + fn: "area", + allowNegatives: false, + }, + }, + ], + min: 1, +} as const; diff --git a/editor.planx.uk/src/@planx/components/List/schemas/CIL/UnoccupiedCIL.ts b/editor.planx.uk/src/@planx/components/List/schemas/CIL/UnoccupiedCIL.ts new file mode 100644 index 0000000000..83126000b9 --- /dev/null +++ b/editor.planx.uk/src/@planx/components/List/schemas/CIL/UnoccupiedCIL.ts @@ -0,0 +1,44 @@ +import { Schema } from "@planx/components/shared/Schema/model"; +import { TextInputType } from "@planx/components/TextInput/model"; + +export const UnoccupiedBuildingsCIL: Schema = { + type: "Building not meant for occupation or temporarily permitted", + fields: [ + { + type: "text", + data: { + title: "Describe the existing building", + fn: "descriptionExisting", + type: TextInputType.Short, + }, + }, + { + type: "number", + data: { + title: "How much of its floorspace will be retained?", + units: "m²", + fn: "area.retained", + allowNegatives: false, + }, + }, + { + type: "text", + data: { + title: "What will the retained floorspace be used for?", + description: "This can be identical to its current use.", + fn: "descriptionProposed", + type: TextInputType.Short, + }, + }, + { + type: "number", + data: { + title: "How much of its floorspace will be lost?", + units: "m²", + fn: "area.loss", + allowNegatives: false, + }, + }, + ], + min: 1, +} as const;