Skip to content
New issue

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

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

Already on GitHub? # to your account

Update video #2512

Merged
merged 3 commits into from
May 1, 2020
Merged

Update video #2512

merged 3 commits into from
May 1, 2020

Conversation

sunete
Copy link
Contributor

@sunete sunete commented May 1, 2020

support insert bilibili video

This is an enhancement or feature.

Summary

Support insert bilibili video in the posts.

How to insert bilibili video?

Replace videoID with the bvid of the video you want to post.

{% include video id="videoID" provider="bilibili" %}

support bilibili video
_includes/video Outdated
@@ -9,5 +9,9 @@
<iframe src="https://www.youtube-nocookie.com/embed/{{ video_id }}" frameborder="0" allowfullscreen></iframe>
{% elsif video_provider == "google-drive" %}
<iframe src="https://drive.google.com/file/d/{{ video_id }}/preview" frameborder="0" allowfullscreen></iframe>
{% elsif video_provider == "bilibili" %}
<div class="responsive-video-container">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's already a <div class="responsive-video-container"> surrounding the whole if statement. Might be better to drop this duplicated <div> wrapper,

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. You're right. I have deleted the duplicated <div> wrapper.

drop the duplicated <div> wrapper
_includes/video Outdated
@@ -9,5 +9,7 @@
<iframe src="https://www.youtube-nocookie.com/embed/{{ video_id }}" frameborder="0" allowfullscreen></iframe>
{% elsif video_provider == "google-drive" %}
<iframe src="https://drive.google.com/file/d/{{ video_id }}/preview" frameborder="0" allowfullscreen></iframe>
{% elsif video_provider == "bilibili" %}
<iframe src="//player.bilibili.com/player.html?bvid={{ video_id }}&page=1&as_wide=1&high_quality=1&danmaku=0" scrolling="no" border="0" frameborder="no" framespacing="0" allowfullscreen="true"> </iframe>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another suggestion: Add https: before the URL so it stays in line with other items in the same list.

-  <iframe src="//player.bilibili.com/player.html?bvid={{ video_id }}&page=1&as_wide=1&high_quality=1&danmaku=0" scrolling="no" border="0" frameborder="no" framespacing="0" allowfullscreen="true"> </iframe>
+  <iframe src="https://player.bilibili.com/player.html?bvid={{ video_id }}&page=1&as_wide=1&high_quality=1&danmaku=0" scrolling="no" border="0" frameborder="no" framespacing="0" allowfullscreen="true"></iframe>

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😄Done.

update video
@mmistakes mmistakes merged commit 9280de7 into mmistakes:master May 1, 2020
jesuswasrasta pushed a commit to jesuswasrasta/jesuswasrasta.github.io that referenced this pull request Jul 8, 2020
* Update video

support bilibili video

* Update video

drop the duplicated <div> wrapper

* Update video

update video
mzaffran pushed a commit to mzaffran/mzaffran.github.io that referenced this pull request Jan 4, 2021
* Update video

support bilibili video

* Update video

drop the duplicated <div> wrapper

* Update video

update video
kaitokikuchi pushed a commit to kaitokikuchi/kaitokikuchi.github.io that referenced this pull request Sep 4, 2023
* Update video

support bilibili video

* Update video

drop the duplicated <div> wrapper

* Update video

update video
chukycheese pushed a commit to chukycheese/chukycheese.github.io that referenced this pull request Sep 18, 2023
* Update video

support bilibili video

* Update video

drop the duplicated <div> wrapper

* Update video

update video
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants