jekyll-theme-profile 1.8.4 → 1.8.5

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: 170036b5178432b2e86e982346a8895b8758af76ce6d06d51f368c39dd78a075
4
- data.tar.gz: 625304ca5346c58c02731398c47088fad3f623f1acd72e9d2e18b14f7299924f
3
+ metadata.gz: 9898d76037a44648a544a0e55be21c87068ffe5dbbfedf6d9b8988ae149c51e7
4
+ data.tar.gz: 59c490d46718934edd9de4672d5c0cbdf17557860037fb4cc5a241267c77853b
5
5
  SHA512:
6
- metadata.gz: 36dfb3861cbaddaf2e2ff6289b9b06091a04b15553c641fd5a5293c29fd7386196a1a5a93eb33fd47dd1ec00a651a330ce4a08b63e19f214916e1cd88a483ff1
7
- data.tar.gz: 7f0366544fef23ce6305970c1765271180e1e7d1f1b373fe70617faa6df4c62f22817e13c8e88af4ea4dbb7327e75ee374fdaf7f43fee8618fa924bf09827bea
6
+ metadata.gz: 9490534c90e37b61445ffd26dc980e6ef77d9b7f45d4c74f2ced5bf52735674f5c8abe1d8bdcd5800e2658cecb9bf3151e191447d7714d6a911438692817621c
7
+ data.tar.gz: c0187da606072cffdf05b586390d3c8c2e4460e5905a46aa922b7f834b58925c8f5ceec078f61202506bac8b3f841d18aa139564fe14ebe77730b685852f010d
@@ -22,9 +22,8 @@
22
22
  <div class="col-12 col-md-7">
23
23
  <div class="ml-5 mt-5">
24
24
  {%- if post.video %}
25
- <div class="image-container mb-5">
26
- <iframe height="490" width="100%" src="{{ post.video }}" frameborder="0" gesture="media"
27
- allow="encrypted-media; fullscreen; picture-in-picture" allowfullscreen></iframe>
25
+ <div id="Timeline-video-container" class="image-container mb-5">
26
+ <iframe id="Timeline-video" src="{{ post.video }}" frameborder="0" height="inherited" width="inherited"></iframe>
28
27
  </div>
29
28
  {%- elsif post.image %}
30
29
  <div class="image-container mb-5">
@@ -1,29 +1,49 @@
1
- // Fix timeline anchors
2
1
  document.addEventListener("DOMContentLoaded", function () {
3
- console.log("Timeline script is running!");
2
+ console.log("Timeline script is running!");
4
3
 
5
- function updateTopBarHeight() {
6
- // Recalculate topBarHeight
7
- var topBarElement = document.querySelector('.topbar');
8
- topBarHeight = topBarElement ? topBarElement.offsetHeight : 0;
4
+ function updateTopBarHeight() {
5
+ // Recalculate topBarHeight
6
+ var topBarElement = document.querySelector('.topbar');
7
+ topBarHeight = topBarElement ? topBarElement.offsetHeight : 0;
9
8
 
10
- // Update styles for each timeline title
11
- timelineTitles.forEach(function (title) {
12
- title.style.top = topBarHeight + "px";
13
- });
14
- }
9
+ // Update styles for each timeline title
10
+ timelineTitles.forEach(function (title) {
11
+ title.style.top = topBarHeight + "px";
12
+ });
13
+ console.log("Updated offsetHeight!");
14
+ }
15
15
 
16
- // Default topBarHeight to 0 if .topbar doesn't exist
17
- var topBarHeight = 0;
18
- var timelineTitles = document.querySelectorAll(".TimelineItem-title");
16
+ // Set dimensions for all iframes with the same ID
17
+ function setIframeDimensions() {
18
+ var iframes = document.querySelectorAll('iframe[id="Timeline-video"]');
19
+ console.log(iframes.length);
20
+ var container = document.getElementById('Timeline-video-container');
19
21
 
20
- // Initial update
21
- updateTopBarHeight();
22
+ // Get the container's dimensions
23
+ var containerWidth = container.offsetWidth;
24
+ var containerHeight = container.offsetHeight;
25
+ if (iframes) {
26
+ iframes.forEach(function (iframe) {
27
+ iframe.style.width = containerWidth + 'px';
28
+ iframe.style.height = containerHeight + 'px';
29
+ });
30
+ console.log("Updated iframes width x height: " + containerWidth + " x " + containerHeight);
31
+ }
32
+ }
22
33
 
23
- // Add event listener for window resize
24
- window.addEventListener('resize', function () {
25
- // Call the function to update topBarHeight and adjust styles
26
- console.log("Updated height!");
27
- updateTopBarHeight();
28
- });
34
+ // Default topBarHeight to 0 if .topbar doesn't exist
35
+ var topBarHeight = 0;
36
+ var timelineTitles = document.querySelectorAll(".TimelineItem-title");
37
+
38
+ // Initial update
39
+ updateTopBarHeight();
40
+ setIframeDimensions();
41
+
42
+ // Add event listener for window resize
43
+ window.addEventListener('resize', function () {
44
+ // Call the function to update topBarHeight and adjust styles
45
+ console.log("resizing elements");
46
+ updateTopBarHeight();
47
+ setIframeDimensions();
48
+ });
29
49
  });
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-profile
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.4
4
+ version: 1.8.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Allison Thackston
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-12-18 00:00:00.000000000 Z
11
+ date: 2023-12-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll