Skip to content

Commit 0196aff

Browse files
Merge pull request #66 from alanocallaghan/slide-refactor
Slide refactor
2 parents 8addd9e + c7525c4 commit 0196aff

File tree

12 files changed

+42
-28
lines changed

12 files changed

+42
-28
lines changed

_config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ repository: qupath/qupath.github.io
99
collections:
1010
slides:
1111
_hide_content: true
12+
sort_by: priority

_includes/footer.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<footer>
33
<p class="footer-text">{{page.footer-1 }}
44
<p class="footer-text">{{page.footer-2 }}
5+
<p class="footer-text">{{page.footer-3 }}
56
</p>
67
<hr>
78
</hr>

_includes/slideshow.html

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
<!-- Slideshow component -->
22
<div class="slideshow-container standard-component">
33
<!-- Full-width images with number and caption text -->
4-
{% for slide in site.slides %}
4+
5+
{% assign slides_list = site.slides | sort:"priority" %}
6+
{% for slide in slides_list %}
7+
{% unless slide.hide %}
58
<div class="mySlides fade">
69
<div class="slide">
710
<div class="slide-text {{ slide.slide-text-class }}">
@@ -11,6 +14,7 @@ <h2>{{slide.slide-title }}</h2>
1114
<img src="{{ slide.slide-img }}" class="{{ slide.slide-img-class }}" alt="">
1215
</div>
1316
</div>
17+
{% endunless %}
1418
{% endfor %}
1519

1620
<!-- Next and previous buttons -->
@@ -22,9 +26,9 @@ <h2>{{slide.slide-title }}</h2>
2226
<br>
2327
<!-- The dots/circles -->
2428
<div style="text-align:center">
25-
<span class="dot" onclick="currentSlide(1)" tabindex="0"></span>
26-
<span class="dot" onclick="currentSlide(2)" tabindex="0"></span>
27-
<span class="dot" onclick="currentSlide(3)" tabindex="0"></span>
28-
<span class="dot" onclick="currentSlide(4)" tabindex="0"></span>
29-
<span class="dot" onclick="currentSlide(5)" tabindex="0"></span>
30-
</div>
29+
{% for slide in site.slides | sort:"priority" | reversed %}
30+
{% unless slide.hide %}
31+
<span class="dot" onclick="currentSlide({{ forloop.index }})" tabindex="0"></span>
32+
{% endunless %}
33+
{% endfor %}
34+
</div>

_sass/_base.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
min-width: 330px;
113113
margin-bottom: 50px;
114114
border-radius: 0px 0px 10px 10px;
115-
background-color: var(--banner-red);
115+
background-color: var(--banner-blue);
116116
}
117117

118118
div.news-banner-text {
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@ slide-title: Annotate faster
33
slide-content: QuPath has lots of tricks to annotate images quickly. See them in action in this <a href="https://twitter.com/petebankhead/status/1295965136646176768?s=20 t=ETG2R8JKrhtT-kSZdW-Cnw" target=blank >annotation tweetorial</a>.
44
slide-img: /assets/images/slideshow/annotation-snapping.jpg
55
slide-img-class: screenshot-img
6-
---
6+
priority: 5
7+
---
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@
22
slide-title: Understand images
33
slide-content: Learn the core ideas behind analyzing images from QuPath’s creator, in the new interactive handbook <a href="https://bioimagebook.github.io/README.html" target=blank>Introduction to Bioimage Analysis</a>.
44
slide-img: /assets/images/slideshow/pete-teaching.png
5-
---
5+
priority: 6
6+
hide: true
7+
---
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@ slide-title: Get started
33
slide-content: See how QuPath can help visualize & analyze complex images with our step-by-step guides on <a href="https://qupath.readthedocs.io/en/stable/" target=blank>ReadTheDocs</a>.
44
slide-img: /assets/images/slideshow/qupath-getting-started.png
55
slide-img-class: screenshot-img
6-
---
6+
priority: 3
7+
---
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ slide-content: Dive deeper into what QuPath can do by checking out the tutorials
44
slide-img: /assets/images/slideshow/qupath-youtube.png
55
slide-img-class: inverse screenshot-img
66
slide-text-class: inverse-text
7-
---
7+
priority: 4
8+
---

_slides/slide1.md

Lines changed: 0 additions & 7 deletions
This file was deleted.

_slides/v0-6-0.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
slide-title: v0.6.0 has arrived!
3+
slide-content: <br> Learn about the many new features and improvements in the <a href="https://forum.image.sc/t/qupath-v0-6-0-now-available/114104"target=blank>detailed release notes</a>.
4+
slide-img: /assets/images/slideshow/qupath-jobs.png
5+
slide-img-class: inverse
6+
slide-text-class: inverse-text
7+
priority: 1
8+
---

0 commit comments

Comments
 (0)