Coder Social home page Coder Social logo

hexo-theme-mellow's Introduction

hexo-theme-mellow

Join the chat at https://gitter.im/hexo-theme-mellow/Lobby

mellow

Material Design 风格的Hexo主题,基于 Hexo 3.0+ & Node 7.x+ 制作。 已经被Hexo官方收录

TODO: Internationalization

Feature

  1. 全端响应式主题。
  2. 添加了英文字体支持 bluehost。
  3. 添加了一些波纹效果。By Waves
  4. 无后端依赖的分享、浏览统计功能实现。
  5. 完美集成valine以及gitment评论系统。
  6. 基于静态数据的站内搜索,无第三方侵入。
  7. 支持文章打赏。
  8. 文章内可引入Github仓库。
  9. 持续更新中...

Document

文档 | Document

ChangeLog

升级前请仔细查看更改内容,如非必要可不升级。

ChangeLog

FAQ

初次使用时hexo g报错,大部分情况是因为缺少依赖,或者依赖版本问题。前往wiki-主题安装查看如何安装依赖。

打不开tags和categories等页面,是因为这两个页面并不属于hexo初始化范畴,需要手动创建。参考wiki-菜单开启与目录中对应页面方法

Community

QQ群:527753185

Users

下方陈列长期使用mellow主题的博客地址,不定期更新。需要的话请提交issue并附上博客的在线地址。

yirufeng's Blog - http://www.sivan.tech

YuanLiChenAi - https://yuanlichenai.cn/

Zip的小窝 - https://blog.ourfor.top/

ZhangQiang's blog - https://zq-jhon.github.io/

Dandan Rhapsody - https://blog.dandan.tw/

hexo-theme-mellow's People

Contributors

codefine avatar formattedzzz avatar ourfor avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hexo-theme-mellow's Issues

图片路径,markdown和网页显示不一致

<img src="./文章名/graph.PNG" alt="graph" />可以在本地markdown内显示,但是部署到网页上后,无法显示图片。只有改成<img src="graph.PNG" alt="graph" />网页才能显示,但是此时markdown本地无法显示图片

代码行bug了,变成一行了

hexo生成后第一部分代码变成一行,行号也挤在一起了变成123,后面的代码没有变化
14a180ec571d8111f63937f26bd09ef8
这是md文件里面的
bca7ec368ffdc33963d325ef8ea6b2bf

图片路径错误

头像背景图片和头部背景图片路径没有拼接上项目root
image
正常路径如头像如下:
image

关于手机端代码显示不全的bug

关于手机端代码显示不全的问题

例如下图中的现象:

sudo dd if=/Users/zip/Desktop/lede-17.01.4-brcm2708-bcm2710-rpi-3-ext4-sdcard.img of=/dev/disk4 bs=1m

上图中代码末端缺失了m

作者提供的解决办法:
用文本编辑器打开博客根目录中的/themes/mellow/source/css/_partial/highlight.less,找到这一行:

    .highlight {
        .codeBlock();

        pre {
            margin: 0;
            padding: 0;
        }

改成:

    .highlight {
        .codeBlock();

        pre {
            margin: 0;
            padding-top: 0;
            padding-bottom: 0;
            padding-left: 0;

        }

Cannot GET /

clone了主题,在项目根目录的_config.yml 配置了主题,然后hexo g hexo s,
然后说找不到主页:

Cannot GET /

啥情况啊这是

新版是出于什么考虑把正文区域宽度缩小呢?

感觉原来的宽度很舒服,使用makedown写代码块,比较长的代码,原来正好能显示全,现在都要拉滚动条才能看见...

"Attach Listener" #12 daemon prio=9 os_prio=31 tid=0x00007ff0f780c800 nid=0x4507 waiting on condition [0x0000000000000000]
   java.lang.Thread.State: RUNNABLE

关于local_search没有结果的问题

站点配置

search:
  path: search.xml
  field: post
  format: html
  limit: 1000

主题配置

#搜索
local_search: true

之后并没有在根目录下看到search.xml的文件,请问博主怎么解决,有没有其他要注意的?

关于分享失败的问题

微博:ok
微信:扫码之后提示什么什么非微信官方网页,点击继续访问无响应
qq:移动端qq内置浏览器ok,PC端有提示信息,如下:

文档内容不符

最近升级主题版本,所以就重新克隆了最新的主题下来
在主题自带的_config.yml中,第22行讲到的头部背景,但是我改了路径才发现是换了主页的头部照片,而不是人物头像后面的背景,所以希望能够在文档当中改一下!

# 头部背景
# 如/img/avatar.jpg` 或 https://i.loli.net/2017/12/12/5a2fd18a74471.jpg
headerBg: /img/banner.jpg

插入代码后显示效果出现异常

在md源文件中插入代码:

typedef struct{
	ElemType *elem;      //结构体的基地址
	int length;          //顺序表中实际存放的元素个数
	int listsize;        //顺序表中能够存放的元素个数
}Sqlist;//结构体名


显示效果:


经测试如果在代码块前面插入一个任意代码,第二个代码显示正常

效果:

希望老哥尽快解决@-@

可否加入首页摘要渲染开关?

RT,现在首页文章的摘要都是未经渲染的原文本,看起来并不美观。摘要很多时候也可以用富文本写巧的,这里能给加个配置文件开关就很完美了。

我现在用的是Next主题,正在考虑更换Mellow,唯一阻拦就是这个qwq。

hexo 4.2.0 使用该主题访问报错

用hexo默认的landscape主题正常访问,但是切换成mellow主题后,启动正常,但访问不了,报错信息如下:
Unhandled rejection TypeError: /Users/yonas/blog/themes/mellow/layout/index.ejs:8

6     <div class="container body-wrap">
7         <ul class="post-list">
8         <%
9         if (theme.articleSort) {
10             site.posts.data = site.posts.data.sort(function(a, b) {
11                 return Number(a.updated.format('x')) < Number(b.updated.format('x')) ? 1 : -1;

Cannot read property 'per_page' of undefined
at eval (/Users/yonas/blog/themes/mellow/layout/index.ejs:26:49)
at index (/Users/yonas/blog/node_modules/ejs/lib/ejs.js:682:17)
at viewFn._compiled.locals [as _compiled] (/Users/yonas/blog/node_modules/hexo/lib/theme/view.js:136:48)
at viewFn.View.render (/Users/yonas/blog/node_modules/hexo/lib/theme/view.js:41:15)
at /Users/yonas/blog/node_modules/hexo/lib/hexo/index.js:61:21
at tryCatcher (/Users/yonas/blog/node_modules/bluebird/js/release/util.js:16:23)
at /Users/yonas/blog/node_modules/bluebird/js/release/method.js:15:34
at RouteStream._read (/Users/yonas/blog/node_modules/hexo/lib/hexo/router.js:126:3)
at RouteStream.Readable.read (stream_readable.js:470:10)
at resume
(_stream_readable.js:949:12)
at process._tickCallback (internal/process/next_tick.js:63:19)

环境信息如下:
hexo version
hexo: 4.2.0
hexo-cli: 3.0.0
os: Darwin 17.5.0 darwin x64
http_parser: 2.8.0
node: 10.16.3
v8: 6.8.275.32-node.54
uv: 1.28.0
zlib: 1.2.11
brotli: 1.0.7
ares: 1.15.0
modules: 64
nghttp2: 1.39.2
napi: 4
openssl: 1.1.1c
icu: 64.2
unicode: 12.1
cldr: 35.1
tz: 2019a

cat package.json
{
"name": "hexo-site",
"version": "0.0.0",
"private": true,
"scripts": {
"build": "hexo generate",
"clean": "hexo clean",
"deploy": "hexo deploy",
"server": "hexo server"
},
"hexo": {
"version": "4.2.0"
},
"dependencies": {
"hexo": "^4.0.0",
"hexo-generator-archive": "^1.0.0",
"hexo-generator-category": "^1.0.0",
"hexo-generator-index": "^1.0.0",
"hexo-generator-tag": "^1.0.0",
"hexo-renderer-ejs": "^1.0.0",
"hexo-renderer-stylus": "^1.1.0",
"hexo-renderer-marked": "^2.0.0",
"hexo-server": "^1.0.0"
}

分类界面异常

按照wiki创建好categories界面后,直接点击分类界面,会出现下面的界面,而不会显示全部分类:
1
但点击博客主页卡片上的分类可以正常显示:
2
3
点击全部后会回到第一幅图片的样子
这是有关 的一些设置:
4
请问这是什么原因,谢谢!!!

调用其他网站的某些js文件可以保持到本地吗?

最近博客的域名老是出现异常,提交工单, 您好,查看您的网站ourfor.tk和ourfor.top都有调用其他站点的文件例如http://cdn.bootcss.com/mathjax/2.7.1/latest.js?config=TeX-AMS-MML_HTMLorMML,其中ourfor.tk是正常的,ourfor.top提示403,建议您检查该文件的网站服务器是否有黑名单限制,可能是您的域名ourfor.top调用台频繁被拦截了。,但我还想用ourfor.top这个域名,也不想换主题,那么我能不能把某些可以保持到本地的js文件保存到七牛云或者博客的资源文件夹里面呢?能否实现呢?需要修改哪些文件呢?

可以展示自己的项目

自己有一个idea,有的hexo博客可以展示自己的GitHub上做的项目,例如“演示”这个主题的博客上面可以展示自己的开源项目,甚至还可以展示地点!

大佬

建议加入一个代码高亮就像NexT这样的代码高亮很不错

模板渲染问题

问题

最近在学习Python Flask框架,经常会遇到 url_for 等语法,今天在写文章整理的时候,hexo g 出现如下问题

image

后来自己在写的文章里面一个一个改,找到了问题出现的地方:

url_for() 除了第1个传入视图函数名,后面还可以在对应的视图界面中传入视图函数所需要的参数,参数名便是视图函数中的动态参数名
<a href="{{ url_for('delete_book', book_id=book.id) }}">删除</a>

修改思路就是把上面出现问题的地方使用markdown语法中的```进行包裹

求助

最后请问这个问题如何解决呀,除了用markdown语法的```进行包裹

主题启动报错

启动服务后,出现下面的问题:
ERROR Plugin load failed: hexo-generator-search TypeError: Cannot set property 'cdata' of undefined at Object.<anonymous> (G:\project\Hexo\Blog\node_modules\hexo-generator-search\lib\xml_generator.js:5:19) at Module._compile (module.js:643:30) at Object.Module._extensions..js (module.js:654:10) at Module.load (module.js:556:32) at tryModuleLoad (module.js:499:12) at Function.Module._load (module.js:491:3) at Module.require (module.js:587:17) at require (G:\project\Hexo\Blog\node_modules\hexo\lib\hexo\index.js:216:21) at G:\project\Hexo\Blog\node_modules\hexo-generator-search\index.js:20:40 at G:\project\Hexo\Blog\node_modules\hexo\lib\hexo\index.js:232:12 at tryCatcher (G:\project\Hexo\Blog\node_modules\bluebird\js\release\util.js:16:23) at Promise._settlePromiseFromHandler (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:512:31) at Promise._settlePromise (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:569:18) at Promise._settlePromise0 (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:614:10) at Promise._settlePromises (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:693:18) at Promise._fulfill (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:638:18) at Promise._resolveCallback (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:432:57) at Promise._settlePromiseFromHandler (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:524:17) at Promise._settlePromise (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:569:18) at Promise._settlePromise0 (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:614:10) at Promise._settlePromises (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:693:18) at Promise._fulfill (G:\project\Hexo\Blog\node_modules\bluebird\js\release\promise.js:638:18) INFO Start processing INFO Hexo is running at http://localhost:4001/. Press Ctrl+C to stop.
能够正常访问,但是看着不舒服,本机的环境是:node.js v8.9.4; hexo 3.5.0;
安装顺序按照wiki进行的,很顺利
请问这是什么原因?谢谢!

新功能建议

目前这款主题很强大也很简洁,但窝觉得还是有些地方可以改进一下:

  • 点击图片可以进行缩放(比如,Next主题那样)
  • 是否考虑加一些音乐的控件,可以全局播放啥的(比如,咚门的WordPress主题Always那种类型的Playlist)

也不知道我的建议是否有违作者的初心或者理念,若有请忽略!😂

Markdown中插入HTML表格出现异常

因为markdown不支持合并单元格,我插入了一个HTML的表格,可是这个表格总是位于文章底部。例如下图现象:

在主题 mellow 和主题 landscape 中测试均出现如下现象

其中插入table代码为

<table>
    <tr>
        <th>节次/周次</th>
        <th>星期一</th>
        <th>星期二</th>
        <th>星期三</th>
        <th>星期四</th>
        <th>星期五</th>
    </tr>
    <tr>
        <td>第一节</td>
        <td></td>
        <td></td>
        <td rowspan="2">高等数学(西205)</td>
        <td rowspan="2">高等数学(西206)</td>
        <td></td>
    </tr>
    <tr>
        <td>第二节</td>
        <td></td>
        <td rowspan="3">C++(西205)</td>
        <td></td>
    </tr>
    <tr>
        <td>第三节</td>
        <td rowspan="2">高等数学(西205)</td>
        <td rowspan="2">数据结构(西205)</td>
        <td rowspan="2">高等数学(西206)</td>
        <td rowspan="2">大学英语(至205)</td>
    </tr>
    <tr>
        <td>第四节</td>
    </tr>
    <tr>
        <td>第五节</td>
        <td rowspan="2">数据结构(西203)</td>
        <td rowspan="2">离散数学(西407)</td>
        <td rowspan="2">大学体育</td>
        <td></td>
        <td></td>
    </tr>
    <tr>
        <td>第六节</td>
        <td></td>
        <td></td>
    </tr>
    <tr>
        <td>第七节</td>
        <td rowspan="2">近代史(至305)</td>
        <td></td>
        <td rowspan="2">大学英语(至205)</td>
        <td></td>
        <td></td>
    </tr>
    <tr>
        <td>第八节</td>
        <td></td>
        <td></td>
        <td></td>
    </tr>
</table>

这表格始终位于文章底部,即莫名其妙出现大段空白
该如何解决呢?

执行hexo s,报错:ERROR Asset render failed: css/style.css

执行 hexo s 报错信息如下:
$ hexo s
INFO Start processing
INFO Hexo is running at http://localhost:4000 . Press Ctrl+C to stop.
WARN Partial _third-party/swipebox does not exist. (in _partial\script.ejs)
ERROR Asset render failed: css/style.css
TypeError: Cannot read property 'eval' of null
at C:\Users\Administrator\Desktop\git\blog\node_modules\less\lib\less\tree\call.js:41:54

然后导致页面css无法加载
已经按照wiki指导(https://blog.lujingtao.com/2017/11/20/hexo-theme/)安装依赖,但还是css无法加载。
我的github博客地址https://mryewills.github.io/
求大神支招

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.