Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help page document #4250

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Help page document #4250

wants to merge 8 commits into from

Conversation

georges1996
Copy link
Contributor

@georges1996 georges1996 commented Oct 4, 2024

⚠️ This repo is Continuously Deployed: make sure you follow the guidance ⚠️

What

Handle Help page documents in Frontend, in preparation for them being taken out of Government Frontend

Why

https://trello.com/c/GP0bkcD4/350-move-document-type-helppage-from-government-frontend-to-frontend

How

These documents all have a fixed prefix, so add a scoped route for them, a controller, a model and a view. Here we add the initial ContentItem model the document type models will be based on, with the minimum functionality required to get Help page documents working.

We also create a couple of helpers for rendering generic content.

Screenshots?

From example page: https://www.gov.uk/help/browsers

Before (running in Government Frontend)

Screenshot 2024-10-04 at 07 54 53

After (running in Frontend)

Screenshot 2024-10-04 at 07 54 35

@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 4, 2024 06:42 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 4, 2024 06:56 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 4, 2024 11:59 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 4, 2024 12:02 Inactive
@georges1996 georges1996 marked this pull request as ready for review October 8, 2024 08:43
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 11:05 Inactive
Copy link
Contributor

@leenagupte leenagupte left a comment

Choose a reason for hiding this comment

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

This is a really good start. I think not being able to merge the Take Part PR means that this one needs some extra work before it's ready.

We've already spoken IRL about linking to the files in government-frontend directly. I think the only commit that needs the links updated is the one that ports over the components.

I've added inline comments for everything else.

spec/components/published_dates_spec.rb Outdated Show resolved Hide resolved
config/locales/en.yml Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
config/routes.rb Show resolved Hide resolved
spec/system/help_page_spec.rb Outdated Show resolved Hide resolved
spec/system/sessions_spec.rb Outdated Show resolved Hide resolved
spec/helpers/date_helper_spec.rb Show resolved Hide resolved
app/views/help_page/show.html.erb Outdated Show resolved Hide resolved
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 17:47 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 17:52 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 17:55 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 17:58 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 18:00 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 18:16 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 19:29 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 19:48 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 9, 2024 20:03 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 10, 2024 12:59 Inactive
@govuk-ci govuk-ci temporarily deployed to govuk-frontend-app-pr-4250 October 10, 2024 13:39 Inactive
Commit audit trail:
- app/views/shared/_footer_navigation.html.erb alphagov/government-frontend@6500698
- app/views/shared/_sidebar_navigation.html.erb alphagov/government-frontend@abd4912
-  Ran rake "consolidation:copy_translation[components.published_dates]"
…p_page

- Add new route
- Add help_page controller
- Update content item model
- Add help_page views
- Add system  spec for the new help_page

Commit audit trail:
- spec/system/help_page_spec.rb https://github.com/alphagov/government-frontend/blob/af54031948650448b965ac274c3248d23658c4f6/test/integration/help_page_test.rb
- app/views/help_page/show.html.erb https://github.com/alphagov/government-frontend/blob/af54031948650448b965ac274c3248d23658c4f6/app/views/content_items/help_page.html.erb
- Ran rake "rake "consolidation:copy_translation[i18n]"
Copy link
Contributor

@KludgeKML KludgeKML left a comment

Choose a reason for hiding this comment

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

LGTM (but we need a second opinion because I am now implicated in some of this)

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.

4 participants