Skip to content

Commit edd223b

Browse files
authored
[PYT-152] Wire up external Ecosystem cards (#45)
1 parent c201799 commit edd223b

File tree

7 files changed

+22
-28
lines changed

7 files changed

+22
-28
lines changed

_ecosystem/detectron.md

+2-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,7 @@
11
---
22
layout: ecosystem_detail
33
title: Detectron
4-
slug: detectron
54
summary: A Pytorch Implementation of Detectron
6-
background-class: ecosystem-background
7-
body-class: ecosystem ecosystem-detail
8-
call-to-action: Try via CoLab
5+
external: true
6+
link: https://github.com/roytseng-tw/Detectron.pytorch
97
---
10-
11-
## Detectron
12-
13-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

_ecosystem/elf.md

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
---
22
layout: ecosystem_detail
33
title: ELF
4-
slug: elf
54
summary: Extensive, Lightweight, and Flexible platform for game research
65
background-class: ecosystem-background
76
body-class: ecosystem ecosystem-detail

_ecosystem/parlai.md

+2-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,7 @@
11
---
22
layout: ecosystem_detail
33
title: ParlAI
4-
slug: parlai
54
summary: Framework for dialog AI research, implemented in Python
6-
background-class: ecosystem-background
7-
body-class: ecosystem ecosystem-detail
8-
call-to-action: Try via CoLab
5+
external: true
6+
link: http://www.parl.ai/
97
---
10-
11-
## ParlAI
12-
13-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

_ecosystem/wav2letter.md

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
---
22
layout: ecosystem_detail
33
title: Wav2Letter
4-
slug: wav2letter
54
summary: Simple and efficient end-to-end Automatic Speech Recognition (ASR) system from Facebook AI Research
65
background-class: ecosystem-background
76
body-class: ecosystem ecosystem-detail

_sass/base_styles.scss

+6-6
Original file line numberDiff line numberDiff line change
@@ -436,20 +436,20 @@ a, .btn {
436436
background-repeat: no-repeat;
437437
padding: rem(25px) rem(30px);
438438

439-
&.detectron {
440-
background-image: url($baseurl + "/assets/images/logo-detectron.svg");
441-
background-size: 24px 24px;
439+
&.external {
442440
h4 {
443441
@include external_link_icon
444442
}
445443
}
446444

445+
&.detectron {
446+
background-image: url($baseurl + "/assets/images/logo-detectron.svg");
447+
background-size: 24px 24px;
448+
}
449+
447450
&.elf {
448451
background-image: url($baseurl + "/assets/images/logo-elf.svg");
449452
background-size: 29px 25px;
450-
h4 {
451-
@include external_link_icon
452-
}
453453
}
454454

455455
&.parlai {

ecosystem.html

+6-2
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,12 @@ <h1>Ecosystem</h1>
6767
{% for item in site.ecosystem %}
6868
<div class="col-md-6 ecosystem-card-wrapper" data-categories="{{ item.category | join: "," }}">
6969
<div class="card ecosystem-card">
70-
<a href="{{ site.baseurl }}{{ item.url }}">
71-
<div class="card-body {{ item.slug }}">
70+
{% if item.external %}
71+
<a href="{{ item.link }}" target="_blank">
72+
{% else %}
73+
<a href="{{ site.baseurl }}{{ item.url }}">
74+
{% endif %}
75+
<div class="card-body {{ item.title | slugify }} {% if item.external %}external{% endif %}">
7276
<h4>{{ item.title }}</h4>
7377
<p class="card-summary">{{ item.summary }}</p>
7478
</div>

index.html

+6-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,12 @@ <h2>Showcased Projects </h2>
6161
{% for item in site.ecosystem limit:3 %}
6262
<div class="col-md-4">
6363
<div class="card ecosystem-card">
64-
<a href="{{ site.baseurl }}{{ item.url }}">
65-
<div class="card-body {{ item.slug }}">
64+
{% if item.external %}
65+
<a href="{{ item.link }}" target="_blank">
66+
{% else %}
67+
<a href="{{ site.baseurl }}{{ item.url }}">
68+
{% endif %}
69+
<div class="card-body {{ item.title | slugify }} {% if item.external %}external{% endif %}">
6670
<h4>{{ item.title }}</h4>
6771
<p class="card-summary">{{ item.summary }}</p>
6872
</div>

0 commit comments

Comments
 (0)