askclass-course-theme 0.9.0 → 0.11.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 58556eda0ec2b4f641cdeb7abdbf4a342935a059d18b92097a8432b14e1140e4
4
- data.tar.gz: dc1d7bd7ffcd8531f1fff6aadb7365565eee993c87c71b766cb6119654568f4c
3
+ metadata.gz: ad415f673871488c829c0bdbfa89be7e3ff9f892c2f3200f725a11926e89d428
4
+ data.tar.gz: 6a64b6a2420b29a6d511933644937c7ed49614d781fc787c215506c77d8faf5a
5
5
  SHA512:
6
- metadata.gz: 92d67474765579b087fecbe2a02a25fec3fadb2ea4bf5969a66f58333e6d629b3ddeb594c1cc3d58727d486f5ba5e5ca5bce120a7a25759e248a294529dfd82d
7
- data.tar.gz: da5f36fa59a4cef5ca886f1556b076874436060988e1ad3157fdc76042a21c165d2081a085322ee7334f17ac47d24d8c38740accd90ccb5e5126e4efc11f9527
6
+ metadata.gz: 924742638712d060a2555c0f14e642a9d5b43de26327fa55173ee2cb712e14654fcb62d5a12717527d77bde53439679c6a24a908e5d0d4df278324118717a70b
7
+ data.tar.gz: 6d4e3fba3a8e1ec59e302b5e0511a63f91aec08dc951735d9d018e832a00921997c69412def98e085de22020af52b4af357d1182209365b86ae3d5f7701d2876
@@ -13,13 +13,12 @@
13
13
  window.onscroll = () => {
14
14
  const top = window.pageYOffset;
15
15
  if (window.innerHeight + top >= document.body.offsetHeight - 2) {
16
- e.style.opacity = 1;
17
- e.style.top = 'unset';
18
- e.style.bottom = '70px';
16
+ e.classList.add('bottom');
17
+ } else if (top > 100) {
18
+ e.classList.remove('bottom');
19
+ e.classList.add('fixed');
19
20
  } else {
20
- e.style.top = '5px';
21
- e.style.bottom = 'unset';
22
- e.style.opacity = top > 100 ? 0.5 : 1;
21
+ e.classList.remove('fixed');
23
22
  }
24
23
  }
25
24
  </script>
@@ -0,0 +1,6 @@
1
+ <div class="video-background">
2
+ <iframe sandbox="allow-same-origin allow-scripts allow-popups allow-forms"
3
+ src="{{ include.src }}"
4
+ frameborder="0"
5
+ allowfullscreen></iframe>
6
+ </div>
@@ -1,4 +1,4 @@
1
- <section class="center-align special spacer">
1
+ <section class="center-align special">
2
2
  {%- if session_data.header -%}
3
3
  <div>{{ session_data.header }}</div>
4
4
  {%- endif -%}
@@ -9,21 +9,31 @@
9
9
  {%- assign _next_segment = segment_data.items[_nidx] -%}
10
10
  {%- assign _next_item = site.data.sessions[_next_segment] -%}
11
11
 
12
+ {%- unless _next_item -%}
13
+ {%- assign _next_segment = site.data.syllabus[next].items[0] -%}
14
+ {%- assign _next_item = site.data.sessions[_next_segment] -%}
15
+ {%- endunless -%}
16
+
12
17
  {%- if _index > 0 -%}
13
18
  {%- assign _pidx = _index | minus: 1 -%}
14
19
  {%- assign _prev_segment = segment_data.items[_pidx] -%}
15
20
  {%- assign _prev_item = site.data.sessions[_prev_segment] -%}
16
21
  {%- endif -%}
17
22
 
23
+ {%- unless _prev_item -%}
24
+ {%- assign _prev_segment = site.data.syllabus[prev].items[-1] -%}
25
+ {%- assign _prev_item = site.data.sessions[_prev_segment] -%}
26
+ {%- endunless -%}
27
+
18
28
  <section class="spacer center-align">
19
29
 
20
30
  {%- include segment/nav.html segment=session_data.segment -%}
21
- <div>
31
+ <center>
22
32
  {%- if session_data.header -%}
23
- {{ session_data.header }} &bull;&nbsp;
33
+ <small>{{ session_data.header }}</small><br/>
24
34
  {%- endif -%}
25
35
  {{ session_data.title }}
26
- </div>
36
+ </center>
27
37
 
28
38
  <div class="paginator-container spacer">
29
39
  {%- include session/next_prev.html p="previous" item=_prev_item -%}
@@ -1,5 +1,9 @@
1
1
  {% for v in include.videos %}
2
- {% include session/youtube.html id=v %}
2
+ {% if v contains '://' %}
3
+ {% include session/googledrive.html src=v %}
4
+ {% else %}
5
+ {% include session/youtube.html id=v %}
6
+ {% endif %}
3
7
  {% assign _size = include.videos | size %}
4
8
  {% if forloop.index != _size %}<hr />{% endif %}
5
9
  {% endfor %}
@@ -6,7 +6,7 @@
6
6
  <html lang="en">
7
7
  {% include header.html %}
8
8
  <body>
9
- {% include logo_static.html size=30 height=30 %}
9
+ {% include logo_static.html size=50 height=50 %}
10
10
  {% include session/header.html %}
11
11
 
12
12
  <section class="center-align spacer content">
data/_sass/_base.scss CHANGED
@@ -125,9 +125,6 @@ sub {
125
125
  align-items: center;
126
126
  text-decoration: none;
127
127
  text-align: center;
128
- img {
129
- margin-right: 5px;
130
- }
131
128
  }
132
129
  @mixin align-center() {
133
130
  display: flex;
@@ -151,17 +148,29 @@ sub {
151
148
  .course-id {
152
149
  @include align-middle();
153
150
  font-family: var(--font-special);
154
- flex-direction: row-reverse;
155
- position: fixed;
156
- top: 5px;
157
- right: 5px;
151
+ flex-direction: column;
158
152
  a {
159
153
  color: var(--color-theme);
160
154
  display: flex;
161
- margin-left: 5px;
155
+ margin: 0 5px;
162
156
  }
163
157
  & a:nth-child(2) {
164
- margin-top: 3px;
158
+ margin: 3px 0;
159
+ }
160
+ &.fixed {
161
+ flex-direction: row-reverse;
162
+ position: fixed;
163
+ right: 5px;
164
+ top: 5px;
165
+ opacity: 0.8;
166
+ img {
167
+ transform: scale(0.6);
168
+ }
169
+ &.bottom {
170
+ opacity: 1;
171
+ bottom: 70px;
172
+ top: unset;
173
+ }
165
174
  }
166
175
  }
167
176
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: askclass-course-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - AskClass
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-19 00:00:00.000000000 Z
11
+ date: 2022-11-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -48,6 +48,7 @@ files:
48
48
  - _includes/segment/index.html
49
49
  - _includes/segment/nav.html
50
50
  - _includes/session/content_revealer.html
51
+ - _includes/session/googledrive.html
51
52
  - _includes/session/header.html
52
53
  - _includes/session/images.html
53
54
  - _includes/session/item.html