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

Text alignment override class #789

Closed
teodorastraianu1 opened this issue Nov 2, 2021 · 1 comment · Fixed by #802
Closed

Text alignment override class #789

teodorastraianu1 opened this issue Nov 2, 2021 · 1 comment · Fixed by #802
Assignees

Comments

@teodorastraianu1
Copy link

Bug Report

What is the issue?

Related issue: nhsuk/nhsuk-service-manual-community-backlog#297

We need a new override class for text alignment. Normally text needs to be aligned to the left (and it is by default in the prototype kit), but there are a few exceptions. (e.g. languages that run right to left, such as Arabic, when text needs to be right-aligned).

We are currently working on publishing guidance in the service manual explaining text should be left aligned unless it is an exception and we need a new override class to support those exceptions.

To support this guidance we only need an override class for right-alignment, but I see GOV's approach was creating an override class for left, center or right: alphagov/govuk-frontend#2339

I think this would be a better approach, in case we ever need to suggest aligning text to left or center.

What steps are required to reproduce the issue?

  • Create override classes for aligning text to left, center and right.
  • Publish those classes in the frontend.

What was the environment where this issue occurred?

  • Device: n/a
  • Operating System: n/a
  • Browser: n/a
  • Browser version: n/a
  • NHS.UK frontend package version: n/a
  • Node version: n/a
  • npm version: n/a

Is there anything else you think would be useful in recreating the issue?

@henocookie
Copy link
Contributor

henocookie commented Jan 11, 2022

@DomBaker or @wa-rren-dev please could one of you check the PR is good to merge? @mcheung-nhs has already accepted the review but just want one more check ideally.

Then we will have to:

  1. update the nhsuk-frontend version for the service manual app
  2. update the text-alignment example to use the nhsuk-frontend right-align text-alignment class
  3. remove the custom CSS in the service manual app

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

4 participants