mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-10-04 22:32:00 +08:00
update
This commit is contained in:
1 parent
2ca779a6ad
commit
90b4511193
3 files changed
+26
-35
No files matched your search
@@ -82,7 +82,7 @@ hexo.extend.helper.register('getBgPath', path => {
|
||||
|
||||
const absoluteUrlPattern = /^(?:[a-z][a-z\d+.-]*:)?\/\//i
|
||||
const relativeUrlPattern = /^(\.\/|\.\.\/|\/|[^/]+\/).*$/
|
||||
const colorPattern = /^(#|rgb|rgba|hsl|hsla|linear-gradient|radial-gradient)/i
|
||||
const colorPattern = /^(#|rgb|rgba|hsl|hsla)/i
|
||||
|
||||
if (colorPattern.test(path)) {
|
||||
return `background-color: ${path};`
|
||||
|
||||
Reference in new issue
Block a user