[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [community/master] Add revealjs slides



commit 07c503c8a2127b787d2a83d15f30ba7d88ed2969
Author: hiro <hiro@xxxxxxxxxxxxxx>
Date:   Wed Feb 17 18:44:00 2021 +0100

    Add revealjs slides
---
 .gitmodules                                        |  1 +
 .../training/resources/tor-training/contents.lr    | 78 ++++++++++++++++++++--
 flowblocks/slide.ini                               | 21 ++++++
 lego                                               |  2 +-
 models/{slide.ini => slideshow.ini}                | 16 +++--
 templates/blocks/slide.html                        |  5 ++
 templates/{slide.html => slideshow.html}           | 52 ++++++++-------
 7 files changed, 141 insertions(+), 34 deletions(-)

diff --git a/.gitmodules b/.gitmodules
index d246c46..e8f1eb4 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -1,3 +1,4 @@
 [submodule "lego"]
 	path = lego
 	url = https://git.torproject.org/project/web/lego.git
+	branch = master
diff --git a/content/training/resources/tor-training/contents.lr b/content/training/resources/tor-training/contents.lr
index fc3af25..d50603d 100644
--- a/content/training/resources/tor-training/contents.lr
+++ b/content/training/resources/tor-training/contents.lr
@@ -1,11 +1,81 @@
-_model: slide
+_model: slideshow
 ---
 title: Tor Presentation
 ---
-_template: slide.html
+_template: slideshow.html
 ---
 subtitle: Teach your community about using Tor
 ---
-body:
+author: Community Team
+---
+background: white
+---
+image: /static/images/onion-bg.png
+---
+slides:
+
+#### slide ####
+title: Hello Slideshow
+----
+description: Test slides
+----
+background: white
+
+#### slide ####
+title: Topics
+----
+description:
+
+- Whatâ??s Tor?
+- Types of relays
+- Technical setup
+- More about relays
+- Relay diversity
+- Getting help
+
+----
+background: white
+
+#### slide ####
+title: What's Tor?
+----
+description:
+- Tor is a free software and an open network
+- Mitigates against tracking, surveillance and censorship
+- Run by a US non-profit and volunteers from all over the world
+- Itâ??s Tor, not TOR
+
+----
+background: white
+
+#### slide ####
+title: The Tor network
+----
+description:
+- An open network, everyone can be part of it. Basically, your server will relay the tor traffic to another server in the Internet.
+- The network is composed by different types of servers run by volunteers around the world.
+- To ingress in the network, the new server will pass automatically to a new relay lifecycle.
+----
+background: white
+
+#### slide ####
+title: Why run a Tor relay?
+----
+description:
+By running a Tor relay you can help make the Tor network:
+- faster (and therefore more usable)â??more robust against attacks
+- more stable in case of outages
+- safer for its users (spying on more relays is harder than on a few)
+----
+background: white
 
-welcome
+#### slide ####
+title: Why run a Tor relay?
+----
+description:
+By running a Tor relay you can help make the Tor network:
+- faster (and therefore more usable)â??more robust against attacks
+- more stable in case of outages
+- safer for its users (spying on more relays is harder than on a few)
+----
+background: white
diff --git a/flowblocks/slide.ini b/flowblocks/slide.ini
new file mode 100644
index 0000000..97b1b6b
--- /dev/null
+++ b/flowblocks/slide.ini
@@ -0,0 +1,21 @@
+[block]
+name = Slide
+
+[fields.title]
+label = Title
+type = markdown
+translate = True
+
+[fields.description]
+label = Description
+type = markdown
+translate = True
+
+[fields.image]
+label = Image
+type = select
+source = record.attachments.images
+
+[fields.background]
+label = Background color
+type = string
diff --git a/lego b/lego
index 7bf3403..4cb4064 160000
--- a/lego
+++ b/lego
@@ -1 +1 @@
-Subproject commit 7bf34035e6f44bc243fab1674c38ac81a18fbdbd
+Subproject commit 4cb4064486b300f04573b4dde54afa6835dafa63
diff --git a/models/slide.ini b/models/slideshow.ini
similarity index 70%
rename from models/slide.ini
rename to models/slideshow.ini
index 54f874f..7d0116a 100644
--- a/models/slide.ini
+++ b/models/slideshow.ini
@@ -1,5 +1,5 @@
 [model]
-name = Slide
+name = Slideshow
 label = {{ this.title }}
 
 [fields.title]
@@ -7,6 +7,11 @@ label = Title
 type = string
 translate = True
 
+[fields.description]
+label = Description
+type = string
+translate = True
+
 [fields.author]
 label = Author
 type = string
@@ -16,10 +21,11 @@ label = Subtitle
 type = string
 translate = True
 
-[fields.body]
-label = Body
-type = markdown
-translate = True
+[fields.slides]
+label = Slides
+type = flow
+flow_blocks = slide
+translate = False
 
 [fields.color]
 label = Color
diff --git a/templates/blocks/slide.html b/templates/blocks/slide.html
new file mode 100644
index 0000000..5f96574
--- /dev/null
+++ b/templates/blocks/slide.html
@@ -0,0 +1,5 @@
+<section data-background-color="{{ this.background }}">
+  <h2>{{ this.title }}</h2>
+  {{ this.description }}
+
+</section>
diff --git a/templates/slide.html b/templates/slideshow.html
similarity index 50%
rename from templates/slide.html
rename to templates/slideshow.html
index 982f1cc..64fe9d5 100644
--- a/templates/slide.html
+++ b/templates/slideshow.html
@@ -1,47 +1,51 @@
 <!doctype html>
 <html lang="en">
-
 	<head>
 		<meta charset="utf-8">
-
 		<title>{{ _("Tor Project") }} | {% block title %}{{ this.title }}{% endblock %}</title>
-
-		<meta name="description" content="{{ _(\"Tor Project\") }} | {% block title %}{{ this.title }}{% endblock %}">
+		<meta name="description" content="{{ _('Tor Project') }} | {{ this.description }}">
 		<meta name="author" content="{{ this.author }}">
-
 		<meta name="apple-mobile-web-app-capable" content="yes">
 		<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
-
 		<meta name="viewport" content="width=device-width, initial-scale=1.0">
-
 		<link rel="stylesheet" href="{{ '/static/revealjs/dist/reset.css'|asseturl }}">
 		<link rel="stylesheet" href="{{ '/static/revealjs/dist/reveal.css'|asseturl }}">
-		<link rel="stylesheet" href="{{ '/static/revealjs/dist/theme/black.css'|asseturl }}" id="theme">
-
+		<link rel="stylesheet" href="{{ '/static/revealjs/dist/theme/tor.css'|asseturl }}" id="theme">
 		<!-- Theme used for syntax highlighting of code -->
-		<link rel="stylesheet" href="{{ '/static/revealjs/plugin/highlight/monokai.css|asseturl }}" id="highlight-theme">
+		<link rel="stylesheet" href="{{ '/static/revealjs/plugin/highlight/monokai.css'|asseturl }}" id="highlight-theme">
 	</head>
-
 	<body>
-
-		<div class="reveal">
-
+    <div class="reveal">
 			<!-- Any section element inside of this container is displayed as a slide -->
-      
 			<div class="slides">
-
+				<section data-background-color="{{ this.background }}" data-background-image="{{ this.image|asseturl }}" data-background-position="bottom right" data-background-size="3em">
+				  <h1>{{ this.title }}</h1>
+				  <h2>{{ this.subtitle }}</h2>
+					<p>{{ this.author }}</p>
+				</section>
+
+        {{ this.slides }}
+
+				<div class="footer">
+					<div class="left">
+						<a href="https://torproject.org";>torproject.org</a>
+					</div>
+					<div class="right">
+						<img src="{{ '/static/images/tor-logo/White.png'|asseturl }}">
+					</div>
+				</div>
       </div>
 
-		</div>
+    </div>
 
-		<script src="{{ '/static/revealjs/dist/reveal.js'|asseturl }}"></script>
-		<script src="{{ '/static/revealjs/plugin/zoom/zoom.js'|asseturl }}"></script>
-		<script src="{{ '/static/revealjs/plugin/notes/notes.js'|asseturl }}"></script>
-		<script src="{{ '/static/revealjs/plugin/search/search.js'|asseturl }}"></script>
-		<script src="{{ '/static/revealjs/plugin/markdown/markdown.js'|asseturl }}"></script>
-		<script src="{{ '/static/revealjs/plugin/highlight/highlight.js'|asseturl }}"></script>
-		<script>
+    <script src="{{ '/static/revealjs/dist/reveal.js'|asseturl }}"></script>
+    <script src="{{ '/static/revealjs/plugin/zoom/zoom.js'|asseturl }}"></script>
+    <script src="{{ '/static/revealjs/plugin/notes/notes.js'|asseturl }}"></script>
+    <script src="{{ '/static/revealjs/plugin/search/search.js'|asseturl }}"></script>
+    <script src="{{ '/static/revealjs/plugin/markdown/markdown.js'|asseturl }}"></script>
+    <script src="{{ '/static/revealjs/plugin/highlight/highlight.js'|asseturl }}"></script>
 
+		<script>
 			// Also available as an ES module, see:
 			// https://revealjs.com/initialization/
 			Reveal.initialize({

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits