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

Render news article format #232

Merged
merged 6 commits into from Jan 26, 2017
Merged

Render news article format #232

merged 6 commits into from Jan 26, 2017

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Jan 18, 2017

Tests will fail until the schema and examples have been merged and deployed: alphagov/govuk-content-schemas#488

  • Render the news article format, with each of its sub-types: news_story, press_release and government_response (identical except for the title context provided by document_type)
  • Includes a couple of fixes for world location news article
  • Allow news and world location news to be translated rtl
  • Fix rtl rendering of share buttons
Type Old New
News story news_story_old news_story_new
Translated news_story_translated_old news_story_translated_new
History mode news_story_history_mode_old news_story_history_mode_new

https://trello.com/c/Jse0oAvr/575-news-article-migration-1-mvp-content-schema-examples-and-front-end-work

fofr added 5 commits Jan 17, 2017
Run: `bundle exec rails generate news_article`
These are provided by the base layout now
* Contents aren’t used
* Withdrawable is provided in the ContentItemPresenter
* Use valid CSS selector in test
@boffbowsh boffbowsh temporarily deployed to government-frontend-pr-232 Jan 18, 2017 Inactive
@fofr fofr force-pushed the news-articles branch from b70d4da to 500ea2b Jan 18, 2017
@boffbowsh boffbowsh temporarily deployed to government-frontend-pr-232 Jan 18, 2017 Inactive
@fofr fofr force-pushed the news-articles branch from 500ea2b to 4e41ee7 Jan 18, 2017
@boffbowsh boffbowsh temporarily deployed to government-frontend-pr-232 Jan 18, 2017 Inactive
.direction-rtl & {
.share-button-link {
// By changing the link to inline-block the browser
// calculate’s the icon and the text as a single run of text

This comment has been minimized.

@gpeng

gpeng Jan 23, 2017
Contributor

calculate's -> calculates

This comment has been minimized.

@fofr

fofr Jan 24, 2017
Author Contributor

😱

This comment has been minimized.

@fofr

fofr Jan 24, 2017
Author Contributor

Fixed

Copy link
Contributor

@bevanloon bevanloon left a comment

LGTM pending the errant apostrophe found by Graham.

When text-direction is set to right-to-left, the inline-block icons get
split weirdly, creating one link that wraps another.

On rtl set the container to inline-block, this treats the whole block
as a single run of text, rather than two. That prevents the link from
being split.

Also clean up the margins
@gpeng
gpeng approved these changes Jan 24, 2017
@fofr fofr merged commit 7317c83 into master Jan 26, 2017
1 check passed
1 check passed
continuous-integration/jenkins/branch This commit looks good
Details
@fofr fofr deleted the news-articles branch Jan 26, 2017
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.