Skip to content

Commit

Permalink
Merge pull request #779 from rubyforgood/add-css-for-custom-text
Browse files Browse the repository at this point in the history
Start of css to be applied to all custom text (user submitted)
  • Loading branch information
maebeale authored Oct 12, 2020
2 parents 5f6d17d + 5b11e0d commit a44ba94
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 7 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ We're still in the [initial development phase](https://www.jering.tech/articles/

This changelog also serves to acknowledge the incredible people who've contributed brilliance, effort and being. Their handles are listed under the first release they each touched. 💗🙏🏾

## [Unreleased]
* Unordered lists in user provided custom text (eg /about) now display with discs ('bullets') #777, #779

## [0.3.0] - 2020-10-05
### Breaking changes
Expand Down
2 changes: 2 additions & 0 deletions app/assets/stylesheets/application.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
@import './yearbook'; // TODO: remove this once listings/new is refactored
@import './listings'; // TODO: remove this once listings/new is refactored

@import './custom_text';

@import './mapbox-gl';
@import './maps';

Expand Down
6 changes: 6 additions & 0 deletions app/assets/stylesheets/custom_text.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.custom-text {
// Bulma strips list-style from ol, ul by default
ul {
list-style: disc inside;
}
}
8 changes: 4 additions & 4 deletions app/javascript/pages/orientation/AboutSection.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<div class='section'>
<div class='section custom-text'>
<h2 class='subtitle'>{{title}}</h2>
<p v-html="description" class='description'></p>
</div>
Expand All @@ -8,8 +8,8 @@
<script>
export default {
props:{
title:{type: String, default:"This is a placeholder!"},
description:{type: String, default:"Put descriptive things about this section here"}
title: {type: String, default: "This is a placeholder!"},
description: {type: String, default: "Put descriptive things about this section here"}
},
}
</script>
</script>
4 changes: 2 additions & 2 deletions app/views/contributions/thank_you.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<%= @current_organization&.name %>
</div>

<div class="header">
<div class="header custom-text">
<%= HtmlSanitizer.new(@system_setting.confirmation_page_text_header).sanitize_for_rails %>
</div>

Expand Down Expand Up @@ -34,7 +34,7 @@
</div>
</div>

<div class="footer">
<div class="footer custom-text">
<%= HtmlSanitizer.new(@system_setting.confirmation_page_text_footer).sanitize_for_rails %>
</div>

4 changes: 3 additions & 1 deletion app/views/public/about.html.erb
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
<%= @about_us_text.present? ? @about_us_text : "Some more info about us..." %>
<div class="custom-text">
<%= @about_us_text.present? ? @about_us_text : "Some more info about us..." %>
</div>

0 comments on commit a44ba94

Please sign in to comment.