Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Embedded video does not respect the media_subpath Front Matter variable #1738

Closed
1 task done
steveng57 opened this issue May 12, 2024 · 3 comments · Fixed by #1745
Closed
1 task done

Embedded video does not respect the media_subpath Front Matter variable #1738

steveng57 opened this issue May 12, 2024 · 3 comments · Fixed by #1745
Labels
bug Something isn't working released

Comments

@steveng57
Copy link

steveng57 commented May 12, 2024

Checklist

How did you create the site?

Generated from chirpy-starter

Describe the bug

When you embed a video using the include statement as follows:

{% include embed/video.html src="IMG_0695.mp4" muted = true title = "Walnut Table - 180° View" poster = "thumbnails/IMG_0695.jpeg"%}

the code ignores the media_subpath variable, looks for the mp4 file in the root of the project instead of where the media_subpath folder is pointing to.

Steps To Reproduce

Create a page and include the video.html file as above...set put the video in say /assets/posts/videos and set the media_subpath Front Matter page variable to that...

Expected Behavior

All media should be relative to the media_subpath variable, images and video ( and their posters).

In the file /_includes/embed/video.html, lines 6 thru 10 are as follows.

{% unless video_url contains '://' %}
  {%- capture video_url -%}
    {% include media-url.html src=video_url %}
  {%- endcapture -%}
{% endunless %}

It appears they should be...

{% unless video_url contains '://' %}
  {%- capture video_url -%}
    {% include media-url.html src=video_url subpath=page.media_subpath  %}
  {%- endcapture -%}
{% endunless %}

Environment

  • Ruby: 3.2.1
  • Jekyll: 4.3.3
  • Chirpy: 7.0.0

Anything else?

No response

@cotes2020 cotes2020 added the bug Something isn't working label May 14, 2024
Copy link

🎉 This issue has been resolved in version 7.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@steveng57
Copy link
Author

Thanks for the fix!
Nice.

@kungfux
Copy link
Collaborator

kungfux commented May 20, 2024

Thanks for the fix!
Nice.

Thanks for reporting!
You reminded me there was an unresolved thing in new features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants