questionnaire defect 54 - plus tidying up

This commit is contained in:
2025-01-13 17:04:19 +00:00
parent dc8cffad33
commit 463d03f798
+103 -28
View File
@@ -41,7 +41,7 @@ const styles = StyleSheet.create({
logoImage: { width: "200pt" }, logoImage: { width: "200pt" },
questionBullet: { width: "5%", fontSize: 12 }, questionBullet: { width: "5%", fontSize: 12 },
questionText: { width: "30%", fontSize: 12 }, questionText: { width: "30%", fontSize: 12 },
questionTextMid: { width: "80%", fontSize: 12 }, questionTextMid: { width: "75%", fontSize: 12, marginRight: 10 },
questionTextWide: { width: "95%", fontSize: 12, marginBottom: 5 }, questionTextWide: { width: "95%", fontSize: 12, marginBottom: 5 },
questionAnswer: { questionAnswer: {
color: "#757575", color: "#757575",
@@ -277,6 +277,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
wrap={false} wrap={false}
@@ -333,6 +334,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -371,6 +373,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -408,6 +411,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -443,6 +447,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -484,6 +489,14 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
</Text> </Text>
</View> </View>
<View style={styles.sectionContainer}> <View style={styles.sectionContainer}>
]
<View
style={{
flexDirection: "column",
marginBottom: 10,
}}
wrap={false}
>
<View <View
wrap={false} wrap={false}
style={{ style={{
@@ -491,39 +504,29 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
marginBottom: 10, marginBottom: 10,
}} }}
> >
<Text style={styles.questionBullet}>11.</Text> <Text style={styles.questionBullet}>
<Text style={styles.questionText}> 11.
</Text>
<Text style={styles.questionTextWide}>
{getTrans( {getTrans(
docProps.locale, docProps.locale,
"s78-section-question-11" "s78-section-question-11"
)} )}
</Text> </Text>
<View style={styles.questionAnswer}> </View>
<View style={styles.questionAnswerWide}>
<Html style={styles.richArea}> <Html style={styles.richArea}>
{CleanHTML(values.LPAcaseFileAndReps)} {CleanHTML(values.LPAcaseFileAndReps)}
</Html> </Html>
</View> </View>
</View> </View>
<View <View
wrap={false}
style={{ style={{
flexDirection: "row", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<Text style={styles.questionBullet}>12.</Text>
<Text style={styles.questionText}>
{getTrans(
docProps.locale,
"s78-section-question-12"
)}
</Text>
<View style={styles.questionAnswer}>
<Html style={styles.richArea}>
{CleanHTML(values.LPAldpAndMap)}
</Html>
</View>
</View>
<View <View
wrap={false} wrap={false}
style={{ style={{
@@ -531,14 +534,47 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
marginBottom: 10, marginBottom: 10,
}} }}
> >
<Text style={styles.questionBullet}>13.</Text> <Text style={styles.questionBullet}>
<Text style={styles.questionText}> 12.
</Text>
<Text style={styles.questionTextWide}>
{getTrans(
docProps.locale,
"s78-section-question-12"
)}
</Text>
</View>
<View style={styles.questionAnswerWide}>
<Html style={styles.richArea}>
{CleanHTML(values.LPAldpAndMap)}
</Html>
</View>
</View>
<View
style={{
flexDirection: "column",
marginBottom: 10,
}}
wrap={false}
>
<View
wrap={false}
style={{
flexDirection: "row",
marginBottom: 10,
}}
>
<Text style={styles.questionBullet}>
13.
</Text>
<Text style={styles.questionTextWide}>
{getTrans( {getTrans(
docProps.locale, docProps.locale,
"s78-section-question-13" "s78-section-question-13"
)} )}
</Text> </Text>
<View style={styles.questionAnswer}> </View>
<View style={styles.questionAnswerWide}>
<Html style={styles.richArea}> <Html style={styles.richArea}>
{CleanHTML(values.LPAlocalGuidance)} {CleanHTML(values.LPAlocalGuidance)}
</Html> </Html>
@@ -603,6 +639,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -636,6 +673,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -671,6 +709,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -706,6 +745,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -739,6 +779,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -774,6 +815,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -827,6 +869,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -915,6 +958,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -987,6 +1031,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1026,11 +1071,12 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
marginTop: 10, marginTop: 10,
fontFamily: "Helvetica-Bold", fontFamily: "Helvetica-Bold",
}} }}
wrap={false}
> >
<Text style={{ fontSize: 14 }}> <Text style={{ fontSize: 14 }}>
{getTrans( {getTrans(
docProps.locale, docProps.locale,
"s78-section-heading-five" "s78-section-heading-five-sub"
)} )}
</Text> </Text>
</View> </View>
@@ -1040,6 +1086,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1060,6 +1107,9 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
{values.copyOfApplicantsCertificate} {values.copyOfApplicantsCertificate}
</Text> </Text>
</View> </View>
{values.hasOwnProperty(
"copyOfApplicantsCertificateEvidence"
) && (
<View style={styles.questionAnswerWide}> <View style={styles.questionAnswerWide}>
<Html style={styles.richArea}> <Html style={styles.richArea}>
{CleanHTML( {CleanHTML(
@@ -1067,12 +1117,14 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
)} )}
</Html> </Html>
</View> </View>
)}
</View> </View>
<View <View
style={{ style={{
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1093,7 +1145,9 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
{values.advertismentGiven} {values.advertismentGiven}
</Text> </Text>
</View> </View>
{values.hasOwnProperty(
"advertismentGivenEvidence"
) && (
<View style={styles.questionAnswerWide}> <View style={styles.questionAnswerWide}>
<Html style={styles.richArea}> <Html style={styles.richArea}>
{CleanHTML( {CleanHTML(
@@ -1101,12 +1155,14 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
)} )}
</Html> </Html>
</View> </View>
)}
</View> </View>
<View <View
style={{ style={{
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1129,6 +1185,9 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
} }
</Text> </Text>
</View> </View>
{values.hasOwnProperty(
"copyOfLetterOfAppealNotificationEvidence"
) && (
<View style={styles.questionAnswerWide}> <View style={styles.questionAnswerWide}>
<Html style={styles.richArea}> <Html style={styles.richArea}>
{CleanHTML( {CleanHTML(
@@ -1136,12 +1195,14 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
)} )}
</Html> </Html>
</View> </View>
)}
</View> </View>
<View <View
style={{ style={{
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1175,6 +1236,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1213,6 +1275,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1248,6 +1311,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1283,6 +1347,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
flexDirection: "column", flexDirection: "column",
marginBottom: 10, marginBottom: 10,
}} }}
wrap={false}
> >
<View <View
style={{ style={{
@@ -1408,6 +1473,13 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
</Text> </Text>
</View> </View>
<View style={styles.sectionContainer}> <View style={styles.sectionContainer}>
<View
wrap={false}
style={{
flexDirection: "column",
marginBottom: 10,
}}
>
<View <View
wrap={false} wrap={false}
style={{ style={{
@@ -1415,16 +1487,19 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
marginBottom: 10, marginBottom: 10,
}} }}
> >
<Text style={styles.questionBullet}></Text> <Text
<Text style={styles.questionText}> style={styles.questionBullet}
></Text>
<Text style={styles.questionTextWide}>
{getTrans( {getTrans(
docProps.locale, docProps.locale,
"lpa-list-supporting-documents-list" "lpa-list-supporting-documents-list"
)} )}
</Text> </Text>
</View>
<View <View
style={[ style={[
styles.questionAnswer, styles.questionAnswerWide,
{ flexDirection: "column" }, { flexDirection: "column" },
]} ]}
> >
@@ -1446,7 +1521,7 @@ export const lpaQuestionnaire_pdf = ({ docProps }) => {
> >
{p.name} -{" "} {p.name} -{" "}
{bytesToSize( {bytesToSize(
p.size p.contentLength
)}{" "} )}{" "}
{"\n"} {"\n"}
</Text> </Text>