import {
Document,
Image,
Page,
StyleSheet,
Text,
View,
Font,
} from "@react-pdf/renderer";
import Html from "react-pdf-html";
import { getFormCollectionByID, bytesToSize } from "../../components/utils";
const styles = StyleSheet.create({
page: {
backgroundColor: "white",
padding: 20,
fontSize: 16,
paddingBottom: 50,
},
header: {
fontSize: 25,
fontFamily: "Helvetica",
flexDirection: "row",
justifyContent: "space-between",
},
subHeader: {
fontSize: 20,
},
logoImage: { width: "200pt" },
questionBullet: { width: "5%", fontSize: 12 },
questionText: { width: "30%", fontSize: 12 },
questionTextMid: { width: "80%", fontSize: 12 },
questionTextWide: { width: "95%", fontSize: 12, marginBottom: 5 },
questionAnswer: {
color: "#757575",
width: "65%",
fontSize: 12,
padding: 5,
border: 1,
borderColor: "#eee",
paddingLeft: 10,
backgroundColor: "white",
},
questionAnswerMid: {
color: "#757575",
width: "20%",
fontSize: 12,
padding: 5,
border: 1,
borderColor: "#eee",
paddingLeft: 10,
backgroundColor: "white",
},
questionAnswerWide: {
color: "#757575",
width: "95%",
fontSize: 12,
marginLeft: "5%",
border: 1,
borderColor: "#eee",
backgroundColor: "white",
padding: 5,
},
sectionContainer: {
backgroundColor: "#F8F8F8",
padding: 10,
marginTop: 20,
fontSize: 15,
},
pageNumber: {
position: "absolute",
fontSize: 12,
bottom: 20,
left: 0,
right: 0,
textAlign: "center",
color: "grey",
},
richArea: {
fontSize: 12,
flexDirection: "column",
},
});
export const EnforcementQuestionnaire_pdf = ({ docProps }) => {
//console.log(docProps);
function formatDates(dateObj) {
var dateObj = new Date(dateObj);
var dd = String(dateObj.getDate()).padStart(2, "0");
var mm = String(dateObj.getMonth() + 1).padStart(2, "0"); //January is 0!
var yyyy = dateObj.getFullYear();
return dd + "/" + mm + "/" + yyyy;
}
let values = docProps;
let appealTypeValue = getFormCollectionByID(values.appealType);
//console.log("//////////////////////\n docpropseeeee:".docProps);
//console.log("sdffhjdhjdjdgkj: ", values.procedureType);
Font.registerHyphenationCallback((word) => [word]);
function CleanHTML(htmlStr) {
let cleanStr =
typeof htmlStr === "string"
? htmlStr.replace(/
<\/p>/g, "")
: "";
return cleanStr;
}
return (
Local Planning Authority Questionnaire
For Planning Enforcement Appeals
The LPA must send the completed questionnaire and
any attachments to PEDW.casework@gov.wales and the
appellant (or their agent) within 5 working days of
the start date specified in our start letter.
Case details
1.
{t(
"myrepresentations:s78-section-question-1"
)}
:
{values.caseRef}
2.
{t(
"myrepresentations:s78-section-question-2"
)}
:
{values.lpaRef}
3.
Site address/grid ref:
{values.siteAddress}
{t("myrepresentations:s78-section-heading-one")}
4.
Which procedure do you consider the
appeal should follow?
{values.procedureType}
{values.procedureType !=
"Written representations" && (
{CleanHTML(
values.procedureTypeEvidence
)}
)}
5.
Will the Inspector need to enter the appeal
site/property?
{values.enterToView}
6.
Do you consider that the Inspector needs
to enter neighbouring private
land/property to view the site?
{values.enterNeighbouringLandToViewSite}
{values.enterNeighbouringLandToViewSite ==
"Yes" && (
{CleanHTML(
values.enterNeighbouringLandToViewSiteEvidence
)}
)}
7.
If access to private land/buildings is
required, are you content for the
Inspector to visit the site on an
‘access required’ basis, with only the
landowner or their representative
present?
{
values.enterNeighbouringLandAccessRequired
}
{values.enterNeighbouringLandAccessRequired !=
"Yes" && (
{CleanHTML(
values.enterNeighbouringLandAccessRequiredEvidence
)}
)}
8.
Are you aware of any health and safety
issues which would need to be considered
when the Inspector visits the site?
{values.healthAndSafetyIssues}
{values.healthAndSafetyIssues == "Yes" && (
{CleanHTML(
values.healthAndSafetyIssuesEvidence
)}
)}
9.
LPA contact for site visit, hearing or
inquiry arrangements:
{CleanHTML(values.LPAcontactDetails)}
Deemed Application Fee{" "}
10.
Has the Local Planning Authority
received the correct fee payable in
relation to this appeal for the deemed
planning application/ground (a) to be
considered?
{values.feePaid}
11.
Is the appeal fee exempt?
{values.feeExempt}
{values.feeExempt == "Yes" && (
{CleanHTML(
values.feeExemptEvidence
)}
)}
Supporting documents
12.
Have any planning permissions or lawful
development certificates been granted
previously in respect of the development or
on the site?
{values.previousGrantedCerts}
{values.previousGrantedCerts == "Yes" && (
{CleanHTML(
values.previousGrantedCertsEvidence
)}
)}
13.
Has a Stop Notice been served in addition to
the Enforcement Notice?
{values.stopNoticeServed}
{values.stopNoticeServed == "Yes" && (
{CleanHTML(
values.stopNoticeServedEvidence
)}
)}
14.
Are there any related cases (e.g. appeals
under s78 of the Town and Country Planning
Act 1990) which are currently or have
previously been before the Welsh Ministers?
{values.relatedCases}
{values.relatedCases == "Yes" && (
{CleanHTML(values.relatedCasesEvidence)}
)}
15.
Has there been any previous enforcement
action on the site?
{values.previousEnforcement}
{values.previousEnforcement == "Yes" && (
{CleanHTML(
values.previousEnforcementEvidence
)}
)}
16.
Is the site subject to an Article 4
Direction?
{values.subjectArticle4}
{values.subjectArticle4 == "Yes" && (
{CleanHTML(
values.subjectArticle4Evidence
)}
)}
17.
Have permitted development rights been
restricted by any previous planning
condition?
{values.previousPDRRestriction}
{values.previousPDRRestriction == "Yes" && (
{CleanHTML(
values.previousPDRRestrictionEvidence
)}
)}
Supporting documents
18.
LPA’s adopted Local Development Plan and
Proposals Map
{CleanHTML(values.LPAldpAndMap)}
19.
Adopted local guidance relevant to the
proposal:
{CleanHTML(values.LPAlocalGuidance)}
20.
If applicable, do you intend to submit a
full statement at the 4-week stage?
{values.LPAintentionToSubmitFullStatement}
Statutory considerations
21.
Is all or part of the site within an Area of
Outstanding Natural Beauty?
{values.AONB}
22.
Does the site include any public rights
of way?
{values.ROW}
{values.ROW == "Yes" && (
{CleanHTML(values.ROWEvidence)}
)}
23.
Is all or part of the site within a
Conservation Area?
{values.conservationArea}{" "}
{values.conservationArea == "Yes" && (
{CleanHTML(
values.conservationAreaEvidence
)}
)}
24.
Does the development include works to,
or affect the setting of, a listed
building, Scheduled Monument or other
designated historic asset?
{values.affectListedBuilding}
{values.affectListedBuilding == "Yes" && (
{CleanHTML(
values.affectListedBuildingEvidence
)}
)}
25.
Is any part of the site subject to a
Tree Preservation Order?
{values.TPO}
{values.TPO == "Yes" && (
{CleanHTML(values.TPOEvidence)}
)}
26.
Is the site within or likely to affect
an International or National Designated
Site for nature conservation (as defined
in Planning Policy Wales)?
{values.natureConservationSite}
{values.natureConservationSite == "Yes" && (
{CleanHTML(
values.natureConservationSiteEvidence
)}
)}
27.
Are any protected species likely to be
affected by the proposal?
{values.protectedSpecies}
{values.protectedSpecies == "Yes" && (
{CleanHTML(
values.protectedSpeciesEvidence
)}
)}
28.
Does the case involve persons claiming
Gypsy/Traveller status, whether or not this
is accepted by the LPA?
{values.gypsyTravellerInvolvment}
29.
Is flooding an issue?
{values.floodingIssue}
{values.floodingIssue == "Yes" && (
{CleanHTML(
values.floodingIssueEvidence
)}
)}
30.
Have you received comments or directions
from any government department/agency or
statutory undertaker, including in
response to a statutory notification or
consultation?
{values.governmentDepartmentComments}
{values.governmentDepartmentComments ==
"Yes" && (
{CleanHTML(
values.governmentDepartmentCommentsEvidence
)}
)}
Suggested considerations
31.
If there is an appeal on ground (a), review
the following standard conditions and advise
whether they would be necessary if
permission is granted:
a)
The development shall be carried out in
accordance with the following approved
plans and documents:
............................ Reason: To
ensure the development is carried out in
accordance with the approved documents,
plans and drawings submitted with the
application.
{
values.developmentCarriedOutInAccordance
}
{values.developmentCarriedOutInAccordance ==
"Yes" && (
{CleanHTML(
values.developmentCarriedOutInAccordanceEvidence
)}
)}
b)
No development shall take place until a
scheme for biodiversity enhancement has been
submitted to and agreed in writing by the
Local Planning Authority. Development shall
be carried out in accordance with the
approved details. Reason: In the interests
of maintaining and enhancing biodiversity,
in accordance with Future Wales Policy 9.
{values.developmentNotTakePlaceBiodiversity}
d)
No development shall take place until a
scheme to enable the provision of gigabit
capable broadband infrastructure from the
site boundary to the dwellings/buildings
hereby permitted has been submitted to and
agreed in writing by the local planning
authority. Development shall be carried out
in accordance with the approved details.
Reason: To support the roll-out of digital
communications infrastructure across Wales
in accordance with Policy 13 of Future
Wales.
{values.developmentNotTakePlaceBroadband}
25.
Do you consider other conditions, or
amended versions of the above standard
conditions, to be necessary?
{values.developmentAnyOtherConditions}
{values.developmentAnyOtherConditions ==
"Yes" && (
{CleanHTML(
values.developmentAnyOtherConditionsEvidence
)}
)}
Before sending, have you attached or provided a
web link to:
33.
A true copy of the enforcement notice?
{values.copyOfEnforcementNotice}
{CleanHTML(
values.copyOfEnforcementNoticeEvidence
)}
34.
The enforcement notice plan.
{values.enforcementNoticePlan}
{CleanHTML(
values.enforcementNoticePlan
)}
35.
A list of those served with the
enforcement notice.
{values.listOfNotifiedOfEnforcement}
{CleanHTML(
values.listOfNotifiedOfEnforcementEvidence
)}
36.
A copy of the letter with which you
notified people of the appeal AND a list
of the people you notified?
{
values.copyOfLetterOfAppealNotification
}
{CleanHTML(
values.copyOfLetterOfAppealNotificationEvidence
)}
37.
The LPA’s Environmental Impact
Assessment Screening Opinion and
‘Regulation 45 Notice’*, if applicable?
{values.lpaEIAOS}
{values.lpaEIAOS == "Yes" && (
{CleanHTML(values.lpaEIAOSEvidence)}
)}
38.
Details of other appeals or applications
relating to the site, or a nearby site,
which are still being considered by PEDW
or the Welsh Ministers?
{values.detailsOfOtherAppeals}
{values.detailsOfOtherAppeals == "Yes" && (
{CleanHTML(
values.detailsOfOtherAppealsEvidence
)}
)}
39.
Details of any previous appeal decision
relating to the site or a nearby site
referred to by the LPA or applicant?
{values.detailsOfPreviousAppeals}
{values.detailsOfPreviousAppeals == "Yes" && (
{CleanHTML(
values.detailsOfPreviousAppealsEvidence
)}
)}
40.
Any other relevant information that we
should know about?
{values.otherRelevantInformation}
{values.otherRelevantInformation == "Yes" && (
{CleanHTML(
values.otherRelevantInformationEvidence
)}
)}
Declaration
Signed:
{values.caseOfficer}
Date:
{formatDates(values.signedDate)}
On behalf of:
{values.onBehalfOfLPA}
Supporting documents
List of attached files
{values.hasOwnProperty("filesList") &&
values.filesList.map(function (p) {
return (
{p.name} -{" "}
{bytesToSize(
p.size
)}{" "}
{"\n"}
);
})}
* Regulation 45 of the Town and Country Planning
(Environmental Impact Assessment) (Wales)
Regulations 2017 (as amended).
`${pageNumber} / ${totalPages}`
}
fixed
/>
);
};