Skip to content

Commit

Permalink
Allow speeches to be translated
Browse files Browse the repository at this point in the history
* Metadata module added in right-to-left support
* Add right to left styling for speeches (matches case-studies approach)
  • Loading branch information
fofr committed Jan 5, 2017
1 parent 4ca1e83 commit 579fdef
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions app/assets/stylesheets/views/_speech.scss
Expand Up @@ -3,4 +3,9 @@
@include description;
@include history-notice;
@include withdrawal-notice;

.direction-rtl & {
direction: rtl;
text-align: start;
}
}
8 changes: 8 additions & 0 deletions test/integration/speech_test.rb
Expand Up @@ -9,6 +9,14 @@ class SpeechTest < ActionDispatch::IntegrationTest
assert_has_component_govspeak(@content_item["details"]["body"])
end

test "translated speech" do
setup_and_visit_content_item('speech-translated')

assert_has_component_title(@content_item["title"])
assert page.has_text?(@content_item["description"])
assert page.has_css?('.available-languages')
end

test "renders metadata and document footer, including speaker" do
setup_and_visit_content_item('speech')

Expand Down

0 comments on commit 579fdef

Please sign in to comment.