Skip to content

Defaults v2 summary title when not supplied#230

Merged
jbarnsley10 merged 5 commits intomainfrom
feat/DF-564-summary-title
Oct 31, 2025
Merged

Defaults v2 summary title when not supplied#230
jbarnsley10 merged 5 commits intomainfrom
feat/DF-564-summary-title

Conversation

@jbarnsley10
Copy link
Copy Markdown
Contributor

@jbarnsley10 jbarnsley10 commented Oct 24, 2025

Proposed change

Default the summary title of a v2 form to 'Check your answers before sending your form' if no title is supplied (i.e. empty string). If a title is supplied, use that instead.

v1 forms cannot have an empty string as the title, so we can only use the title provided.

Another PR for forms-manager will be required to do a DB migration to do the following:

  • leave V1 forms unchanged
  • set any v2 forms that have summary title as 'Summary' to have summary title as empty string
  • do the above for both live and draft forms
image

Jira ticket: DF-564

Type of change

  • Bug fix
  • New feature
  • Breaking change
  • Misc. (documentation, build updates, etc)

Checklist

  • You have executed this code locally and it performs as expected.
  • You have added tests to verify your code works.
  • You have added code comments and JSDoc, where appropriate.
  • There is no commented-out code.
  • You have added developer docs in README.md and docs/* (where appropriate, e.g. new features).
  • The tests are passing (npm run test).
  • The linting checks are passing (npm run lint).
  • The code has been formatted (npm run format).

@jbarnsley10 jbarnsley10 marked this pull request as ready for review October 28, 2025 11:21
@sonarqubecloud
Copy link
Copy Markdown


this.page = page
this.pageTitle = page.title
if (def.schema === SchemaVersion.V2 && !page.title) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably not neccessary to do a check specifically on V2 to be honest, I don't think it'd ever occur as a scenario. All good anyway.

@jbarnsley10 jbarnsley10 merged commit 0e85e81 into main Oct 31, 2025
10 checks passed
@jbarnsley10 jbarnsley10 deleted the feat/DF-564-summary-title branch October 31, 2025 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants