askclass-course-theme 0.17.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 886e39bbcdab94d388dfa9c55bcbfe41b1b1283f479c4db696d93883bf9c23df
4
- data.tar.gz: 785bca91c47314ff9456392e3f5f32ccaee7b78eb07e0f046929ba4be96215d3
3
+ metadata.gz: 774894d1fc1a67d7c731c3cd0d3563798198c89968ddf9620529004f3d31b17b
4
+ data.tar.gz: a16889d3dfde34bac5aeaaa375403f1f46efcbc827458d9ffb988118b8107722
5
5
  SHA512:
6
- metadata.gz: 6571e10c3b28c25ac4e98153c5bf828ac3ae36ebf28beac7beac9b927ef948940b2c95970a9df227b1801a01183ea5cbe27477d503ff8a3bb42ea8808087c780
7
- data.tar.gz: 7d45255fc7eb87db6331645d7ccf3f2636ea596f2cb11db03d893d35c85364f8812fcd0add0120dd14727843caa34029f0df0c2b690c2391aec2742f4282dba9
6
+ metadata.gz: 5c17878b86a406c61a94e490b23f7c26f9d1453d3f4e2e485a00f5951d56cfe42d30fbeb0619d00671368117b70e05e60c70ca145c1546c9704d7f595e707e7c
7
+ data.tar.gz: 0c42c8af64f481af2ebbf8e14174dc10ee8636621c6fcdbdff7a6b25c65ea5f1e6a1073c8816ca2a38d8d5d579c02d1e3c59246921ff49abcb700acc0142450b
@@ -48,7 +48,7 @@
48
48
  {{ session.title }}
49
49
 
50
50
  {%- if session.part -%}
51
- <small>(Part {{ session.part }})</small>
51
+ <small>({{ session.part }})</small>
52
52
  {%- endif -%}
53
53
  </div>
54
54
  {%- endfor -%}
@@ -56,8 +56,10 @@
56
56
  <div class="control">
57
57
  <a class="button" href="/segment/{{ segment }}">
58
58
  {{ info.title }}&nbsp;
59
+ {%- if info['rocket-icon'] != 'none' %}
59
60
  <span data-date="{{ info.end }}"
60
61
  class="middle-align rocket {{ symbols }}">rocket_launch</span>
62
+ {%- endif %}
61
63
  </a>
62
64
  </div>
63
65
  </li>
@@ -2,7 +2,7 @@
2
2
  {% include head/meta.html -%}
3
3
  {%- include head/common.html -%}
4
4
  {%- if page.collection == 'session' -%}
5
- {%- if session_data.type == 'Dialog' -%}
5
+ {%- if session_data.dialog -%}
6
6
  <link rel="stylesheet" href="{{ 'assets/css/dialog.css' | relative_url }}" />
7
7
  {%- else -%}
8
8
  <link rel="stylesheet" href="{{ 'assets/css/session.css' | relative_url }}" />
@@ -23,10 +23,8 @@
23
23
  <span data-date="{{ session.due }}" class="{{ symbols }} alarm">alarm_on</span>
24
24
  {{ session.due | date: '%b %e, %y' }}
25
25
  </div>
26
- {%- elsif session.type -%}
27
- <div class="header">{{ session.header }}</div>
28
26
  {%- else -%}
29
- <div class="header">&nbsp;</div>
27
+ <div class="header">{{ session.header | default: "&nbsp;" }}</div>
30
28
  {%- endif -%}
31
29
 
32
30
  <div class="body">
@@ -38,7 +36,7 @@
38
36
 
39
37
  {%- if session.part -%}
40
38
  <div class="item">
41
- Part {{ session.part }}
39
+ {{ session.part }}
42
40
  </div>
43
41
  {%- endif -%}
44
42
  </div>
@@ -1,4 +1,3 @@
1
-
2
1
  <div class="bubble-container {{ include.side }}">
3
2
  <div class="talk-bubble {{ include.side }} tri-right {{ include.side }}-in border round">
4
3
  <div class="talktext">
@@ -4,7 +4,7 @@
4
4
  {%- if session_data.width != 'max' -%}
5
5
  {%- assign constraint = 'max-width' -%}
6
6
  {%- endif -%}
7
- {%- if session_data.type == 'Dialog' -%}
7
+ {%- if session_data.dialog -%}
8
8
  {%- assign constraint = constraint | prepend: 'dialog ' -%}
9
9
  {%- endif -%}
10
10
 
@@ -33,7 +33,7 @@
33
33
  {%- include footer.html -%}
34
34
  {%- include foot/mathjax.html -%}
35
35
  <script async src="/assets/js/essential-audio-player.js"></script>
36
- {%- if session_data.type == 'Dialog' -%}
36
+ {%- if session_data.dialog -%}
37
37
  <script async src="/assets/js/word-click-handler.js"></script>
38
38
  {%- include word-click-handler.html -%}
39
39
  {%- include foot/popup.html -%}
data/_sass/_base.scss CHANGED
@@ -53,6 +53,10 @@ body {
53
53
  &::-webkit-scrollbar-corner {
54
54
  background-color: transparent;
55
55
  }
56
+ &.no-scroll {
57
+ overflow: hidden;
58
+ padding-right: 6px;
59
+ }
56
60
  }
57
61
 
58
62
  hr {
data/_sass/_bubbles.scss CHANGED
@@ -281,23 +281,24 @@ html {
281
281
  font-size: calc(20px + (30 - 10) * ((100vw - 500px) / (1600 - 300)));
282
282
  line-height: calc(30px + (12 - 0) * ((100vw - 500px) / (600 - 10)));
283
283
  font-family: var(--font-tertiary);
284
- }
285
- .talktext .index {
286
- position: absolute;
287
- top: -14px;
288
- display: flex;
289
- width: 30px;
290
- font-size: 20px;
291
- line-height: 29px;
284
+ .index {
285
+ position: absolute;
286
+ top: -14px;
287
+ display: flex;
288
+ width: 30px;
289
+ font-size: 20px;
290
+ line-height: 29px;
291
+ white-space: nowrap;
292
+ }
292
293
  }
293
294
  .left .talktext .index {
294
295
  color: var(--color1);
295
- left: -40px;
296
+ left: -37px;
296
297
  justify-content: flex-end;
297
298
  }
298
299
  .right .talktext .index {
299
300
  color: var(--color2);
300
- right: -40px;
301
+ right: -37px;
301
302
  justify-content: flex-begin;
302
303
  }
303
304
  u {
data/_sass/_bullets.scss CHANGED
@@ -32,3 +32,36 @@ ul > li > ul > li {
32
32
  list-style-type: initial;
33
33
  }
34
34
  }
35
+
36
+ details {
37
+ summary {
38
+ cursor: pointer;
39
+ list-style: none;
40
+ &::-webkit-details-marker,
41
+ &::marker {
42
+ display: none;
43
+ }
44
+ &::before {
45
+ content: "\25B6\FE0E";
46
+ margin-right: 5px;
47
+ font-size: 0.9em;
48
+ color: var(--color-bullet);
49
+ }
50
+ }
51
+ &[open] {
52
+ summary {
53
+ &::before {
54
+ content: "\25BC\FE0E";
55
+ }
56
+ }
57
+ }
58
+ }
59
+
60
+ details > *:not(summary) {
61
+ animation: fadeIn 0.3s ease-in;
62
+ }
63
+
64
+ @keyframes fadeIn {
65
+ from { opacity: 0; margin-top: -10px; }
66
+ to { opacity: 1; margin-top: 0; }
67
+ }
data/_sass/_tab-main.scss CHANGED
@@ -45,6 +45,7 @@
45
45
  font-family: var(--icon-name);
46
46
  line-height: 0.7;
47
47
  font-size: 37px;
48
+ cursor: pointer;
48
49
  }
49
50
  }
50
51
 
@@ -69,6 +70,9 @@
69
70
  padding: 10px;
70
71
  overflow: hidden;
71
72
  text-align: left;
73
+ display: flex;
74
+ flex-direction: column;
75
+ justify-content: space-between;
72
76
  &.limit-height {
73
77
  max-height: var(--grid-body-height);
74
78
  overflow-y: auto;
data/_sass/popup.scss CHANGED
@@ -20,6 +20,10 @@
20
20
  width: 480px;
21
21
  max-height: 85vh;
22
22
  position: relative;
23
- height: inherit;
23
+ height: initial;
24
+ }
25
+
26
+ .body {
27
+ overflow-y: auto;
24
28
  }
25
29
  }
@@ -39,25 +39,29 @@ function showPopup(title, html) {
39
39
  if (body) body.innerHTML = html;
40
40
 
41
41
  popup.classList.add('show');
42
+ document.body.classList.add('no-scroll');
43
+ }
44
+
45
+ function close(popup) {
46
+ popup.classList.remove('show');
47
+ document.body.classList.remove('no-scroll');
42
48
  }
43
49
 
44
50
  function initPopupClose() {
45
51
  const popup = document.getElementById('course-popup');
46
52
  if (!popup) return;
47
53
 
48
- popup.querySelector('.tab')?.addEventListener('click', () => {
49
- popup.classList.remove('show');
50
- });
54
+ popup.querySelector('.tab')?.addEventListener('click', () => close(popup));
51
55
 
52
56
  popup.addEventListener('click', (e) => {
53
57
  if (e.target === popup) {
54
- popup.classList.remove('show');
58
+ close(popup);
55
59
  }
56
60
  });
57
61
 
58
62
  document.addEventListener('keydown', (e) => {
59
63
  if (e.key === 'Escape' && popup.classList.contains('show')) {
60
- popup.classList.remove('show');
64
+ close(popup);
61
65
  }
62
66
  });
63
67
  }
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.17.0
4
+ version: 0.18.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - AskClass
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-01-22 00:00:00.000000000 Z
11
+ date: 2026-01-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll