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

Add {stat-headline} markdown and styles for HTML publications #2356

Merged
merged 8 commits into from Oct 12, 2015
Merged

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Oct 9, 2015

https://trello.com/c/z4YmHWDp/127-html-pubs-add-markdown-to-allow-users-to-add-large-font-and-graphs-medium

Departments are about to create and publish their Single Departmental Plans. These will be published to GOV.UK as HTML publications. Departments need to be able to pull out important figures periodically throughout the HTML publication in large font.

  • Add guidance for the {stat-headline} markdown when adding and editing HTML publications
  • Style the markup generated by these headlines on HTML publications only
  • Add styles so the in-form preview shows an approximation of the final content
  • Switches all HTML pubs to have the same text colour as GOV.UK
{stat-headline}*13.8bn* years since the big bang{/stat-headline}

Guidance

screen shot 2015-10-09 at 12 32 24

## How to use it and preview

screen shot 2015-10-09 at 12 32 34

screen shot 2015-10-09 at 12 32 42

## Final HTML publication

screen shot 2015-10-09 at 12 33 20

cc @alextea

fofr added 8 commits Oct 6, 2015
HTML publications were displaying in a slightly lighter text colour
than the rest of GOV.UK.
Allow writers to pull out important numbers. This can be a single
number or a group of them.

“Departments are about to create and publish their Single Departmental
Plans. These will be published to GOV.UK as HTML publications.

It is a ministerial priority that depts can pull out important figures
periodically throughout the HTML publication in large font, and can
visually represent data in graphs (this is just images as per the
budget).”

https://trello.com/c/z4YmHWDp/127-html-pubs-add-markdown-to-allow-users-
to-add-large-font-and-graphs-medium
Groups aren’t necessary _yet_.

In user research the group has been used in a way that causes content
to render poorly. Content of different heights would render incorrectly
if more than 2 stats were used in a group. Content with long numbers
would overlap each other at thinner page widths when using standard
grid markup.

While styles could be modified to avoid these bugs, the simplest
approach for now is to remove this capability altogether. It may need
to be added if a user need arises as departments work on their single
departmental plans.
When previewing content in Whitehall show that the markdown is
rendering by making the number bigger and bolder.

It doesn’t match the front-end as the rest of the preview is
inconsistent.
See:
alphagov/govspeak@783a030
0e583c28c33b

Patterns using `{::` and `{:/` are confusing and lead to errors that
are difficult to spot.
@boffbowsh
Copy link
Contributor

@boffbowsh boffbowsh commented Oct 9, 2015

👍 from a codings POV

@jamiecobbett
Copy link
Contributor

@jamiecobbett jamiecobbett commented Oct 9, 2015

👍

@dsingleton
Copy link
Contributor

@dsingleton dsingleton commented Oct 12, 2015

👍 from me

@jamiecobbett
Copy link
Contributor

@jamiecobbett jamiecobbett commented Oct 12, 2015

I have two thumbs 👍 👍

fofr added a commit that referenced this pull request Oct 12, 2015
Add {stat-headline} markdown and styles for HTML publications
@fofr fofr merged commit 09c4f05 into master Oct 12, 2015
1 check passed
1 check passed
default Build #6770 succeeded on Jenkins
Details
@fofr fofr deleted the stat-headlines branch Oct 12, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.