You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by pa...@apache.org on 2022/12/02 20:40:41 UTC

[beam] branch master updated: [Website] add coauthor option to case-studies #24486 (#24475)

This is an automated email from the ASF dual-hosted git repository.

pabloem pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new 53bcb39378e [Website] add coauthor option to case-studies #24486 (#24475)
53bcb39378e is described below

commit 53bcb39378ed2fdcd4ca24d7aa94d7f68a683b6f
Author: bullet03 <bu...@akvelon.com>
AuthorDate: Sat Dec 3 02:40:34 2022 +0600

    [Website] add coauthor option to case-studies #24486 (#24475)
---
 website/ADD_CASE_STUDY.md                       | 27 ++++++++++--------
 website/www/site/assets/scss/_case_study.scss   | 11 ++++++--
 website/www/site/layouts/case-studies/list.html | 37 +++++++++++++++++++------
 3 files changed, 52 insertions(+), 23 deletions(-)

diff --git a/website/ADD_CASE_STUDY.md b/website/ADD_CASE_STUDY.md
index 079cedf7be6..75effd0ceca 100644
--- a/website/ADD_CASE_STUDY.md
+++ b/website/ADD_CASE_STUDY.md
@@ -28,18 +28,21 @@ If you have any questions about adding a case study, please send an email to dev
 
 Following properties determine how your case-study will looks on [Apache Beam case studies](https://beam.apache.org/case-studies/) listing and the case study page itself.
 
-| Field             | Description                                                                                             |
-|-------------------|---------------------------------------------------------------------------------------------------------|
-| `title`           | Case study title, usually 4-12 words                                                                    |
-| `name`            | Company or project name                                                                                 |
-| `icon`            | Relative path to the company/project logo e.g. "/images/logos/powered-by/company_name.png"              |
-| `category`        | `study` for case studies                                                                                |
-| `cardTitle`       | Case study card title for Apache Beam [case studies](https://beam.apache.org/case-studies/) page        |
-| `cardDescription` | Description for [case studies](https://beam.apache.org/case-studies/) page, usually 30-40 words         |
-| `authorName`      | Case study author                                                                                       |
-| `authorPosition`  | Case study author role                                                                                  |
-| `authorImg`       | Relative path for case study author photo, e.g. "/images/case-study/company/authorImg.png"              |
-| `publishDate`     | Case study publish date for sorting at [case studies](https://beam.apache.org/case-studies/), e.g. `2022-10-14T01:56:00+00:00` |
+| Field                 | Description                                                                                                                    |
+|-----------------------|--------------------------------------------------------------------------------------------------------------------------------|
+| `title`               | Case study title, usually 4-12 words                                                                                           |
+| `name`                | Company or project name                                                                                                        |
+| `icon`                | Relative path to the company/project logo e.g. "/images/logos/powered-by/company_name.png"                                     |
+| `category`            | `study` for case studies                                                                                                       |
+| `cardTitle`           | Case study card title for Apache Beam [case studies](https://beam.apache.org/case-studies/) page                               |
+| `cardDescription`     | Description for [case studies](https://beam.apache.org/case-studies/) page, usually 30-40 words                                |
+| `authorName`          | Case study author                                                                                                              |
+| `coauthorName`        | Case study additional author, optional param                                                                                   |
+| `authorPosition`      | Case study author role                                                                                                         |
+| `coauthorPosition`    | Case study additional author role, optional param                                                                              |
+| `authorImg`           | Relative path for case study author photo, e.g. "/images/case-study/company/authorImg.png"                                     |
+| `coauthorImg`         | Relative path for case study second author photo, e.g. "/images/case-study/company/authorImg.png", optional param              |
+| `publishDate`         | Case study publish date for sorting at [case studies](https://beam.apache.org/case-studies/), e.g. `2022-10-14T01:56:00+00:00` |
 
 Other sections of the [case study md template](https://github.com/apache/beam/blob/master/website/CASE_STUDY_TEMPLATE.md) are organized to present the case study content.
 
diff --git a/website/www/site/assets/scss/_case_study.scss b/website/www/site/assets/scss/_case_study.scss
index bcbd184a16b..72c7ce3d94a 100644
--- a/website/www/site/assets/scss/_case_study.scss
+++ b/website/www/site/assets/scss/_case_study.scss
@@ -24,7 +24,6 @@
 
 .case-study-list {
   display: flex;
-  align-items: center;
   flex-wrap: wrap;
   gap: 2%;
   margin-bottom: 16px;
@@ -159,6 +158,14 @@
     align-items: center;
     justify-content: space-between;
   }
+
+  .quote-block-wrapper {
+    padding-top: 15px;
+    height: 120px;
+    display: flex;
+    flex-direction: column;
+    justify-content: center;
+  }
 }
 
 .case-study-row-button-container {
@@ -199,7 +206,7 @@ h2.case-study-h2 {
 }
 
 .case-study-quote-block {
-  padding: 0;
+  padding: 5px 0 50px 0;
   border-left: 0;
 
   .case-study-quote-text {
diff --git a/website/www/site/layouts/case-studies/list.html b/website/www/site/layouts/case-studies/list.html
index d4eb6a77b0b..c609d56f468 100644
--- a/website/www/site/layouts/case-studies/list.html
+++ b/website/www/site/layouts/case-studies/list.html
@@ -24,20 +24,39 @@ limitations under the License. See accompanying LICENSE file.
             </div>
             <h3 class="case-study-card-title">{{ .Params.cardTitle }}</h3>
             <p class="case-study-card-description">{{ .Params.cardDescription }}</p>
-            <div class="case-study-quote-block">
-                <div class="case-study-quote-author">
-                    <div class="case-study-quote-author-img">
-                        <img src="{{ .Params.authorImg }}">
+            <div class="quote-block-wrapper">
+                <div class="case-study-quote-block">
+                    <div class="case-study-quote-author">
+                        <div class="case-study-quote-author-img">
+                            <img src="{{ .Params.authorImg }}">
+                        </div>
+                        <div class="case-study-quote-author-info">
+                            <div class="case-study-quote-author-name">
+                                {{ .Params.authorName }}
+                            </div>
+                            <div class="case-study-quote-author-position">
+                                {{ .Params.authorPosition }}
+                            </div>
+                        </div>
                     </div>
-                    <div class="case-study-quote-author-info">
-                        <div class="case-study-quote-author-name">
-                            {{ .Params.authorName }}
+                </div>
+                {{ if .Params.coauthorName }}
+                <div class="case-study-quote-block">
+                    <div class="case-study-quote-author case-study-quote-author--end">
+                        <div class="case-study-quote-author-img">
+                            <img src="{{ .Params.coauthorImg }}">
                         </div>
-                        <div class="case-study-quote-author-position">
-                            {{ .Params.authorPosition }}
+                        <div class="case-study-quote-author-info case-study-quote-author-info--end">
+                            <div class="case-study-quote-author-name">
+                                {{ .Params.coauthorName }}
+                            </div>
+                            <div class="case-study-quote-author-position">
+                                {{ .Params.coauthorPosition }}
+                            </div>
                         </div>
                     </div>
                 </div>
+                {{ end }}
             </div>
             <a class="case-study-card-learn-more" href="{{ .RelPermalink }}">
                 <span>{{ T "case-studies-learn-more" }}</span>