Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Info boxes template added as .sass and .lsg

Inga Mai52e9279fd1b8
diff --git a/app/assets/stylesheets/content/_enterprise.sass b/app/assets/stylesheets/content/_enterprise.sass
index a48f0373862..0aa7f2cdd04 100644
--- a/app/assets/stylesheets/content/_enterprise.sass
+++ b/app/assets/stylesheets/content/_enterprise.sass
@@ -13,12 +13,4 @@
.token-form textarea
font-family: "Lucida Console", Monaco, monospace
- max-width: 560px
-
-.upsale-benefits
- list-style: none
- display: flex
- margin: 0
- li
- margin: 15px
-
+ max-width: 560px
\ No newline at end of file
diff --git a/app/assets/stylesheets/content/_index.sass b/app/assets/stylesheets/content/_index.sass
index e4c9c2235ad..a9ced1ece00 100644
--- a/app/assets/stylesheets/content/_index.sass
+++ b/app/assets/stylesheets/content/_index.sass
@@ -26,6 +26,7 @@
@import content/icon_control
@import content/drag_and_drop
@import content/boxes
+@import content/info_boxes
@import content/headings
@import content/watchers
@import content/simple_filters
diff --git a/app/assets/stylesheets/content/_info_boxes.lsg b/app/assets/stylesheets/content/_info_boxes.lsg
new file mode 100644
index 00000000000..25bd2f8cb95
--- /dev/null
+++ b/app/assets/stylesheets/content/_info_boxes.lsg
@@ -0,0 +1,68 @@
+# Info boxes
+
+## Simple info boxes
+```
+<div class="info-boxes">
+ <h2>Heading</h2>
+ <div class="info-boxes--container">
+ <div class="info-boxes--item">
+ <header>
+ <h3>Box 1</h3>
+ </header>
+ <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</p>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <h3>Box 2</h3>
+ </header>
+ <p>Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.</p>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <h3>Box 3</h3>
+ </header>
+ <p>Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.</p>
+ </div>
+ </div>
+</div>
+```
+
+## Centered with image and links
+```
+<div class="info-boxes -centered">
+ <h2>Heading</h2>
+ <div class="info-boxes--container">
+ <div class="info-boxes--item">
+ <header>
+ <img src="https://via.placeholder.com/250x200" class="info-boxes--teaser-image">
+ <h3>Box 1</h3>
+ </header>
+ <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</p>
+ <ul class="widget-box--arrow-links">
+ <li><a>Learn more</a></li>
+ </ul>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <img src="https://via.placeholder.com/250x200" class="info-boxes--teaser-image">
+ <h3>Box 2</h3>
+ </header>
+ <p>Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.</p>
+ <ul class="widget-box--arrow-links">
+ <li><a>Learn more</a></li>
+ <li><a>Another link</a></li>
+ </ul>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <img src="https://via.placeholder.com/250x200" class="info-boxes--teaser-image">
+ <h3>Box 3</h3>
+ </header>
+ <p>Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.</p>
+ <ul class="widget-box--arrow-links">
+ <li><a>Learn more</a></li>
+ </ul>
+ </div>
+ </div>
+</div>
+```
\ No newline at end of file
diff --git a/app/assets/stylesheets/content/_info_boxes.sass b/app/assets/stylesheets/content/_info_boxes.sass
new file mode 100644
index 00000000000..cebb5eebbf8
--- /dev/null
+++ b/app/assets/stylesheets/content/_info_boxes.sass
@@ -0,0 +1,49 @@
+//-- copyright
+// OpenProject is an open source project management software.
+// Copyright (C) 2012-2020 the OpenProject GmbH
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License version 3.
+//
+// OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:
+// Copyright (C) 2006-2017 Jean-Philippe Lang
+// Copyright (C) 2010-2013 the ChiliProject Team
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License
+// as published by the Free Software Foundation; either version 2
+// of the License, or (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+// See docs/COPYRIGHT.rdoc for more details.
+//++
+
+.info-boxes
+ width: 100%
+ max-width: 1000px
+ h2
+ margin: 15px auto
+ .info-boxes--container
+ display: grid
+ grid-gap: 20px
+ grid-template-columns: repeat(auto-fit,minmax(200px,1fr))
+ header
+ .info-boxes--teaser-image
+ padding: 0 30px 15px 30px
+ h3
+ white-space: nowrap
+ font-weight: bold
+ &.-centered
+ max-width: 1140px
+ margin: auto
+ padding: 0 15px
+ h2
+ text-align: center
\ No newline at end of file
diff --git a/app/views/enterprises/_info.html.erb b/app/views/enterprises/_info.html.erb
index 02c14281dc1..80d40fa0175 100644
--- a/app/views/enterprises/_info.html.erb
+++ b/app/views/enterprises/_info.html.erb
@@ -34,29 +34,48 @@ See docs/COPYRIGHT.rdoc for more details.
<enterprise></enterprise>
-<ul class="upsale-benefits">
- <li>
- <p>
- <b><%= t('js.admin.enterprise.upsale.benefits.installation') %></b>
- </p>
- <p><%= t('js.admin.enterprise.upsale.benefits.installation_text') %></p>
- </li>
- <li>
- <p>
- <b><%= t('js.admin.enterprise.upsale.benefits.professional_support') %></b>
- </p>
- <p><%= t('js.admin.enterprise.upsale.benefits.professional_support_text') %></p>
- </li>
- <li>
- <p>
- <b><%= t('js.admin.enterprise.upsale.benefits.premium_features') %></b>
- </p>
- <p><%= t('js.admin.enterprise.upsale.benefits.premium_features_text') %></p>
- </li>
- <li>
- <p>
- <b><%= t('js.admin.enterprise.upsale.benefits.high_security') %></b>
- </p>
- <p><%= t('js.admin.enterprise.upsale.benefits.high_security_text') %></p>
- </li>
-</ul>
+<div class="info-boxes upsale-benefits">
+ <h2>What are the benefits</h2>
+ <div class="info-boxes--container">
+ <div class="info-boxes--item">
+ <header>
+ <%= image_tag "", class: "info-boxes--teaser-image" %>
+ <h3><%= t('js.admin.enterprise.upsale.benefits.installation') %></h3>
+ </header>
+ <p><%= t('js.admin.enterprise.upsale.benefits.installation_text') %></p>
+ <ul class="widget-box--arrow-links">
+ <li><a><%= t('js.label_learn_more_link') %></a></li>
+ </ul>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <%= image_tag "", class: "info-boxes--teaser-image" %>
+ <h3><%= t('js.admin.enterprise.upsale.benefits.professional_support') %></h3>
+ </header>
+ <p><%= t('js.admin.enterprise.upsale.benefits.professional_support_text') %></p>
+ <ul class="widget-box--arrow-links">
+ <li><a><%= t('js.label_learn_more_link') %></a></li>
+ </ul>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <%= image_tag "", class: "info-boxes--teaser-image" %>
+ <h3><%= t('js.admin.enterprise.upsale.benefits.premium_features') %></h3>
+ </header>
+ <p><%= t('js.admin.enterprise.upsale.benefits.premium_features_text') %></p>
+ <ul class="widget-box--arrow-links">
+ <li><a><%= t('js.label_learn_more_link') %></a></li>
+ </ul>
+ </div>
+ <div class="info-boxes--item">
+ <header>
+ <%= image_tag "", class: "info-boxes--teaser-image" %>
+ <h3><%= t('js.admin.enterprise.upsale.benefits.high_security') %></h3>
+ </header>
+ <p><%= t('js.admin.enterprise.upsale.benefits.high_security_text') %></p>
+ <ul class="widget-box--arrow-links">
+ <li><a><%= t('js.label_learn_more_link') %></a></li>
+ </ul>
+ </div>
+ </div>
+</div>
diff --git a/config/locales/js-en.yml b/config/locales/js-en.yml
index 4f688c4cd32..e28921cbd89 100644
--- a/config/locales/js-en.yml
+++ b/config/locales/js-en.yml
@@ -351,6 +351,7 @@ en:
label_import: "Import"
label_latest_activity: "Latest activity"
label_last_updated_on: "Last updated on"
+ label_learn_more_link: "Learn more"
label_less_or_equal: "<="
label_less_than_ago: "less than days ago"
label_loading: "Loading..."
diff --git a/frontend/src/app/components/enterprise/enterprise-modal/enterprise-trial.modal.html b/frontend/src/app/components/enterprise/enterprise-modal/enterprise-trial.modal.html
index 88720d63d00..6eee520b15d 100644
--- a/frontend/src/app/components/enterprise/enterprise-modal/enterprise-trial.modal.html
+++ b/frontend/src/app/components/enterprise/enterprise-modal/enterprise-trial.modal.html
@@ -66,7 +66,7 @@
</div>
<div class="form--field -required">
<div class="form--field-container">
- <label class="form--label-with-check-box">
+ <label class="form--label-with-check-box -no-ellipsis">
<div class="form--check-box-container">
<input type="checkbox"
class="form--check-box"
@@ -86,7 +86,7 @@
</div>
<div class="form--field">
<div class="form--field-container">
- <label class="form--label-with-check-box">
+ <label class="form--label-with-check-box -no-ellipsis">
<div class="form--check-box-container">
<input type="checkbox"
class="form--check-box"