From bc616828f5d39c8d8fa86fd67c2ab6d0eac50195 Mon Sep 17 00:00:00 2001 From: xaoxuu Date: Sat, 4 Apr 2020 14:37:12 +0800 Subject: [PATCH] audio & video --- _config.yml | 2 +- scripts/tags/{video.js => media.js} | 8 +++++++- source/css/_layout/article.styl | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) rename scripts/tags/{video.js => media.js} (58%) diff --git a/_config.yml b/_config.yml index 2cb9859..2e1e4c5 100755 --- a/_config.yml +++ b/_config.yml @@ -4,7 +4,7 @@ info: version: '2.4.0' docs: https://volantis.js.org/ cdn: # To use CDN, write 'use_cdn: true' in 'blog/_config.yml'. - css: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@2.4.0.3/css/style.css + # css: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@2.4.0.3/css/style.css js: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@2.4.0/js/app.js diff --git a/scripts/tags/video.js b/scripts/tags/media.js similarity index 58% rename from scripts/tags/video.js rename to scripts/tags/media.js index 92f0c85..7926487 100644 --- a/scripts/tags/video.js +++ b/scripts/tags/media.js @@ -1,8 +1,13 @@ 'use strict'; +function postAudio(args) { + let src = args[0].trim() + return `

`; +} + function postVideo(args) { let src = args[0].trim() - return ``; + return `

`; } function postVideos(args, content) { @@ -19,5 +24,6 @@ function postVideos(args, content) { } } +hexo.extend.tag.register('audio', postAudio); hexo.extend.tag.register('video', postVideo); hexo.extend.tag.register('videos', postVideos, {ends: true}); diff --git a/source/css/_layout/article.styl b/source/css/_layout/article.styl index b5a68d3..64d9008 100644 --- a/source/css/_layout/article.styl +++ b/source/css/_layout/article.styl @@ -89,7 +89,7 @@ margin: 0 box-shadow: none s - color: alpha(@color, .75) + opacity: 0.7 u color: $color-hover p