diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..063b0e4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +.DS_Store +Thumbs.db +db.json +*.log +node_modules/ +public/ +.deploy*/ \ No newline at end of file diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..58f6b79 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,29 @@ +language: node_js +node_js: stable + +# 指定缓存模块,可选。缓存可加快编译速度。 +cache: + directories: + - node_modules + +install: + - npm install + +script: + - hexo g + +after_script: + - cd ./public + - git init + - git config user.name "travis ci" + - git config user.email "travis@163.com" + - git add . + - git commit -m "自动部署" + - git push --force --quiet "https://${GitHub_Token}@${GH_REF}" master:master + +branches: + only: + - hexo +env: + global: + - GH_REF: github.com/sslf/sslf.github.io \ No newline at end of file diff --git "a/2017/11/21/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" "b/2017/11/21/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" deleted file mode 100644 index a403579..0000000 --- "a/2017/11/21/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" +++ /dev/null @@ -1,954 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 编程器救砖小米mini路由器 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

编程器救砖小米mini路由器

- - - -
- - - - - -
- - - - - -

这个教程也适用修复sn码。申明: 刷机有风险,需谨慎。一切后果与本人无关

-

变砖原因

刚把路由器买来的时候,就迫不及待的刷成了PandoraBox,用了一段时间之后,想刷回官方的系统,在
刷回实际操作的时候,选错了方法,还是使用了刷PandoraBox的方式。导致路由器通电之后,一直
处于黄灯状态。ssh无法连接路由器。使用usb刷系统,处于红灯状态。我下意识就知道成砖头了。

-

吐槽一下小米之家,变砖之后我就直接去了小米之家,他们的维修方式只有两种:一种是在保修期内直接
换新的。另一种是保修期外返厂维修(他们是没有线刷设备的,维修不了)。我是过了保修期,又不想返
厂。为什么呢?我敢肯定的是硬件没有坏、有一点硬件的知识、不着急用、想练练手。

-

工具的准备

    -
  • 电脑一台
  • -
  • CH341A编程器和驱动
  • -
  • 编程器夹子
  • -
  • 十字和一字螺丝刀
  • -
  • WinHex软件
  • -
  • 小米mini路由器编程器固件
  • -
-

编程器和夹子都可以从某宝买来也不贵,但需要注意的是: 夹子的针脚数是8,别买错了
驱动和编程固件点击下载

-

操作步骤

1.拆路由器

一开始拿到路由器的时候,根本不知道从哪里下手,其实是要把他 背面的封条 撕掉(放到一边备用),就会露出螺丝来。
撕下来之后,就到了破开外壳了。用一字螺丝刀把路由器的这两边 撬开地方 撬开,再用一点劲就可以掰开了。备用。

-

2.修改编程固件

这个步骤是修复sn码,如果你不修复的话,无法绑定小米账号,也就无法用手机端管理路由器。不修复,能不能救活路由器我就不知道了,因为没有测试过。

-

用WinHex打开小米mini编程器固件(文件-打开-选择小米mini编程器固件),使用快捷键 ALT+G,输入 00FF0004 如图(图片来自网络)修改sn 就到了要我们修改的地方了。上图黄色标注的地方就是要替换的sn,我们自己路由器的sn就在从拆开路由器时,撕下来的标签上写着的。

-

这里修改sn的时候,并不是可以直接就把黄色标注的地方修改过来,而是需要在左边16进制区域进行修改。需要注意的是:16进制区域两个字母代表右边的一个数字。例如:00代表0,01代表1,以此类推09代表9。好在sn码全是数字,就可以自己使用刚刚的规则直接修改了。

-

在左边区域移动光标到要修改地方的起始位(移动的时候,右边的光标也会跟着移动,注意,右边移动两次,左边才移动一次。原因刚刚说过了)。把sn码逐个替换,替换完一个数字之后,看看右边显示的是不是我们想要的数字。

-

替换完成之后,还有一步重要的操作。选块计算CRC32,步骤是,标记一个起始位和一个截止未,计算这一段的 CRC32(32bit) 值。具体操作为:ALT+G 转到偏移量输入00FF0004,再按ALT+1(选块起始),按ALT+G转到偏移量输入00FF3FFF,再按ALT+2(选块结束),这样就选择好了块。再按CTRL+F2选择计算CRC32(注意类型)。就会得到一个值。记下这个值。 倒序 修改这个地方。如图(来自网络) 填写CRC32值 修改完成之后,保存。这个就是我们等会要刷入路由器的固件了。

-

3.刷机

这一步有两个难点。1.驱动的安装。2.正确的连接路由器和编程器。

-

驱动的安装,我就不说了。我是找了很多却动和换了3台电脑才成功了,重点说说连接路由器
正确连接的关键是: 找到路由器闪存、夹子和编程器的第一个脚
闪存器第一个脚是这个(来源网络): 闪存器第一个脚
夹子的第一个如图
夹子第一个脚
编程器的第一个脚如图 编程器第一个脚 注意放入的位置要和图片指示的位置一样。别上下搞反了。

-

这个三个地方的第一个脚全部连接好了之后,就可以用CH341A编程器软件刷机了。注意的是,在使用编程器夹子的时候千万不要给路由器通电,切记!

-

步骤是:检测-[读取-保存]-擦除-查空-打开(第二步修改保存的固件)-编程-校验。
读取和保存可以不操作,这步是保存刷机前路由器你的程序固件。编程的时候要等一段时间。一般都会校验通过的,通过了就代表着刷机成功了。赶快去下编程器,通电试试吧!

-

来几张我实际刷机的图片
实际图片1
实际图片2
实际图片3

-

总结

正确连接路由器和编程器是关键。驱动安装可能会出现错误,要有道耐心。

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2017/11/23/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207/index.html" "b/2017/11/23/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207/index.html" deleted file mode 100644 index c7ddab3..0000000 --- "a/2017/11/23/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207/index.html" +++ /dev/null @@ -1,948 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 设计模式第一篇 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

设计模式第一篇

- - - -
- - - - - -
- - - - - -

参考网址: 参考地址

-

什么是设计模式

它是一种编程的技巧,重在提高代码的可复用性。即使你不知道设计模式,也不妨碍你编码。大不了写的是一次性代码,代码看起来乱一点。如在没有任何编码经验下学习设计模式,我觉得你会走火入魔,变得形式主义,这样大可不必。当然,也不必把它当成神物,设计模式是要在特定的场合下才能发挥它实际的效果。重申一遍,它只是编码技巧。

-

设计模式的6原则

1.开闭原则

-
-

对扩展开发,对修改关闭。在程序需要扩展的时候,不能去修改原有的代码。

-
-

2.里氏替换原则

-
-

任何基类可以出现的地方,子类一点可以出现。只有当子类替换掉基类,软件功能不受影响时,基类才真正的被复用。子类可以在其基础上扩展新的行为。他是对开闭原则的补充,实现开闭原则的关键步骤就是抽象化。

-
-

3.依赖倒转原则

-
-

这是开闭原则的基础。依赖抽象,而不是依赖具体的实现

-
-

4.接口隔离原则

-
-

用多个接口来定义多个功能,实现多个接口,比实现一个接口更低耦合。

-
-

5.迪米特法则(最少知道原则)

-
-

一个类对自己依赖的类知道的越少越好。也就是说对于被依赖的类来说,无论逻辑有多复杂,都尽量的把逻辑封装在类的内部。高内聚

-
-

6.合成复用原则

-
-

尽量使用合成、聚合的方式,而不是使用继承。

-
-

其实这些原则,也是我们编码的原则。只要在编码过程中注意有没有违法这些原则,如果没有,那你写的代码的方式就是设计模式。

-

设计模式的分类

总体来说分为三大类

-
    -
  • 创建型模式,共五种:工厂方法模式、抽象工厂模式、单例模式、建造者模式、原型模式。
  • -
  • 结构型模式,共七种:适配器模式、装饰器模式、代理模式、外观模式、桥接模式、组合模式、享元模式。
  • -
  • 行为型模式,共十一种:策略模式、模板方法模式、观察者模式、迭代子模式、责任链模式、命令模式、备忘录模式、状态模式、访问者模式、中介者模式、解释器模式。
  • -
-

其实还有两类:并发型模式和线程池模式。

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/26/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247/index.html" "b/2018/03/26/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247/index.html" deleted file mode 100644 index 118e96e..0000000 --- "a/2018/03/26/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247/index.html" +++ /dev/null @@ -1,941 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 共享变量的可见性 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

共享变量的可见性

- - - -
- - - - - -
- - - - - -

一、什么是多线程共享变量的可见性

线程A对共享变量number的修改,在线程B中,能够及时的看到。

-

二、原子性

又叫代码执行不可分割性。顾名思义就是在程序执行的时候,获取了CPU执行权利后,该代码就必须要在这个运行状态中,全部执行完。不能执行一部分后等待下一次该线程的运行状态执行。

-

三、什么是共享变量

变量同时在多个线程中存在副本。那这个变量就是线程的共享变量。具体表现为:类的成员变量。

-

四、如何保证共享变量的可见性

换句话说就是:怎样才能保证变量在一个线程中的修改,其他线程可以准确无误的读取到。
要想实现这样的想法,那就要保证:变量在同一时刻,只能一个线程读取和修改。在Java中,提供了两个关键字来实现该操作。synchronized和volatile。

-

五、Java多线程简单的内存模型

内存分为:主内存和线程工作内存。如下图:
Java内存模型(JMM)

-

Java中所有的变量都存在于主内存中,线程工作内存中存放了共享变量的副本。

-

线程对共享变量的操作只能在自己的工作内存中进行,不能直接读取主内存。
不同线程之间不能访问其他线程的工作内存,线程间的变量传递只能通过主内存中转。

-

由上图可见:线程1对x的修改要想线程2及时看到要经过两个步骤:
1.把工程内存1中的共享变量刷新到主内存中。
2.线程2从主内存中同步共享变量到工作内存2中。

-

六、synchronized(同步)

作用:保证代码块的原子性和共享变量的可见性。
实现步骤:

-
    -
  1. 获取互斥锁。
  2. -
  3. 清空工作内存。
  4. -
  5. 把主内存中的共享变量存放到工作内存中。
  6. -
  7. 执行synchronized代码块。
  8. -
  9. 同步工作内存变量到主内存中。
  10. -
  11. 释放互斥锁。
  12. -
-

七、volatile

作用:保证共享变量的可见性。
原理:在对volatile变量执行写操作后,立即强制线程把该共享变量的更新到主内存中。在执行读操作时,强制线程从主内存中读取该变量的值。
注意事项:一般在多线程中使用volatile变量,对变量的写操作不能依赖变量本身。如:number++,num = num * 5等。

-

八、synchronized和volatile对比

    -
  1. volatile只能保证共享变量的可见性。
  2. -
  3. synchronized既能保证可见性,也能保证原子性。
  4. -
  5. volatile不需要加锁。比synchronized更轻,还不会阻塞线程。
  6. -
  7. volatile只能修饰变量,synchronized能修饰类、方法和代码块。
  8. -
  9. synchronized能被编译器优惠,比如代码的重排序。
  10. -
- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/27/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206/index.html" "b/2018/03/27/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206/index.html" deleted file mode 100644 index 346107d..0000000 --- "a/2018/03/27/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206/index.html" +++ /dev/null @@ -1,930 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Java 动态代理 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Java 动态代理

- - - -
- - - - - -
- - - - - -

什么是代理模式已经说明过了,那为什么Java又会有动态代理呢?

-

静态代理模式的缺点

    -
  1. 每代理一个类,都要编写一个代理类。如果需要代理大量的类那就不好维护代码了。
  2. -
  3. 如果代理要增加一个代理方法的话,那么所有的代理都需要同时修改。
  4. -
-

什么是Java动态代理

代理实现的本质就是:生成一个代理类来代理执行。动态代理就是:动态生成一个代理类。也就是在
程序运行期间,由JVM通过反射机制动态的生成一个代理类。

-

Java动态代理的分类

    -
  1. Jdk代理===接口代理
  2. -
  3. Cglib代理===子类代理
  4. -
-

jdk代理的实现方式

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/**
* 定义一个卖火车票接口
*/
public interface IticketSales {
void ticketSales();
}

/**
* 火车站实现买票接口
*/
public Class TrainStation implement IticketSales {

@Override
public void ticketSales(){
System.out.println("火车站卖票");
}

}

import java.lang.reflect.InvocationHandler;

public Class TrainStationProxy implement InvocationHandler {
// 代理目标类
Object target;

public TrainStationProxy(){

}

public TrainStationProxy(Object target){
this.target = target;
}

/**
* @Parama proxy 动态生成的代理类
* @Parama method 动态生成的代理类的被代理方法
* @Parama args 被代理方法的参数列表
*/
@Override
public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {

// 在目标对象的方法执行之前简单的打印一下
System.out.println("------------------before------------------");

// 执行目标对象的方法
Object result = method.invoke(target, args);

// 在目标对象的方法执行之后简单的打印一下
System.out.println("-------------------after------------------");

// 代理方法的返回值
return result;
}

/**
* 简化获取代理类的方式
*/
public Object newProxyInstance(){
Class targetClass = target.getClass();
Proxy.newProxyInstance(targetClass.getClassLoader(), targetClass.getInterfaces(), this);
}
}

/**
* 测试
*/
public static void main(String[] args) {
IticketSales iticketSales = new TrainStation();

// 获取代理对象
IticketSales trainStationProxy = (IticketSales) new TrainStationProxy(iticketSales).newProxyInstance();

// 调用方法
trainStationProxy.ticketSales();
}
-

问题:

    -
  1. 为什么jdk动态代理在没有实现接口类中不起作用?
  2. -
  3. 先生成的代理对象后,在调用的方法时,动态代理它怎么知道应该代理哪个方法,是不是把接口的所有方法都代理了?
  4. -
-

在回答问题之前,我们先去看看Jdk是如何实现动态代理的。

-

cglib代理的实现方式

- -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/27/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217/index.html" "b/2018/03/27/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217/index.html" deleted file mode 100644 index 6f72528..0000000 --- "a/2018/03/27/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217/index.html" +++ /dev/null @@ -1,930 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 代理模式 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

代理模式

- - - -
- - - - - -
- - - - - -

一、什么是代理模式

为其他对象提供一种代理,以控制对这个对象的访问。

-

二、具体控制了被代理对象的哪些访问?

    -
  1. 新增被代理对象不存在的方法
  2. -
  3. 屏蔽被代理对象中的某些方法
  4. -
  5. 扩展被代理的方法
  6. -
-

三、实际应用场景

场景一:购买火车票

-
-

最开始我们购买火车票一定要去火车站购买。然而火车站大多却是在大城市的边缘地区,离我们生活的区域较远,
购买极其不方便。这个时候,就出现了火车票代售点。它不但可以购买车票,而且还提供预约购票等额外的功能。但是,
却又不提供退票功能(可能实际上有提供),要退票只能去火车站退。

-
-

场景二:

-

四、代理的分类

    -
  1. 静态代理
  2. -
  3. 动态代理 Java动态代理
  4. -
-

五、具体的实现方式

静态代理:
在编写代码前,一定要记住,代理就用是一个类来代替另外一个类来处理事情。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/**
* 定义一个卖火车票接口
*/
public interface IticketSales {
void ticketSales();
}

/**
* 火车站实现买票接口
*/
public Class TrainStation implement IticketSales {

@Override
public void ticketSales(){
System.out.println("火车站卖票");
}

}

/**
* 火车站实现买票接口
*/
public Class TrainStationProxy implement IticketSales {
// 被代理对象
private IticketSales target;

public TrainStationProxy(){

}

public TrainStationProxy(IticketSales target){
this.target = target;
}

@Override
public void ticketSales(){
System.out.println("代售点--购票开始--欢迎来购买火车票");
target.ticketSales();
System.out.println("代售点--购票结束--祝你购票愉快,并送了一瓶水");
}

}

public static void main(String[] args) {
// 被代理对象
IticketSales trainStation = new TrainStation();

// 代理对象
IticketSales trainStationProxy = TrainStationProxy(trainStation);

// 执行购票方法
trainStationProxy.ticketSales();
}

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/28/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225/index.html" "b/2018/03/28/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225/index.html" deleted file mode 100644 index 1b18b47..0000000 --- "a/2018/03/28/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225/index.html" +++ /dev/null @@ -1,906 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Markdown 基本语法 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Markdown 基本语法

- - - -
- - - - - -
- - - - - -

参考地址

-

标题:{ # } 几个#就代表着几级标题。

-

引用:{ > }

-

有序列表:{ 1. } 注意有空格

-

换行:{ 两个空格 }

-

无序列表:{ * 或者 + 或者 - }

-

代码:{ ```java }

-

分割线:{ *** }

-

链接:{ [a标签里的文字](真正的链接地址 “title提示文字”) } title提示文字可以没有,如果要有的话,前面不要忘了空格

-

自动链接:{ <链接地址> }

-

参考:{ 参考 图片-参考方式 }

-

图片-行内: { ![备注文字](具体的图片地址 “图片提示文字”) } markdown不是调整图片大小,可以使用img标签来设置

-

图片-参考方式:{ ![备注文字][参考标识] [参考标识]:url “图片提示文字” } 例如:![GitHub][github]

-

[github]: https://avatars2.githubusercontent.com/u/3265208?v=3&s=100 “GitHub,Social Coding”

-

斜体:{ *斜体文字* }

-

加粗:{ **加粗文字** }

-

删除线:{ ~~删除的文字~~ }

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/29/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader/index.html" "b/2018/03/29/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader/index.html" deleted file mode 100644 index 3bb3ccb..0000000 --- "a/2018/03/29/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader/index.html" +++ /dev/null @@ -1,933 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 类加载器 ClassLoader | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

类加载器 ClassLoader

- - - -
- - - - - -
- - - - - -

参考

-

什么是类加载器

顾名思义就是加载类文件用的,也就是加载源代码文件编译后的class文件。只有加载到了jvm中才可以
执行。

-

加载器的分类

BootstrapClassLoader、ExtentionClassLoader、AppClassLoader、自定义的ClassLoader

-

各个加载器的关系

默认关系是:
BootstrapClassLoader 是 ExtentionClassLoader 的父加载器。
ExtentionClassLoader 是 AppClassLoader 的父加载器。
AppClassLoader 是 自定义的ClassLoader 的加载器。

-

注意:在java中,如果获取到的父加载器是null,那么就说明实际上是BootstrapClassLoader。
所以,当我们要指明父加载器是BootstrapClassLoader的话,就直接设置为null即可。

-

加载类的过程(双亲委派)

类加载过程

-

总结:加载类是一层一层往上加载,如果找到了就一层层返回。如果找到顶层都还没有找到,那顶层加载器就开始加载。如果没有加载到,就调用下一层,一层层加载。直到最后一层加载,如果加载到就返回。没有就抛出ClassNotFindExcepton。

-

ClassLoader 中重要的方法

    -
  1. loadClass (加载class的执行步骤的定义)
  2. -
  3. findLoadedClass (查找加载过的class)
  4. -
  5. findClass (查找class 文件)
  6. -
  7. defineClass (class文件转换为类)
  8. -
-

自定义ClassLoader的使用场景

    -
  1. 自定义加载不同地方的类
  2. -
  3. 类的解密加载器
  4. -
- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/31/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217/index.html" "b/2018/03/31/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217/index.html" deleted file mode 100644 index 7cc71f4..0000000 --- "a/2018/03/31/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217/index.html" +++ /dev/null @@ -1,891 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Centos7 修改源镜像 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Centos7 修改源镜像

- - - -
- - - - - -
- - - - - -

默认的源在国内访问一点慢。修改为阿里云的

-
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
先安装 wget
yum install wget -y

备份当前的yum源
mv /etc/yum.repos.d /etc/yum.repos.d.backup4comex

新建空的yum源设置目录
mkdir /etc/yum.repos.d

下载安装阿里云的yum源配置
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

情况仓库缓存
yum clean all

重新创建缓存
yum makecache

大功告成
- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/31/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6/index.html" "b/2018/03/31/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6/index.html" deleted file mode 100644 index 4fb4444..0000000 --- "a/2018/03/31/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6/index.html" +++ /dev/null @@ -1,890 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CentOS7 安装 mysql5.6 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

CentOS7 安装 mysql5.6

- - - -
- - - - - -
- - - - - -

安装步骤如下:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
1.安装mysql的源
rpm -Uvh http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm

2.查看可以安装的mysql
yum repolist enabled | grep "mysql.*-community.*"

3.执行安装
yum -y install mysql-community-server

4.安装成功,加入开机启动
systemctl enable mysqld

5.启动mysql
systemctl start mysqld.service

6.配置myslq
mysql_secure_installation

配置项:
1.设置root用户密码
2.删除匿名用户
3.禁止root远程登录
4.删除test数据库
5.刷新权限

7.配置root远程登录
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION;

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/03/31/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273/index.html" "b/2018/03/31/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273/index.html" deleted file mode 100644 index f03deb6..0000000 --- "a/2018/03/31/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273/index.html" +++ /dev/null @@ -1,920 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Mysql 读写分离 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Mysql 读写分离

- - - -
- - - - - -
- - - - - -

mysql版本为:5.6
要读写分离,就要配置mysql的同步。
mysql的同步又分为:异步同步(默认),半同步同步。

-

同步原理

mysql主从复制-介绍

-

同步配置步骤

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
1.开启master的log-bin,并配置server-id,设置要同步的数据库
[mysqld]
log-bin=mysql-master-bin
server-id=1
# 设置要同步的数据库
binlog-do-db=test
# 设置不同的数据库
binlog-ignore-db=information_schema
binlog-ignore-db=performance_schema
binlog-ignore-db=mysql


2.在master上创建一个可以用来同步的账户,并赋上相应的权限
grant REPLICATION SLAVE on *.* to 'repl'@'%' identifiled by '密码';

3.(看情况可选操作)停止master新提交数据
FLUSH TABLES WITH READ LOCK;
UNLOCK TABLES;

4.查看master状态
SHOW MASTER STATUS;
#在主库上查看已连接的slave主机
show slave hosts;
#查看所有binlog日志
show binary logs;
#查看所有binlog 事件
show binlog events in 'mysql-bin.000003';

5.配置slave节点
[mysqld]
log-bin=mysql-slave-bin
server-id=2
# 设置要同步的数据库
binlog-do-db=test
# 设置不同的数据库
binlog-ignore-db=information_schema
binlog-ignore-db=performance_schema
binlog-ignore-db=mysql

6.在slave上连接master
change master to master_host='192.168.1.11',master_user='repl',master_password='654321',master_log_file='mysql-master-bin.000003',master_log_pos=397;
7.在salve启动slave功能
start slave;
# 停止
stop slave;

8.查看是否启动成功
show slave status \G;

以下两个参数为Yes则为启动成功
Slave_IO_Running: Yes
Slave_SQL_Running: Yes
-

以上是使用了默认(statement)的bin-log记录模式以及异步复制。

-
1
2
3
4
# 修改bin-log记录模式
binlog_format=mixed
# 半同步复制
rpl_semi_sync_master_enabled=ON
-

读写分离步骤

使用的时360的Atlas
Atlas安装官方文档

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/04/04/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247/index.html" "b/2018/04/04/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247/index.html" deleted file mode 100644 index 5c1ecda..0000000 --- "a/2018/04/04/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247/index.html" +++ /dev/null @@ -1,948 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Google 搜索技巧 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Google 搜索技巧

- - - -
- - - - - -
- - - - - -

首先介绍google常用的命令

-
    -
  1. 双引号(完全匹配搜索)
  2. -
  3. 减号(排除关键字)
  4. -
  5. 星号(通配符)
  6. -
  7. inurl(在url中出现)
  8. -
  9. inanchor(超链接上的文字)
  10. -
  11. intitle(在title中出现)
  12. -
  13. filetype(指定文件类型)
  14. -
  15. site(限定搜索某个域名)
  16. -
-

1.双引号

说明:限定搜索出来的内容必须包含被引号引用的字符串。不区分中英文双引号
格式:“xxxx”

-

举个例子:搜索 重庆出租车。结果包含了:重庆出租车重庆出租车
重庆出租车
重庆出租车其他结果
更改搜索方式:“重庆出租车”
“重庆出租车”
“重庆出租车-15页”

-

2.减号

说明:排除搜索出来的内容包含某个关键字
格式:苹果 -apple,注意需要用空格来隔开

-

例如:搜索苹果,本意是要搜索可以吃的苹果相关内容,结果出现了以下不如意的内容:
不如意的苹果
排除官网 苹果 -官网,结果如下
苹果排除官网
继续排除,直到结果满意,苹果 -apple -官网 -公司 -地点 -系统
苹果满意的结果

-

3.星号

说明:通配符,代表一个或多个字符
格式:重庆*车、出租车*、*重庆

-

4.inurl

说明:在链接中搜索
格式:inurl:/admin/login.asp
inurl-admin-login

-

5.inanchor

说明:搜索的是超链接上的文字。可能返回的页面不一定带有这个超链接。
格式:inanchor:下载。这个的意思就是:搜索包含下载这个超链接的页面。
下载是超链接

-

6.intitle

说明:标题包含的
格式:intitle:后台登录
后台登录

-

7.filetype

说明:限定搜索出来的格式
格式:filetype:doc
filetype

-

8.site

说明:限定某个网址
格式:下载 site:baidu.com
baidu下载

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/04/17/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273/index.html" "b/2018/04/17/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273/index.html" deleted file mode 100644 index a460828..0000000 --- "a/2018/04/17/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273/index.html" +++ /dev/null @@ -1,932 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Java 日志体系 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Java 日志体系

- - - -
- - - - - -
- - - - - -

在工作中,我们可以接触到很多的日志jar包,比如:java.util.logging、log4j、log4j2、logback、slf4j等等。那我们应该怎么使用呢?

-

一、日志分类和作用关系

日志关系

-

日志门面的说明:
我们常用的门面有两个,一个是apache的common-logging-api简称:jcl。另外一个是:slf4j-api 简称 slf4j

-

二、常用门面的区别

他们的区别在于:jcl是检测classpath下存在什么日志就用什么日志。slf4j需要手动的添加适配器包到classpath下,也就是手动设置要用到的日志。

-

三、日志的嫁接

现在我们通常使用的是slf4j,同时也使用了spring。但是spring使用的是jcl门面。所有就需要做日志的嫁接了。如果不做的话,spring的日志我们是无法打印的。除非再给spring专门配一个日志打印。
怎么嫁接呢?

-
    -
  1. 从classpath中移除之前的日志实现。
  2. -
  3. 在classpath中引入一个叫:jcl-over-slf4j的jar包。
  4. -
-

嫁接之后,spring日志具体的执行流程就变成这样了(实线箭头方向):
jcl-over-slf4j

-

同样,想把slf4j嫁接到jcl,只需要移除之前的适配器,然后引入sl4j-jcl就可以了。

-

上面说的都是从一个门面嫁接到另一个门面。当然,从一个具体的日志实现,同样也是可以嫁接到日志门面的。比如:把log4j嫁接到slf4j上,只需要引入log4j-over-slf4j。

-

四、循环引用的问题

这个问题是会引发栈溢出(StackOverflowError),具体是什么一个情况呢。如下图:
栈溢出

-

本来slf4j就是用的log4j来打印日志的,结果又加入了log4j嫁接到slf4j上的jar包。所以也就发生了循环。

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/08/20/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205/index.html" "b/2018/08/20/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205/index.html" deleted file mode 100644 index 1c58578..0000000 --- "a/2018/08/20/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205/index.html" +++ /dev/null @@ -1,934 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Rabbitmq CentOS 安装 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Rabbitmq CentOS 安装

- - - -
- - - - - -
- - - - - -

在安装之前,我们需要准备的运行环境有:

-
-
    -
  1. Erlang (是一种通用的面向并发的编程语言)
  2. -
  3. socat (端口转发工具))
  4. -
-
-

另外需要明确的一点是,使用Centos的版本。以下是Centos6安装
ps.Centos7也是一样的安装步骤,只是下载的软件版本不一样

-

Erlang的安装

-

wget https://dl.bintray.com/rabbitmq/rpm/erlang/21/el/6/x86_64/erlang-21.0.2-1.el6.x86_64.rpm
rpm -ivh erlang-21.0.2-1.el6.x86_64.rpm

-
-

socat的安装

-

yum -y install socat

-
-

rabbitmq的安装

-

wget https://dl.bintray.com/rabbitmq/all/rabbitmq-server/3.7.7/rabbitmq-server-3.7.7-1.el6.noarch.rpm
rpm -ivh rabbitmq-server-3.7.7-1.el6.noarch.rpm

-
-

经过以上的步骤,rabbitmq应该已经是安装成功了。那接下来就是rabbitmq的配置

-
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# 服务的启动
service rabbitmq-server start # 启动mq服务
rabbitmq-plugins enable rabbitmq_management # 开启web管理
chkconfig rabbitmq-server on # 开启开机启动

# 端口的开启
iptables -I INPUT -p tcp -m tcp --dport 15672 -j ACCEPT # 开启端口
iptables -I INPUT -p tcp -m tcp --dport 5672 -j ACCEPT # 开启端口
service iptables save # 保持规则(要不然重启之后上面的两个规则丢失)
service iptables restart # 重启iptables服务(可以不用执行)

# 用户的添加(默认的guest只能在localhost中登录,当然也可以更改权限)
rabbitmqctl add_user admin 123456 # 添加 用户:admin 密码:123456
rabbitmqctl set_user_tags admin administrator # 给admin管理员的角色
rabbitmqctl set_permissions -p "/" admin '.*' '.*' '.*' # 设置用户权限(接受来自所有Host的所有操作)
-

访问你的主机:xxxx:15672 开启rabbitmq之旅吧!

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/09/03/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201/index.html" "b/2018/09/03/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201/index.html" deleted file mode 100644 index 5ba03d7..0000000 --- "a/2018/09/03/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201/index.html" +++ /dev/null @@ -1,927 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Git Bash 中文乱码 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Git Bash 中文乱码

- - - -
- - - - - -
- - - - - -

git status 乱码

执行:git status 命令时,本来该显示中文的地方,都显示成了数字,特别难受。
2018-09-03-19-43-15

-

解决办法如下:
执行:git config --global core.quotepath false 就恢复正常了

-

2018-09-03-19-46-25

-

git log 乱码

1
2
3
git config --global i18n.commitencoding utf-8
git config --global i18n.logoutputencoding utf-8
export LESSCHARSET=utf-8
- -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/09/05/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273/index.html" "b/2018/09/05/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273/index.html" deleted file mode 100644 index dc6b1b9..0000000 --- "a/2018/09/05/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273/index.html" +++ /dev/null @@ -1,1010 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Mysql 事务隔离 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

Mysql 事务隔离

- - - -
- - - - - -
- - - - - -

一、数据库事务的基本特性

事物是区分文件存储系统和Nosql数据库的重要特征之一。它存在的意义是保证在并发情况下的curd的正确性。那怎样才能算是正确的呢?
那就是事物的4个特性,即ACID:

-
    -
  1. A:原子性(atomicty)
    -

    事物中的各个操作,要么全部成功,要么全部失败。

    -
    -
  2. -
  3. C:一致性(consistency)
    -

    事物结束后,各个状态应该是一致的,是正确的。

    -
    -
  4. -
  5. I:隔离性(isolation)
    -

    并发中的各个事物之间,彼此不能看到对方的中间状态。换句话说,不能查询到其他事物的修改。

    -
    -
  6. -
  7. D:持久性(durability)
    -

    保存事物的所有修改

    -
    -
  8. -
-

在高并发下是很难完全同时保证ACID的。除非把所有的事物都串行执行,但串行所带来的效率问题又是我们不愿意接受的。为了解决这个问题。数据库提出了
事物的隔离级别。它允许我们在不同的业务场景下使用不同的策略来做ACID和效率之间的权衡。

-

事物的隔离级别分为以下4种:

-
    -
  1. 读未提交 RU (Read uncommitted):可以读到其他事务没有commit的数据。
  2. -
  3. 读提交 RC (Read committed):只能读到其他事务已经提交了的数据,但是自己事务中的数据,可以被其他事务修改。
  4. -
  5. 可重复读 RR (Repeatable read):
  6. -
  7. 可串行(Serializable):所有事务依次执行,效率最低,保证ACID。
  8. -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
隔离级别脏读不可重复读幻读
未提交读可能可能可能
提交读不可能可能可能
可重复读不可能不可能可能
可串行化不可能不可能不可能
-

有了上面的定义和理论。我们就来实践一下具体隔离级别的。在实践之前,先准备好实践环境。

-

首先创建一张测试表

1
2
3
4
5
CREATE TABLE `test` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8;

-

然后打开两个console。并且设置自动提交为off。

-

2018-09-06-09-41-46
2018-09-06-09-42-05

-

到此,环境已经准备完毕,开始测试。

-

读未提交(RU)

先设置session的事务隔离级别为:read uncommitted(RU)。两个console都要设置

1
set session transaction isolation level read uncommitted;

-

测试流程如下:
2018-09-06-10-00-54

-

可以看到当前事务读取到了其他事务未提交的修改(未确认 commit)。我们把没有commit的数据称为脏数据,因为没有commit的数据还可能发生rollback。

-

读提交(RC)

先设置session的事务隔离级别为:read committed(RC)。两个console都要设置

1
set session transaction isolation level read committed;

-

测试流程如下:
2018-09-06-13-50-33

-

RC级别,不能读取其他事务未提交的数据,脏读问题也就解决了,但是可以发现,在同一次事务中多次查询是数据结果不一致。这也就导致不可重复读取的问题。
如果要解决这个问题,那也就只能是RR级别了。另外,RC级别是Oracle的默认级别(未验证)。

-

可重复读(RR)

先设置session的事务隔离级别为:repeatable read(RR)。两个console都要设置

1
set session transaction isolation level repeatable read;

-

测试流程如下:
2018-09-06-14-09-52

-

在这个级别中。可以发现,已经解决了在同一个事务中多次查询不一致的问题。但是幻读的问题还是存在,myslq innodb 默认的事务隔离级别是:RR,但它自己解决了幻读
那什么是幻读呢?

-

幻读,简单讲就是在事务中前后读取的数据条数不一致。感觉就像是产生幻觉一样。那它和不可重复读有什么区别呢?
不可重复读:是数据的修改,即update、delete。
幻读:也是数据新增,即insert。

-

举个例子:目前表中余额剩余1000块的人有10人。事务A查询余额为1000元的用户查询到了10人,未提交事务。之后,事务B向表中插入了一条余额也为1000的记录。
事务A再次查询余额为1000的人,结果查询出了11条记录。这就是幻读。

-

串行

所以事务串行执行,事务隔离级别最高。效率最低。

-

参考:https://blog.csdn.net/a837199685/article/details/54563740

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/10/12/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242/index.html" "b/2018/10/12/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242/index.html" deleted file mode 100644 index a565ef2..0000000 --- "a/2018/10/12/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242/index.html" +++ /dev/null @@ -1,969 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 进制之间的转换 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

进制之间的转换

- - - -
- - - - - -
- - - - - -

这篇文章是计算机基础的开篇,同时也是我这个非科班的从头学习计算知识的总结。

-

接下来你将看到:

-
    -
  • 什么是基数
  • -
  • 什么是权
  • -
  • 十进制转换为二、八、十六进制
  • -
  • 二、八、十六进制转换为十进制
  • -
  • 二进制和八进制之间的互转
  • -
  • 二进制和十六进制之间的互转
  • -
-

一、什么是进制?

-

进位制是一种记数方式,亦称进位计数法或位值计数法。利用这种记数法,可以使用有限种数字符号来表示所有的数值 –维基百科

-
-

二、常见用途

    -
  1. 二进制广泛用于计算机
  2. -
  3. 三进制用于军队编制
  4. -
  5. 八进制广泛用于计算机
  6. -
  7. 十进制最为常用
  8. -
  9. 十二进制用于计算时辰、月份、一打物品
  10. -
  11. 十六进制广泛用于计算机
  12. -
  13. 二十进制曾被玛雅文明使用
  14. -
  15. 六十进制用于计算时间与角度单元。如秒、分
  16. -
-

三、转换之前要明白的

基数:计数系统拥有的计数字符的个数。

-
-

例如:二进制的字符有:0、1,一共有2个字符。那二进制的基数就是2
八进制的字符有:0、1、2、3、4、5、6、7,一共有8个字符。基数就是8
十进制的字符有:0、1、2、3、4、5、6、7、8、9,一共有10个字符。基数就是10
十六进制的字符有:0、1、2、3、4、5、6、7、8、9、A、B、C、D、E、F,一共有16个字符。基数就是16

-
-

数字的位置:小数点前的从0开始数;小数点后的从-1开始数。简单的理解就是:个位是位置0,向左位置+1,向右位置-1(可以为负数)。

-
-

例如数字:7654.321。7的位置是3、6的位置是2、5的位置是1、4的位置是0、3的是-1、2的是-2、1的是-3

-
-

权(位置决定的值)基数的(位置)次方的值。比如有一个十进制的数字:123.4。那各个数字的权为:1的为10^2、2的为10^1、3的为10^0、4的为10^-1

-

任何数值都是各位数值本身的值与其权之积的总和

-
-

例如:二进制数 10101 = 1*2^4 + 0*2^3 + 1*2^2 + 0*2^1 + 1*2^0
十进制数 1023 = 1*10^3 + 0*10^2 + 2*10^1 + 3*10^0

-
-

四、xxx进制转为十进制

任何进制转换为十进制,都是按权展开,权值相加

-

1. 二进制 –> 十进制

1001100.011 = ?(十进制)
= 1*2^6 + 1*2^3 + 1*2^2 + 1*2^-2 + 1*2^-3
= 64 + 8 + 4 + 0.25 + 0.125
= 76.375

-

2. 八进制 –> 十进制

23574.23 = ?(十进制)
= 2*8^4 + 3*8^3 + 5*8^2 + 7*8^1 + 4*8^0 + 2*8^-1 + 3*8^-2
= 8192 + 1536 + 320 + 56 + 4 + 0.25 + 0.046875
= 10108.296875

-

3. 十六进制 –> 十进制

3b3d9.3a = ?(十进制)
= 3*16^4 + b*16^3 + 3*16^2 + d*16^1 + 9*16^0 + 3*16^-1 + a16^-2
= 3\
16^4 + 11*16^3 + 3*16^2 + 13*16^1 + 9*16^0 + 3*16^-1 + 10*16^-2
= 196608 + 45056 + 768 + 208 + 9 + 0.1875 + 0.0390625
= 242649.2265625

-

五、十进制转为xxx进制

十进制转换为其他进制的方法是:整数部分,不断除以基数 (一直除到商等于0为止),余数倒排;小数部分,不断乘以基数,取积的整数部分,余下的小数继续乘以基数,直到为0为止。(因为小数部分是不断乘以基数有可能会无限乘下去,这就是精度问题的产生原因)

-

1. 十进制 –> 二进制

1239.31 = ?(二进制)
整数部分:
= 1239 / 2 等于 619 于 1
= 619 / 2 等于 309 于 1
= 309 / 2 等于 154 于 1
= 154 / 2 等于 77 于 0
= 77 / 2 等于 38 于 1
= 38 / 2 等于 19 于 0
= 19 / 2 等于 9 于 1
= 9 / 2 等于 4 于 1
= 4 / 2 等于 2 于 0
= 2 / 2 等于 1 于 0
= 1 / 2 等于 0 于 1

-

小数部分:
= 0.31 2 等于 0.62 整数为 0
= 0.62
2 等于 1.24 整数为 1
= 0.24 2 等于 0.48 整数为 0
= 0.48
2 等于 0.96 整数为 0
= 0.96 2 等于 1.92 整数为 1
= 0.92
2 等于 1.84 整数为 1

-

最后得到的结果是(整数部分倒排,小数部分正排):1239.31 ≈ 10011010111.010011

-

2. 十进制 –> 八进制

计算方式不变,还是和十进制转二进制一样,只是基数从2变为了8。具体详细的计算就略过了。

-

3. 十进制 –> 十六进制

基数变为16,其他不变。略

-

六、二进八进制互转

核心思想就是:3位二进制数表示1位8进制数。小数点为分隔符。

-

1. 二进制 –> 八进制

小数点为分隔符,向前向后数,不足3位的补0。3为合并为1位

-

1001001011.01101 = ?(八进制)
= 001 001 001 011.011 010
= 1 1 1 3.3 2
= 1113.32

-

2. 八进制 –> 二进制

3位展开

-

37436.24 = ?(二进制)
= 011 111 100 011 110.010 100
= 011111100011110.010100

-

七、二进制十六进制互转

四位展开或者四位合并

-

1. 二进制 –> 十六进制

略。和二进制转为八进制一个方式,只是3位合并变为了4位合并。

-

2. 十六进制 –> 二进制

略。和八进制转换为二进制一样。只是展开为3位变成了展开为4位。

-

八、总结

// TODO

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2018/10/29/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201/index.html" "b/2018/10/29/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201/index.html" deleted file mode 100644 index 4f9ec25..0000000 --- "a/2018/10/29/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201/index.html" +++ /dev/null @@ -1,969 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 原码、反码和补码 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

原码、反码和补码

- - - -
- - - - - -
- - - - - -

工科的出现是为了解决某些问题,那原码、反码和补码同样也是为了解决某些问题而产生的。那到底是要解决什么问题呢?
全国人民都知道,pc电脑又叫计算机,计算机的最基本的功能就是计算,也就是数字的加减乘除。那好,我们来看看计算机到底是如何做加减乘除的。

-

在做计算前。需要先说明一下,计算机存储任何数据都是用二进制编码。文字是二进制、图像是二进制、视频是二进制同样数字也是二进制。这种二进制存储方式就是俗称的数字化。
还有很重要的一点就是:计算机不会做减法。当我第一次听说的时候,很诧异,也很好奇。为什么呢?原来人们在设计计算机电路的时候,只保留了加法电路,从而简化了电路的设计与实现简单。只保留做加法的功能就能简化电路?
我的回答是肯定的。在数学中:2-1 = 2+(-1)、2*3 = 2+2+2、4/3 = 4-3 = 4+(-3)。用加法就可以做数字的运算。
数字是有正负的,那计算机是如何表达正负的呢?计算机先驱们规定:最高位0表示正数,1表示负数

-

一、方式一

现在要计算机计算:3+2=? 用4位二进制来表示。直接写出十进制的二进制码
计算规则为:二进制码相加,溢出就丢掉。

-

3+2 = 0011 + 0010 = 0101 = +5 结果正确

-

计算:3-2=? 用4位二进制表示
3-2 = 3+(-2) = 0011 + 1010 = 1101 = -5 错误

-

计算:3-3=? 用4位二进制表示
3-3 = 3+(-3) = 0011 + 1011 = 1110 = -6 错误

-

计算:2-3=? 用4位二进制表示
2-3 = 2+(-3) = 0010 + 1011 = 1101 = -5 错误

-

计算:-3-2=? 用4位二进制表示
-3-2 = -3-2 = 1011 + 1010 = 1 0111 = 0111 = 7 错误

-
-

10111等于0111是因为给的是4位,最高位溢出,所以得到了0111

-
-

小结:从上面5个计算结果来看,发现做减法一定是错误的(-3-2不是减法,而是需要强制写符号位的加法),做加法就没问题。
那我们得出的结论是:

-
    -
  1. 做减法错误
  2. -
  3. 0的表示有两种:0000 = +0,1000 = -0
  4. -
  5. 符号位需要强制写入
  6. -
-

二、方式二

为了解决上面出现的几个问题,在上面的基础上做些调整:正数不管,负数除开符号位,也就是最高位不管,其他的位置全部取反,是0变成1,1变成0
计算规则为:在方式一的基础上,正数不用取反,负数取反,然后得到的二进制码相加,有溢出的话,就把剩下的部分加一,最后把加一所得的二进制码取反就是结果

-

还是分别计算上面的几个式子:
3+2 = 0011 + 0010 = 0011 + 0010 = 0100 = 0101 正确

-

3-2 = 3+(-2) = 0011 + 1010 = 0011 + 1101 = 1 0000 = 0001 = 0001 = 1 正确

-
-

解释一下:1 0000 怎么就等于 0001了呢?其实是这样的,因为我们给的是4位,10000 长度为5位,所以最高位的1就溢出被丢弃掉了。因此,10000在4位的时候其实是为
0000,为了到达计算的准确性,只要有进位(溢出)我们就用结果加一。

-
-

3-3 = 3+(-3) = 0011 + 1011 = 0011 + 1100 = 1111 = 1000 = -0 结果正确,符号错误

-

2-3 = 2+(-3) = 0010 + 1011 = 0010 + 1100 = 1110 = 1001 = -1 正确

-

-3-2 = 1011 + 1010 = 1100 + 1101 = 1 1001 = 1010 = 1101 = -5 正确

-

小结:减法可以正确计算,但是溢出需要加一才能得正确的结果。同时又有+0和-0的结果出现,需要取绝对值才是正确的值。得出的结论是:

-
    -
  1. 减法正确
  2. -
  3. 0的表示有两种:0000 = 0000 = +0,1000 = 1111 = -0
  4. -
  5. 溢出需要加一才能得到准确结果
  6. -
  7. 在计算和取得最后结果之前,都需要做取反操作
  8. -
  9. 当结果为0的时候需要取绝对值
  10. -
-

三、方式三

上面的方式二,虽然可以准确的做减法,但是同时也引入的一些新的问题,比如无法准确得到结果0、溢出需要加一操作等等。
在使用计算机的时候,经常会听到性能一词。上面的计算方式明显不合乎追求高性能的做法。那有没有什么方法可以解决这个问题呢,计算机发展了这么多年肯定是有的。
那我们就看看新的方法。

-

在方式二的取反基础上加一得到新的二进制编码,也就是:正数不管,负数除开符号位,也就是最高位不管,其他的位置全部取反,是0变成1,1变成0,然后加1
计算规则为:整数不管,负数取反然后做加法操作,溢出位不管,得到溢出之后的结果再做取反加一就是几个二进制码了

-

还是分别计算上面的几个式子:
3+2 = 0011 + 0010 = 0011 + 0010 = 0011 + 0010 = 0101 = 0101 = 5 正确

-

3-2 = 3+(-2) = (0011 + 1010)二进制 = (0011 + 1101)取反 = (0011 + 1110)加一 = 1 0001 = (0001)溢出 = (0001)正数不管 = 1 正确

-

3-3 = 3+(-3) = 0011 + 1011 = 0011 + 1100 = 0011 + 1101 = 1 0000 = 0000 = 0 正确

-

2-3 = 2+(-3) = (0010 + 1011)二进制 = (0010 + 1100)取反 = (0010 + 1101)加一 = 1111 = (1000)取反 = (1001)加一 = -1 正确

-

-3-2 = -3+(-2) = (1011 + 1010)二进制 = (1100 + 1101)取反 = (1101 + 1110)加一 = 1 1011 = (1011)溢出 = (1100)取反 = (1101)加一 = -5 正确

-

小结:计算结果全部正确,没有特殊的需要判断的操作,因此解决了+0和-0的问题,也没有了溢出加一操作。所以计算都是相同操作。
因此得出的结论为:

-
    -
  1. 所有计算结果准确,且计算方式相同
  2. -
  3. 没有+0和-0的结果
  4. -
  5. 0000表示0,1000表示负的最小值,例如:8位就是:-128
  6. -
-

“都到这里了,还是没有说原码、反码和补码的事“,肯定有朋友是这么想的。其实我已经说过了。方式一就是原码,方式二就是反码,方式三就是补码。那接下来我们来总结一下。

-

四、总结

原码、反码和补码都是为了计算而产生的。只不过补码是为了解决原码和反码所带来的问题。现在的计算机一般都是用反码来计算。因此如果要问某种数据类型取值范围的话,
应该先得到该类型所占的字节数,然后根据1byte = 8bit可以得出取值范围为:-2^(n*8-1)~2^(n*8-1)-1。比如:java的int占多少位。就是-2^(4*8-1)~2^(4*8-1)-1 =
-2^31~2^31-1。

-

五、补码的推导

// TODO

-

参考:

- - - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/2019/02/21/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251/index.html" "b/2019/02/21/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251/index.html" deleted file mode 100644 index 13a16ab..0000000 --- "a/2019/02/21/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251/index.html" +++ /dev/null @@ -1,928 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 缓存击穿与缓存雪崩 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - - - - - - -
- - - -
- - - - - - - -
- - - -

缓存击穿与缓存雪崩

- - - -
- - - - - -
- - - - - -

全世界的程序猿都知道,在应对大流量、数据库的频繁查询的时候,由于数据库是承受不住的,所以一般都是在数据库的上方做一个缓存,也就是所谓的缓存层。
不过,你有没有想过,如果缓存失效了怎么办,全都走数据库查询,那数据库不就gg了吗。

-

什么?缓存会失效,我不信。好吧,那我就说说缓存失效的场景吧。

-

场景一

数据库里打死都不会出现xxx信息,突然有一天,有一大波流量在查询xxx。由于数据库没有数据,理所当然在上方的缓存里也没有缓存该数据,
缓存里没有,那就必须查询数据库了呀,可是数据库又承受不住这么大的流量。所以该数据库就gg了。—— 缓存击穿

-

场景二

数据库里也有数据,同时缓存也缓存了该数据。巧了,热点数据同时大面积失效了。也就是同一时间过期了。相当于没有了缓存,和场景一一样,
全部流量都又去到了数据库了。此时数据库正在承受着不该承受的压力。—— 缓存雪崩

-

缓存击穿造成的原因:查询缓存了压根就不会存在的值;而缓存雪崩的原因是:同一时间大面积缓存数据失效。那有没有什么应对方法呢?答案可定是有的。
具体的方案如下。

-

应对缓存击穿的方案如下:

-
    -
  1. 不是查询了数据库压根就没有的值嘛,只要我们把没有的值也缓存起来,不就可以嘛。比如 数据库返回null,在缓存里也缓存null就可以了。
  2. -
  3. 布隆过滤器
  4. -
  5. 流量控制
  6. -
-

应对缓存雪崩的方案如下:

-
    -
  1. 设置随机过期时间
  2. -
  3. 增加多级缓存
  4. -
  5. 流量控制
  6. -
-

我要说的就写完了,如有补充,请不吝赐教。

- - -
- - - - - - - - - - - -
- - - -
- - - -
- -
-
- - -
- - - - - - -
- -
- -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/_config.yml b/_config.yml new file mode 100644 index 0000000..be7d522 --- /dev/null +++ b/_config.yml @@ -0,0 +1,81 @@ +# Hexo Configuration +## Docs: https://hexo.io/docs/configuration.html +## Source: https://github.com/hexojs/hexo/ + +# Site +title: 水上灵风 +subtitle: 年龄大了,记不住了。所以 +description: 野生程序猿 +keywords: +author: 水上灵风 +language: zh-Hans +timezone: + +# URL +## If your site is put in a subdirectory, set url as 'http://yoursite.com/child' and root as '/child/' +url: http://blog.sslfer.com +root: / +permalink: :year/:month/:day/:title/ +permalink_defaults: + +# Directory +source_dir: source +public_dir: public +tag_dir: tags +archive_dir: archives +category_dir: categories +code_dir: downloads/code +i18n_dir: :lang +skip_render: + +# Writing +new_post_name: :title.md # File name of new posts +default_layout: post +titlecase: false # Transform title into titlecase +external_link: true # Open external links in new tab +filename_case: 0 +render_drafts: false +post_asset_folder: false +relative_link: false +future: true +highlight: + enable: true + line_number: true + auto_detect: false + tab_replace: + +# Home page setting +# path: Root path for your blogs index page. (default = '') +# per_page: Posts displayed per page. (0 = disable pagination) +# order_by: Posts order. (Order by date descending by default) +index_generator: + path: '' + per_page: 10 + order_by: -date + +# Category & Tag +default_category: uncategorized +category_map: +tag_map: + +# Date / Time format +## Hexo uses Moment.js to parse and display date +## You can customize the date format as defined in +## http://momentjs.com/docs/#/displaying/format/ +date_format: YYYY-MM-DD +time_format: HH:mm:ss + +# Pagination +## Set per_page to 0 to disable pagination +per_page: 10 +pagination_dir: page + +# Extensions +## Plugins: https://hexo.io/plugins/ +## Themes: https://hexo.io/themes/ +theme: next-5.1.4 + +# Deployment +## Docs: https://hexo.io/docs/deployment.html +deploy: + type: diff --git a/archives/2017/11/index.html b/archives/2017/11/index.html deleted file mode 100644 index 2866393..0000000 --- a/archives/2017/11/index.html +++ /dev/null @@ -1,768 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2017/index.html b/archives/2017/index.html deleted file mode 100644 index b707a86..0000000 --- a/archives/2017/index.html +++ /dev/null @@ -1,768 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/03/index.html b/archives/2018/03/index.html deleted file mode 100644 index 292ea75..0000000 --- a/archives/2018/03/index.html +++ /dev/null @@ -1,978 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/04/index.html b/archives/2018/04/index.html deleted file mode 100644 index 488ea94..0000000 --- a/archives/2018/04/index.html +++ /dev/null @@ -1,768 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/08/index.html b/archives/2018/08/index.html deleted file mode 100644 index af2f94f..0000000 --- a/archives/2018/08/index.html +++ /dev/null @@ -1,733 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/09/index.html b/archives/2018/09/index.html deleted file mode 100644 index 7b04c31..0000000 --- a/archives/2018/09/index.html +++ /dev/null @@ -1,768 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/10/index.html b/archives/2018/10/index.html deleted file mode 100644 index 9bde086..0000000 --- a/archives/2018/10/index.html +++ /dev/null @@ -1,768 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/index.html b/archives/2018/index.html deleted file mode 100644 index a1a7077..0000000 --- a/archives/2018/index.html +++ /dev/null @@ -1,1052 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2018/page/2/index.html b/archives/2018/page/2/index.html deleted file mode 100644 index 133381c..0000000 --- a/archives/2018/page/2/index.html +++ /dev/null @@ -1,877 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2019/02/index.html b/archives/2019/02/index.html deleted file mode 100644 index 0ffeae0..0000000 --- a/archives/2019/02/index.html +++ /dev/null @@ -1,733 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/2019/index.html b/archives/2019/index.html deleted file mode 100644 index fd22d6e..0000000 --- a/archives/2019/index.html +++ /dev/null @@ -1,733 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/index.html b/archives/index.html deleted file mode 100644 index 04d9b9b..0000000 --- a/archives/index.html +++ /dev/null @@ -1,1057 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/archives/page/2/index.html b/archives/page/2/index.html deleted file mode 100644 index c2ad058..0000000 --- a/archives/page/2/index.html +++ /dev/null @@ -1,987 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 归档 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/categories/index.html b/categories/index.html deleted file mode 100644 index 8f066b0..0000000 --- a/categories/index.html +++ /dev/null @@ -1,709 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 文章分类 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - -
-
- -

文章分类

- - - -
- - - - -
- - -
-
- 目前共计 4 个分类 -
- -
- -
- - - -
- - - -
- - -
- - - - - -
- - - - - - - - - -
-
- - - - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/categories/\345\237\272\347\241\200/index.html" "b/categories/\345\237\272\347\241\200/index.html" deleted file mode 100644 index 92fe06f..0000000 --- "a/categories/\345\237\272\347\241\200/index.html" +++ /dev/null @@ -1,740 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 分类: 基础 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/categories/\345\267\245\345\205\267/index.html" "b/categories/\345\267\245\345\205\267/index.html" deleted file mode 100644 index f3e8de1..0000000 --- "a/categories/\345\267\245\345\205\267/index.html" +++ /dev/null @@ -1,896 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 分类: 工具 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/categories/\346\212\200\346\234\257/index.html" "b/categories/\346\212\200\346\234\257/index.html" deleted file mode 100644 index b3631aa..0000000 --- "a/categories/\346\212\200\346\234\257/index.html" +++ /dev/null @@ -1,896 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 分类: 技术 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/css/main.css b/css/main.css deleted file mode 100644 index 2ae8151..0000000 --- a/css/main.css +++ /dev/null @@ -1,3135 +0,0 @@ -/* normalize.css v3.0.2 | MIT License | git.io/normalize */ -html { - font-family: sans-serif; /* 1 */ - -ms-text-size-adjust: 100%; /* 2 */ - -webkit-text-size-adjust: 100%; /* 2 */ -} -body { - margin: 0; -} -article, -aside, -details, -figcaption, -figure, -footer, -header, -hgroup, -main, -menu, -nav, -section, -summary { - display: block; -} -audio, -canvas, -progress, -video { - display: inline-block; /* 1 */ - vertical-align: baseline; /* 2 */ -} -audio:not([controls]) { - display: none; - height: 0; -} -[hidden], -template { - display: none; -} -a { - background-color: transparent; -} -a:active, -a:hover { - outline: 0; -} -abbr[title] { - border-bottom: 1px dotted; -} -b, -strong { - font-weight: bold; -} -dfn { - font-style: italic; -} -h1 { - font-size: 2em; - margin: 0.67em 0; -} -mark { - background: #ff0; - color: #000; -} -small { - font-size: 80%; -} -sub, -sup { - font-size: 75%; - line-height: 0; - position: relative; - vertical-align: baseline; -} -sup { - top: -0.5em; -} -sub { - bottom: -0.25em; -} -img { - border: 0; -} -svg:not(:root) { - overflow: hidden; -} -figure { - margin: 1em 40px; -} -hr { - -moz-box-sizing: content-box; - box-sizing: content-box; - height: 0; -} -pre { - overflow: auto; -} -code, -kbd, -pre, -samp { - font-family: monospace, monospace; - font-size: 1em; -} -button, -input, -optgroup, -select, -textarea { - color: inherit; /* 1 */ - font: inherit; /* 2 */ - margin: 0; /* 3 */ -} -button { - overflow: visible; -} -button, -select { - text-transform: none; -} -button, -html input[type="button"], -input[type="reset"], -input[type="submit"] { - -webkit-appearance: button; /* 2 */ - cursor: pointer; /* 3 */ -} -button[disabled], -html input[disabled] { - cursor: default; -} -button::-moz-focus-inner, -input::-moz-focus-inner { - border: 0; - padding: 0; -} -input { - line-height: normal; -} -input[type="checkbox"], -input[type="radio"] { - box-sizing: border-box; /* 1 */ - padding: 0; /* 2 */ -} -input[type="number"]::-webkit-inner-spin-button, -input[type="number"]::-webkit-outer-spin-button { - height: auto; -} -input[type="search"] { - -webkit-appearance: textfield; /* 1 */ - -moz-box-sizing: content-box; - -webkit-box-sizing: content-box; /* 2 */ - box-sizing: content-box; -} -input[type="search"]::-webkit-search-cancel-button, -input[type="search"]::-webkit-search-decoration { - -webkit-appearance: none; -} -fieldset { - border: 1px solid #c0c0c0; - margin: 0 2px; - padding: 0.35em 0.625em 0.75em; -} -legend { - border: 0; /* 1 */ - padding: 0; /* 2 */ -} -textarea { - overflow: auto; -} -optgroup { - font-weight: bold; -} -table { - border-collapse: collapse; - border-spacing: 0; -} -td, -th { - padding: 0; -} -::selection { - background: #262a30; - color: #fff; -} -body { - position: relative; - font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif; - font-size: 14px; - line-height: 2; - color: #555; - background: #eee; -} -@media (max-width: 767px) { - body { - padding-right: 0 !important; - } -} -@media (min-width: 768px) and (max-width: 991px) { - body { - padding-right: 0 !important; - } -} -@media (min-width: 1600px) { - body { - font-size: 16px; - } -} -h1, -h2, -h3, -h4, -h5, -h6 { - margin: 0; - padding: 0; - font-weight: bold; - line-height: 1.5; - font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif; -} -h2, -h3, -h4, -h5, -h6 { - margin: 20px 0 15px; -} -h1 { - font-size: 22px; -} -@media (max-width: 767px) { - h1 { - font-size: 18px; - } -} -h2 { - font-size: 20px; -} -@media (max-width: 767px) { - h2 { - font-size: 16px; - } -} -h3 { - font-size: 18px; -} -@media (max-width: 767px) { - h3 { - font-size: 14px; - } -} -h4 { - font-size: 16px; -} -@media (max-width: 767px) { - h4 { - font-size: 12px; - } -} -h5 { - font-size: 14px; -} -@media (max-width: 767px) { - h5 { - font-size: 10px; - } -} -h6 { - font-size: 12px; -} -@media (max-width: 767px) { - h6 { - font-size: 8px; - } -} -p { - margin: 0 0 20px 0; -} -a { - color: #555; - text-decoration: none; - outline: none; - border-bottom: 1px solid #999; - word-wrap: break-word; -} -a:hover { - color: #222; - border-bottom-color: #222; -} -blockquote { - margin: 0; - padding: 0; -} -img { - display: block; - margin: auto; - max-width: 100%; - height: auto; -} -hr { - margin: 40px 0; - height: 3px; - border: none; - background-color: #ddd; - background-image: repeating-linear-gradient(-45deg, #fff, #fff 4px, transparent 4px, transparent 8px); -} -blockquote { - padding: 0 15px; - color: #666; - border-left: 4px solid #ddd; -} -blockquote cite::before { - content: "-"; - padding: 0 5px; -} -dt { - font-weight: 700; -} -dd { - margin: 0; - padding: 0; -} -kbd { - border: 1px solid #ccc; - border-radius: 0.2em; - box-shadow: 0.1em 0.1em 0.2em rgba(0,0,0,0.1); - background-color: #f9f9f9; - font-family: inherit; - background-image: -webkit-linear-gradient(top, #eee, #fff, #eee); - padding: 0.1em 0.3em; - white-space: nowrap; -} -.text-left { - text-align: left; -} -.text-center { - text-align: center; -} -.text-right { - text-align: right; -} -.text-justify { - text-align: justify; -} -.text-nowrap { - white-space: nowrap; -} -.text-lowercase { - text-transform: lowercase; -} -.text-uppercase { - text-transform: uppercase; -} -.text-capitalize { - text-transform: capitalize; -} -.center-block { - display: block; - margin-left: auto; - margin-right: auto; -} -.clearfix:before, -.clearfix:after { - content: " "; - display: table; -} -.clearfix:after { - clear: both; -} -.pullquote { - width: 45%; -} -.pullquote.left { - float: left; - margin-left: 5px; - margin-right: 10px; -} -.pullquote.right { - float: right; - margin-left: 10px; - margin-right: 5px; -} -.affix.affix.affix { - position: fixed; -} -.translation { - margin-top: -20px; - font-size: 14px; - color: #999; -} -.scrollbar-measure { - width: 100px; - height: 100px; - overflow: scroll; - position: absolute; - top: -9999px; -} -.use-motion .motion-element { - opacity: 0; -} -table { - margin: 20px 0; - width: 100%; - border-collapse: collapse; - border-spacing: 0; - border: 1px solid #ddd; - font-size: 14px; - table-layout: fixed; - word-wrap: break-all; -} -table>tbody>tr:nth-of-type(odd) { - background-color: #f9f9f9; -} -table>tbody>tr:hover { - background-color: #f5f5f5; -} -caption, -th, -td { - padding: 8px; - text-align: left; - vertical-align: middle; - font-weight: normal; -} -th, -td { - border-bottom: 3px solid #ddd; - border-right: 1px solid #eee; -} -th { - padding-bottom: 10px; - font-weight: 700; -} -td { - border-bottom-width: 1px; -} -html, -body { - height: 100%; -} -.container { - position: relative; - min-height: 100%; -} -.header-inner { - margin: 0 auto; - padding: 100px 0 70px; - width: calc(100% - 252px); -} -@media (min-width: 1600px) { - .container .header-inner { - width: 900px; - } -} -.main { - padding-bottom: 150px; -} -.main-inner { - margin: 0 auto; - width: calc(100% - 252px); -} -@media (min-width: 1600px) { - .container .main-inner { - width: 900px; - } -} -.footer { - position: absolute; - left: 0; - bottom: 0; - width: 100%; - min-height: 50px; -} -.footer-inner { - box-sizing: border-box; - margin: 20px auto; - width: calc(100% - 252px); -} -@media (min-width: 1600px) { - .container .footer-inner { - width: 900px; - } -} -pre, -.highlight { - overflow: auto; - margin: 20px 0; - padding: 0; - font-size: 13px; - color: #4d4d4c; - background: #f7f7f7; - line-height: 1.6; -} -pre, -code { - font-family: consolas, Menlo, "PingFang SC", "Microsoft YaHei", monospace; -} -code { - padding: 2px 4px; - word-wrap: break-word; - color: #555; - background: #eee; - border-radius: 3px; - font-size: 13px; -} -pre { - padding: 10px; -} -pre code { - padding: 0; - color: #4d4d4c; - background: none; - text-shadow: none; -} -.highlight { - border-radius: 1px; -} -.highlight pre { - border: none; - margin: 0; - padding: 10px 0; -} -.highlight table { - margin: 0; - width: auto; - border: none; -} -.highlight td { - border: none; - padding: 0; -} -.highlight figcaption { - font-size: 1em; - color: #4d4d4c; - line-height: 1em; - margin-bottom: 1em; -} -.highlight figcaption:before, -.highlight figcaption:after { - content: " "; - display: table; -} -.highlight figcaption:after { - clear: both; -} -.highlight figcaption a { - float: right; - color: #4d4d4c; -} -.highlight figcaption a:hover { - border-bottom-color: #4d4d4c; -} -.highlight .gutter pre { - padding-left: 10px; - padding-right: 10px; - color: #869194; - text-align: right; - background-color: #eff2f3; -} -.highlight .code pre { - width: 100%; - padding-left: 10px; - padding-right: 10px; - background-color: #f7f7f7; -} -.highlight .line { - height: 20px; -} -.gutter { - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} -.gist table { - width: auto; -} -.gist table td { - border: none; -} -pre .deletion { - background: #fdd; -} -pre .addition { - background: #dfd; -} -pre .meta { - color: #8959a8; -} -pre .comment { - color: #8e908c; -} -pre .variable, -pre .attribute, -pre .tag, -pre .regexp, -pre .ruby .constant, -pre .xml .tag .title, -pre .xml .pi, -pre .xml .doctype, -pre .html .doctype, -pre .css .id, -pre .css .class, -pre .css .pseudo { - color: #c82829; -} -pre .number, -pre .preprocessor, -pre .built_in, -pre .literal, -pre .params, -pre .constant, -pre .command { - color: #f5871f; -} -pre .ruby .class .title, -pre .css .rules .attribute, -pre .string, -pre .value, -pre .inheritance, -pre .header, -pre .ruby .symbol, -pre .xml .cdata, -pre .special, -pre .number, -pre .formula { - color: #718c00; -} -pre .title, -pre .css .hexcolor { - color: #3e999f; -} -pre .function, -pre .python .decorator, -pre .python .title, -pre .ruby .function .title, -pre .ruby .title .keyword, -pre .perl .sub, -pre .javascript .title, -pre .coffeescript .title { - color: #4271ae; -} -pre .keyword, -pre .javascript .function { - color: #8959a8; -} -.full-image.full-image.full-image.full-image { - border: none; - max-width: 100%; - width: auto; - margin: 20px auto 25px; -} -@media (min-width: 992px) { - .full-image.full-image.full-image.full-image { - max-width: none; - width: 118%; - margin: 0 -9%; - } -} -.blockquote-center, -.page-home .post-type-quote blockquote, -.page-post-detail .post-type-quote blockquote { - position: relative; - margin: 40px 0; - padding: 0; - border-left: none; - text-align: center; -} -.blockquote-center::before, -.page-home .post-type-quote blockquote::before, -.page-post-detail .post-type-quote blockquote::before, -.blockquote-center::after, -.page-home .post-type-quote blockquote::after, -.page-post-detail .post-type-quote blockquote::after { - position: absolute; - content: ' '; - display: block; - width: 100%; - height: 24px; - opacity: 0.2; - background-repeat: no-repeat; - background-position: 0 -6px; - background-size: 22px 22px; -} -.blockquote-center::before, -.page-home .post-type-quote blockquote::before, -.page-post-detail .post-type-quote blockquote::before { - top: -20px; - background-image: url("../images/quote-l.svg"); - border-top: 1px solid #ccc; -} -.blockquote-center::after, -.page-home .post-type-quote blockquote::after, -.page-post-detail .post-type-quote blockquote::after { - bottom: -20px; - background-image: url("../images/quote-r.svg"); - border-bottom: 1px solid #ccc; - background-position: 100% 8px; -} -.blockquote-center p, -.page-home .post-type-quote blockquote p, -.page-post-detail .post-type-quote blockquote p, -.blockquote-center div, -.page-home .post-type-quote blockquote div, -.page-post-detail .post-type-quote blockquote div { - text-align: center; -} -.post .post-body .group-picture img { - box-sizing: border-box; - padding: 0 3px; - border: none; -} -.post .group-picture-row { - overflow: hidden; - margin-top: 6px; -} -.post .group-picture-row:first-child { - margin-top: 0; -} -.post .group-picture-column { - float: left; -} -.page-post-detail .post-body .group-picture-column { - float: none; - margin-top: 10px; - width: auto !important; -} -.page-post-detail .post-body .group-picture-column img { - margin: 0 auto; -} -.page-archive .group-picture-container { - overflow: hidden; -} -.page-archive .group-picture-row { - float: left; -} -.page-archive .group-picture-row:first-child { - margin-top: 6px; -} -.page-archive .group-picture-column { - max-width: 150px; - max-height: 150px; -} -.post-body .note { - position: relative; - padding: 15px; - margin-bottom: 20px; - border: 1px solid #eee; - border-left-width: 5px; - border-radius: 3px; -} -.post-body .note h2, -.post-body .note h3, -.post-body .note h4, -.post-body .note h5, -.post-body .note h6 { - margin-top: 0; - margin-bottom: 0; - border-bottom: initial; - padding-top: 0 !important; -} -.post-body .note p:first-child, -.post-body .note ul:first-child, -.post-body .note ol:first-child, -.post-body .note table:first-child, -.post-body .note pre:first-child, -.post-body .note blockquote:first-child { - margin-top: 0; -} -.post-body .note p:last-child, -.post-body .note ul:last-child, -.post-body .note ol:last-child, -.post-body .note table:last-child, -.post-body .note pre:last-child, -.post-body .note blockquote:last-child { - margin-bottom: 0; -} -.post-body .note.default { - border-left-color: #777; -} -.post-body .note.default h2, -.post-body .note.default h3, -.post-body .note.default h4, -.post-body .note.default h5, -.post-body .note.default h6 { - color: #777; -} -.post-body .note.primary { - border-left-color: #6f42c1; -} -.post-body .note.primary h2, -.post-body .note.primary h3, -.post-body .note.primary h4, -.post-body .note.primary h5, -.post-body .note.primary h6 { - color: #6f42c1; -} -.post-body .note.info { - border-left-color: #428bca; -} -.post-body .note.info h2, -.post-body .note.info h3, -.post-body .note.info h4, -.post-body .note.info h5, -.post-body .note.info h6 { - color: #428bca; -} -.post-body .note.success { - border-left-color: #5cb85c; -} -.post-body .note.success h2, -.post-body .note.success h3, -.post-body .note.success h4, -.post-body .note.success h5, -.post-body .note.success h6 { - color: #5cb85c; -} -.post-body .note.warning { - border-left-color: #f0ad4e; -} -.post-body .note.warning h2, -.post-body .note.warning h3, -.post-body .note.warning h4, -.post-body .note.warning h5, -.post-body .note.warning h6 { - color: #f0ad4e; -} -.post-body .note.danger { - border-left-color: #d9534f; -} -.post-body .note.danger h2, -.post-body .note.danger h3, -.post-body .note.danger h4, -.post-body .note.danger h5, -.post-body .note.danger h6 { - color: #d9534f; -} -.post-body .label { - display: inline; - padding: 0 2px; - white-space: nowrap; -} -.post-body .label.default { - background-color: #f0f0f0; -} -.post-body .label.primary { - background-color: #efe6f7; -} -.post-body .label.info { - background-color: #e5f2f8; -} -.post-body .label.success { - background-color: #e7f4e9; -} -.post-body .label.warning { - background-color: #fcf6e1; -} -.post-body .label.danger { - background-color: #fae8eb; -} -.post-body .tabs { - position: relative; - display: block; - margin-bottom: 20px; - padding-top: 10px; -} -.post-body .tabs ul.nav-tabs { - margin: 0; - padding: 0; - display: flex; - margin-bottom: -1px; -} -@media (max-width: 413px) { - .post-body .tabs ul.nav-tabs { - display: block; - margin-bottom: 5px; - } -} -.post-body .tabs ul.nav-tabs li.tab { - list-style-type: none !important; - margin: 0 0.25em 0 0; - border-top: 3px solid transparent; - border-left: 1px solid transparent; - border-right: 1px solid transparent; -} -@media (max-width: 413px) { - .post-body .tabs ul.nav-tabs li.tab { - margin: initial; - border-top: 1px solid transparent; - border-left: 3px solid transparent; - border-right: 1px solid transparent; - border-bottom: 1px solid transparent; - } -} -.post-body .tabs ul.nav-tabs li.tab a { - outline: 0; - border-bottom: initial; - display: block; - line-height: 1.8em; - padding: 0.25em 0.75em; - transition-duration: 0.2s; - transition-timing-function: ease-out; - transition-delay: 0s; -} -.post-body .tabs ul.nav-tabs li.tab a i { - width: 1.285714285714286em; -} -.post-body .tabs ul.nav-tabs li.tab.active { - border-top: 3px solid #fc6423; - border-left: 1px solid #ddd; - border-right: 1px solid #ddd; - background-color: #fff; -} -@media (max-width: 413px) { - .post-body .tabs ul.nav-tabs li.tab.active { - border-top: 1px solid #ddd; - border-left: 3px solid #fc6423; - border-right: 1px solid #ddd; - border-bottom: 1px solid #ddd; - } -} -.post-body .tabs ul.nav-tabs li.tab.active a { - cursor: default; - color: #555; -} -.post-body .tabs .tab-content { - background-color: #fff; -} -.post-body .tabs .tab-content .tab-pane { - border: 1px solid #ddd; - padding: 20px 20px 0 20px; -} -.post-body .tabs .tab-content .tab-pane:not(.active) { - display: none !important; -} -.post-body .tabs .tab-content .tab-pane.active { - display: block !important; -} -.btn { - display: inline-block; - padding: 0 20px; - font-size: 14px; - color: #555; - background: #fff; - border: 2px solid #555; - text-decoration: none; - border-radius: 2px; - transition-property: background-color; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; - line-height: 2; -} -.btn:hover { - border-color: #222; - color: #fff; - background: #222; -} -.btn +.btn { - margin: 0 0 8px 8px; -} -.btn .fa-fw { - width: 1.285714285714286em; - text-align: left; -} -.btn-bar { - display: block; - width: 22px; - height: 2px; - background: #555; - border-radius: 1px; -} -.btn-bar+.btn-bar { - margin-top: 4px; -} -.pagination { - margin: 120px 0 40px; - text-align: center; - border-top: 1px solid #eee; -} -.page-number-basic, -.pagination .prev, -.pagination .next, -.pagination .page-number, -.pagination .space { - display: inline-block; - position: relative; - top: -1px; - margin: 0 10px; - padding: 0 11px; -} -@media (max-width: 767px) { - .page-number-basic, - .pagination .prev, - .pagination .next, - .pagination .page-number, - .pagination .space { - margin: 0 5px; - } -} -.pagination .prev, -.pagination .next, -.pagination .page-number { - border-bottom: 0; - border-top: 1px solid #eee; - transition-property: border-color; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; -} -.pagination .prev:hover, -.pagination .next:hover, -.pagination .page-number:hover { - border-top-color: #222; -} -.pagination .space { - padding: 0; - margin: 0; -} -.pagination .prev { - margin-left: 0; -} -.pagination .next { - margin-right: 0; -} -.pagination .page-number.current { - color: #fff; - background: #ccc; - border-top-color: #ccc; -} -@media (max-width: 767px) { - .pagination { - border-top: none; - } - .pagination .prev, - .pagination .next, - .pagination .page-number { - margin-bottom: 10px; - border-top: 0; - border-bottom: 1px solid #eee; - padding: 0 10px; - } - .pagination .prev:hover, - .pagination .next:hover, - .pagination .page-number:hover { - border-bottom-color: #222; - } -} -.comments { - margin: 60px 20px 0; -} -.tag-cloud { - text-align: center; -} -.tag-cloud a { - display: inline-block; - margin: 10px; -} -.back-to-top { - box-sizing: border-box; - position: fixed; - bottom: -100px; - right: 30px; - z-index: 1050; - padding: 0 6px; - width: 24px; - background: #222; - font-size: 12px; - opacity: 0.6; - color: #fff; - cursor: pointer; - text-align: center; - -webkit-transform: translateZ(0); - transition-property: bottom; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; -} -@media (min-width: 768px) and (max-width: 991px) { - .back-to-top { - display: none !important; - } -} -@media (max-width: 767px) { - .back-to-top { - display: none !important; - } -} -.back-to-top.back-to-top-on { - bottom: 30px; -} -.header { - background: transparent; -} -.header-inner { - position: relative; -} -.headband { - height: 3px; - background: #222; -} -.site-meta { - margin: 0; - text-align: center; -} -@media (max-width: 767px) { - .site-meta { - text-align: center; - } -} -.brand { - position: relative; - display: inline-block; - padding: 0 40px; - color: #fff; - background: #222; - border-bottom: none; -} -.brand:hover { - color: #fff; -} -.logo { - display: inline-block; - margin-right: 5px; - line-height: 36px; - vertical-align: top; -} -.site-title { - display: inline-block; - vertical-align: top; - line-height: 36px; - font-size: 20px; - font-weight: normal; - font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif; -} -.site-subtitle { - margin-top: 10px; - font-size: 13px; - color: #ddd; -} -.use-motion .brand { - opacity: 0; -} -.use-motion .logo, -.use-motion .site-title, -.use-motion .site-subtitle { - opacity: 0; - position: relative; - top: -10px; -} -.site-nav-toggle { - display: none; - position: absolute; - top: 10px; - left: 10px; -} -@media (max-width: 767px) { - .site-nav-toggle { - display: block; - } -} -.site-nav-toggle button { - margin-top: 2px; - padding: 9px 10px; - background: transparent; - border: none; -} -@media (max-width: 767px) { - .site-nav { - display: none; - margin: 0 -10px; - padding: 0 10px; - clear: both; - border-top: 1px solid #ddd; - } -} -@media (min-width: 768px) and (max-width: 991px) { - .site-nav { - display: block !important; - } -} -@media (min-width: 992px) { - .site-nav { - display: block !important; - } -} -.menu { - margin-top: 20px; - padding-left: 0; - text-align: center; -} -.menu .menu-item { - display: inline-block; - margin: 0 10px; - list-style: none; -} -@media screen and (max-width: 767px) { - .menu .menu-item { - margin-top: 10px; - } -} -.menu .menu-item a { - display: block; - font-size: 13px; - line-height: inherit; - border-bottom: 1px solid transparent; - transition-property: border-color; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; -} -.menu .menu-item a:hover, -.menu-item-active a { - border-bottom-color: #222; -} -.menu .menu-item .fa { - margin-right: 5px; -} -.use-motion .menu-item { - opacity: 0; -} -.post-body { - font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif; -} -@media (max-width: 767px) { - .post-body { - word-break: break-word; - } -} -.post-body .fancybox img { - display: block !important; - margin: 0 auto; - cursor: pointer; - cursor: zoom-in; - cursor: -webkit-zoom-in; -} -.post-body .image-caption, -.post-body .figure .caption { - margin: -20px auto 15px; - text-align: center; - font-size: 14px; - color: #999; - font-weight: bold; - line-height: 1; -} -.post-sticky-flag { - display: inline-block; - font-size: 16px; - -ms-transform: rotate(30deg); - -webkit-transform: rotate(30deg); - -moz-transform: rotate(30deg); - -ms-transform: rotate(30deg); - -o-transform: rotate(30deg); - transform: rotate(30deg); -} -.use-motion .post-block, -.use-motion .pagination, -.use-motion .comments { - opacity: 0; -} -.use-motion .post-header { - opacity: 0; -} -.use-motion .post-body { - opacity: 0; -} -.use-motion .collection-title { - opacity: 0; -} -.posts-expand { - padding-top: 40px; -} -@media (max-width: 767px) { - .posts-expand { - margin: 0 20px; - } - .post-body pre .gutter pre { - padding-right: 10px; - } - .post-body .highlight { - margin-left: 0px; - margin-right: 0px; - padding: 0; - } - .post-body .highlight .gutter pre { - padding-right: 10px; - } -} -@media (min-width: 992px) { - .posts-expand .post-body { - text-align: justify; - } -} -.posts-expand .post-body h2, -.posts-expand .post-body h3, -.posts-expand .post-body h4, -.posts-expand .post-body h5, -.posts-expand .post-body h6 { - padding-top: 10px; -} -.posts-expand .post-body h2 .header-anchor, -.posts-expand .post-body h3 .header-anchor, -.posts-expand .post-body h4 .header-anchor, -.posts-expand .post-body h5 .header-anchor, -.posts-expand .post-body h6 .header-anchor { - float: right; - margin-left: 10px; - color: #ccc; - border-bottom-style: none; - visibility: hidden; -} -.posts-expand .post-body h2 .header-anchor:hover, -.posts-expand .post-body h3 .header-anchor:hover, -.posts-expand .post-body h4 .header-anchor:hover, -.posts-expand .post-body h5 .header-anchor:hover, -.posts-expand .post-body h6 .header-anchor:hover { - color: inherit; -} -.posts-expand .post-body h2:hover .header-anchor, -.posts-expand .post-body h3:hover .header-anchor, -.posts-expand .post-body h4:hover .header-anchor, -.posts-expand .post-body h5:hover .header-anchor, -.posts-expand .post-body h6:hover .header-anchor { - visibility: visible; -} -.posts-expand .post-body ul li { - list-style: circle; -} -.posts-expand .post-body img { - box-sizing: border-box; - margin: auto; - padding: 3px; - border: 1px solid #ddd; -} -.posts-expand .post-body .fancybox img { - margin: 0 auto 25px; -} -@media (max-width: 767px) { - .posts-collapse { - margin: 0 20px; - } - .posts-collapse .post-title, - .posts-collapse .post-meta { - display: block; - width: auto; - text-align: left; - } -} -.posts-collapse { - position: relative; - z-index: 1010; - margin-left: 55px; -} -.posts-collapse::after { - content: " "; - position: absolute; - top: 20px; - left: 0; - margin-left: -2px; - width: 4px; - height: 100%; - background: #f5f5f5; - z-index: -1; -} -@media (max-width: 767px) { - .posts-collapse { - margin: 0 20px; - } -} -.posts-collapse .collection-title { - position: relative; - margin: 60px 0; -} -.posts-collapse .collection-title h1, -.posts-collapse .collection-title h2 { - margin-left: 20px; -} -.posts-collapse .collection-title small { - color: #bbb; - margin-left: 5px; -} -.posts-collapse .collection-title::before { - content: " "; - position: absolute; - left: 0; - top: 50%; - margin-left: -4px; - margin-top: -4px; - width: 8px; - height: 8px; - background: #bbb; - border-radius: 50%; -} -.posts-collapse .post { - margin: 30px 0; -} -.posts-collapse .post-header { - position: relative; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; - transition-property: border; - border-bottom: 1px dashed #ccc; -} -.posts-collapse .post-header::before { - content: " "; - position: absolute; - left: 0; - top: 12px; - width: 6px; - height: 6px; - margin-left: -4px; - background: #bbb; - border-radius: 50%; - border: 1px solid #fff; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; - transition-property: background; -} -.posts-collapse .post-header:hover { - border-bottom-color: #666; -} -.posts-collapse .post-header:hover::before { - background: #222; -} -.posts-collapse .post-meta { - position: absolute; - font-size: 12px; - left: 20px; - top: 5px; -} -.posts-collapse .post-comments-count { - display: none; -} -.posts-collapse .post-title { - margin-left: 60px; - font-size: 16px; - font-weight: normal; - line-height: inherit; -} -.posts-collapse .post-title::after { - margin-left: 3px; - opacity: 0.6; -} -.posts-collapse .post-title a { - color: #666; - border-bottom: none; -} -.page-home .post-type-quote .post-header, -.page-post-detail .post-type-quote .post-header, -.page-home .post-type-quote .post-tags, -.page-post-detail .post-type-quote .post-tags { - display: none; -} -.posts-expand .post-title { - text-align: center; - word-break: break-word; - font-weight: 400; -} -.posts-expand .post-title-link { - display: inline-block; - position: relative; - color: #555; - border-bottom: none; - line-height: 1.2; - vertical-align: top; -} -.posts-expand .post-title-link::before { - content: ""; - position: absolute; - width: 100%; - height: 2px; - bottom: 0; - left: 0; - background-color: #000; - visibility: hidden; - -webkit-transform: scaleX(0); - -moz-transform: scaleX(0); - -ms-transform: scaleX(0); - -o-transform: scaleX(0); - transform: scaleX(0); - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; -} -.posts-expand .post-title-link:hover::before { - visibility: visible; - -webkit-transform: scaleX(1); - -moz-transform: scaleX(1); - -ms-transform: scaleX(1); - -o-transform: scaleX(1); - transform: scaleX(1); -} -.posts-expand .post-title-link .fa { - font-size: 16px; -} -.posts-expand .post-meta { - margin: 3px 0 60px 0; - color: #999; - font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif; - font-size: 12px; - text-align: center; -} -.posts-expand .post-meta .post-category-list { - display: inline-block; - margin: 0; - padding: 3px; -} -.posts-expand .post-meta .post-category-list-link { - color: #999; -} -.posts-expand .post-meta .post-description { - font-size: 14px; - margin-top: 2px; -} -.post-meta-divider { - margin: 0 0.5em; -} -.post-meta-item-icon { - margin-right: 3px; -} -@media (min-width: 768px) and (max-width: 991px) { - .post-meta-item-icon { - display: inline-block; - } -} -@media (max-width: 767px) { - .post-meta-item-icon { - display: inline-block; - } -} -@media (min-width: 768px) and (max-width: 991px) { - .post-meta-item-text { - display: none; - } -} -@media (max-width: 767px) { - .post-meta-item-text { - display: none; - } -} -@media (max-width: 767px) { - .posts-expand .post-comments-count { - display: none; - } -} -.post-button { - margin-top: 40px; -} -.posts-expand .post-tags { - margin-top: 40px; - text-align: center; -} -.posts-expand .post-tags a { - display: inline-block; - margin-right: 10px; - font-size: 13px; -} -.post-nav { - display: table; - margin-top: 15px; - width: 100%; - border-top: 1px solid #eee; -} -.post-nav-divider { - display: table-cell; - width: 10%; -} -.post-nav-item { - display: table-cell; - padding: 10px 0 0 0; - width: 45%; - vertical-align: top; -} -.post-nav-item a { - position: relative; - display: block; - line-height: 25px; - font-size: 14px; - color: #555; - border-bottom: none; -} -.post-nav-item a:hover { - color: #222; - border-bottom: none; -} -.post-nav-item a:active { - top: 2px; -} -.post-nav-item .fa { - position: absolute; - top: 8px; - left: 0; - font-size: 12px; -} -.post-nav-next a { - padding-left: 15px; -} -.post-nav-prev { - text-align: right; -} -.post-nav-prev a { - padding-right: 15px; -} -.post-nav-prev .fa { - right: 0; - left: auto; -} -.posts-expand .post-eof { - display: block; - margin: 80px auto 60px; - width: 8%; - height: 1px; - background: #ccc; - text-align: center; -} -.post:last-child .post-eof.post-eof.post-eof { - display: none; -} -.post-gallery { - display: table; - table-layout: fixed; - width: 100%; - border-collapse: separate; -} -.post-gallery-row { - display: table-row; -} -.post-gallery .post-gallery-img { - display: table-cell; - text-align: center; - vertical-align: middle; - border: none; -} -.post-gallery .post-gallery-img img { - max-width: 100%; - max-height: 100%; - border: none; -} -.fancybox-close, -.fancybox-close:hover { - border: none; -} -.rtl.post-body p, -.rtl.post-body a, -.rtl.post-body h1, -.rtl.post-body h2, -.rtl.post-body h3, -.rtl.post-body h4, -.rtl.post-body h5, -.rtl.post-body h6, -.rtl.post-body li, -.rtl.post-body ul, -.rtl.post-body ol { - direction: rtl; - font-family: UKIJ Ekran; -} -.rtl.post-title { - font-family: UKIJ Ekran; -} -.sidebar { - position: fixed; - right: 0; - top: 0; - bottom: 0; - width: 0; - z-index: 1040; - box-shadow: inset 0 2px 6px #000; - background: #222; - -webkit-transform: translateZ(0); -} -.sidebar a { - color: #999; - border-bottom-color: #555; -} -.sidebar a:hover { - color: #eee; -} -@media (min-width: 768px) and (max-width: 991px) { - .sidebar { - display: none !important; - } -} -@media (max-width: 767px) { - .sidebar { - display: none !important; - } -} -.sidebar-inner { - position: relative; - padding: 20px 10px; - color: #999; - text-align: center; -} -.site-overview-wrap { - overflow: hidden; -} -.site-overview { - overflow-y: auto; - overflow-x: hidden; -} -.sidebar-toggle { - position: fixed; - right: 30px; - bottom: 45px; - width: 14px; - height: 14px; - padding: 5px; - background: #222; - line-height: 0; - z-index: 1050; - cursor: pointer; - -webkit-transform: translateZ(0); -} -@media (min-width: 768px) and (max-width: 991px) { - .sidebar-toggle { - display: none !important; - } -} -@media (max-width: 767px) { - .sidebar-toggle { - display: none !important; - } -} -.sidebar-toggle-line { - position: relative; - display: inline-block; - vertical-align: top; - height: 2px; - width: 100%; - background: #fff; - margin-top: 3px; -} -.sidebar-toggle-line:first-child { - margin-top: 0; -} -.site-author-image { - display: block; - margin: 0 auto; - padding: 2px; - max-width: 120px; - height: auto; - border: 1px solid #eee; -} -.site-author-name { - margin: 0; - text-align: center; - color: #222; - font-weight: 600; -} -.site-description { - margin-top: 0; - text-align: center; - font-size: 13px; - color: #999; -} -.site-state { - overflow: hidden; - line-height: 1.4; - white-space: nowrap; - text-align: center; -} -.site-state-item { - display: inline-block; - padding: 0 15px; - border-left: 1px solid #eee; -} -.site-state-item:first-child { - border-left: none; -} -.site-state-item a { - border-bottom: none; -} -.site-state-item-count { - display: block; - text-align: center; - color: inherit; - font-weight: 600; - font-size: 16px; -} -.site-state-item-name { - font-size: 13px; - color: #999; -} -.feed-link { - margin-top: 20px; -} -.feed-link a { - display: inline-block; - padding: 0 15px; - color: #fc6423; - border: 1px solid #fc6423; - border-radius: 4px; -} -.feed-link a i { - color: #fc6423; - font-size: 14px; -} -.feed-link a:hover { - color: #fff; - background: #fc6423; -} -.feed-link a:hover i { - color: #fff; -} -.links-of-author { - margin-top: 20px; -} -.links-of-author a { - display: inline-block; - vertical-align: middle; - margin-right: 10px; - margin-bottom: 10px; - border-bottom-color: #555; - font-size: 13px; -} -.links-of-author a:before { - display: inline-block; - vertical-align: middle; - margin-right: 3px; - content: " "; - width: 4px; - height: 4px; - border-radius: 50%; - background: #81bfbf; -} -.links-of-blogroll { - font-size: 13px; -} -.links-of-blogroll-title { - margin-top: 20px; - font-size: 14px; - font-weight: 600; -} -.links-of-blogroll-list { - margin: 0; - padding: 0; - list-style: none; -} -.links-of-blogroll-item { - padding: 2px 10px; -} -.links-of-blogroll-item a { - max-width: 280px; - box-sizing: border-box; - display: inline-block; - overflow: hidden; - white-space: nowrap; - text-overflow: ellipsis; -} -.sidebar-nav { - margin: 0 0 20px; - padding-left: 0; -} -.sidebar-nav li { - display: inline-block; - cursor: pointer; - border-bottom: 1px solid transparent; - font-size: 14px; - color: #555; -} -.sidebar-nav li:hover { - color: #fc6423; -} -.page-post-detail .sidebar-nav-toc { - padding: 0 5px; -} -.page-post-detail .sidebar-nav-overview { - margin-left: 10px; -} -.sidebar-nav .sidebar-nav-active { - color: #fc6423; - border-bottom-color: #fc6423; -} -.sidebar-nav .sidebar-nav-active:hover { - color: #fc6423; -} -.sidebar-panel { - display: none; -} -.sidebar-panel-active { - display: block; -} -.post-toc-empty { - font-size: 14px; - color: #666; -} -.post-toc-wrap { - overflow: hidden; -} -.post-toc { - overflow: auto; -} -.post-toc ol { - margin: 0; - padding: 0 2px 5px 10px; - text-align: left; - list-style: none; - font-size: 14px; -} -.post-toc ol > ol { - padding-left: 0; -} -.post-toc ol a { - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; - transition-property: all; - color: #666; - border-bottom-color: #ccc; -} -.post-toc ol a:hover { - color: #000; - border-bottom-color: #000; -} -.post-toc .nav-item { - overflow: hidden; - text-overflow: ellipsis; - text-align: justify; - white-space: nowrap; - line-height: 1.8; -} -.post-toc .nav .nav-child { - display: none; -} -.post-toc .nav .active > .nav-child { - display: block; -} -.post-toc .nav .active-current > .nav-child { - display: block; -} -.post-toc .nav .active-current > .nav-child > .nav-item { - display: block; -} -.post-toc .nav .active > a { - color: #fc6423; - border-bottom-color: #fc6423; -} -.post-toc .nav .active-current > a { - color: #fc6423; -} -.post-toc .nav .active-current > a:hover { - color: #fc6423; -} -.footer { - font-size: 14px; - color: #999; -} -.footer img { - border: none; -} -.footer-inner { - text-align: center; -} -.with-love { - display: inline-block; - margin: 0 5px; -} -.powered-by, -.theme-info { - display: inline-block; -} -.cc-license { - margin-top: 10px; - text-align: center; -} -.cc-license .cc-opacity { - opacity: 0.7; - border-bottom: none; -} -.cc-license .cc-opacity:hover { - opacity: 0.9; -} -.cc-license img { - display: inline-block; -} -.theme-next #ds-thread #ds-reset { - color: #555; -} -.theme-next #ds-thread #ds-reset .ds-replybox { - margin-bottom: 30px; -} -.theme-next #ds-thread #ds-reset .ds-replybox .ds-avatar, -.theme-next #ds-reset .ds-avatar img { - box-shadow: none; -} -.theme-next #ds-thread #ds-reset .ds-textarea-wrapper { - border-color: #c7d4e1; - background: none; - border-top-right-radius: 3px; - border-top-left-radius: 3px; -} -.theme-next #ds-thread #ds-reset .ds-textarea-wrapper textarea { - height: 60px; -} -.theme-next #ds-reset .ds-rounded-top { - border-radius: 0; -} -.theme-next #ds-thread #ds-reset .ds-post-toolbar { - box-sizing: border-box; - border: 1px solid #c7d4e1; - background: #f6f8fa; -} -.theme-next #ds-thread #ds-reset .ds-post-options { - height: 40px; - border: none; - background: none; -} -.theme-next #ds-thread #ds-reset .ds-toolbar-buttons { - top: 11px; -} -.theme-next #ds-thread #ds-reset .ds-sync { - top: 5px; -} -.theme-next #ds-thread #ds-reset .ds-post-button { - top: 4px; - right: 5px; - width: 90px; - height: 30px; - border: 1px solid #c5ced7; - border-radius: 3px; - background-image: linear-gradient(#fbfbfc, #f5f7f9); - color: #60676d; -} -.theme-next #ds-thread #ds-reset .ds-post-button:hover { - background-position: 0 -30px; - color: #60676d; -} -.theme-next #ds-thread #ds-reset .ds-comments-info { - padding: 10px 0; -} -.theme-next #ds-thread #ds-reset .ds-sort { - display: none; -} -.theme-next #ds-thread #ds-reset li.ds-tab a.ds-current { - border: none; - background: #f6f8fa; - color: #60676d; -} -.theme-next #ds-thread #ds-reset li.ds-tab a.ds-current:hover { - background-color: #e9f0f7; - color: #60676d; -} -.theme-next #ds-thread #ds-reset li.ds-tab a { - border-radius: 2px; - padding: 5px; -} -.theme-next #ds-thread #ds-reset .ds-login-buttons p { - color: #999; - line-height: 36px; -} -.theme-next #ds-thread #ds-reset .ds-login-buttons .ds-service-list li { - height: 28px; -} -.theme-next #ds-thread #ds-reset .ds-service-list a { - background: none; - padding: 5px; - border: 1px solid; - border-radius: 3px; - text-align: center; -} -.theme-next #ds-thread #ds-reset .ds-service-list a:hover { - color: #fff; - background: #666; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-weibo { - color: #fc9b00; - border-color: #fc9b00; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-weibo:hover { - background: #fc9b00; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-qq { - color: #60a3ec; - border-color: #60a3ec; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-qq:hover { - background: #60a3ec; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-renren { - color: #2e7ac4; - border-color: #2e7ac4; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-renren:hover { - background: #2e7ac4; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-douban { - color: #37994c; - border-color: #37994c; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-douban:hover { - background: #37994c; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-kaixin { - color: #fef20d; - border-color: #fef20d; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-kaixin:hover { - background: #fef20d; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-netease { - color: #f00; - border-color: #f00; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-netease:hover { - background: #f00; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-sohu { - color: #ffcb05; - border-color: #ffcb05; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-sohu:hover { - background: #ffcb05; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-baidu { - color: #2831e0; - border-color: #2831e0; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-baidu:hover { - background: #2831e0; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-google { - color: #166bec; - border-color: #166bec; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-google:hover { - background: #166bec; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-weixin { - color: #00ce0d; - border-color: #00ce0d; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-weixin:hover { - background: #00ce0d; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-more-services { - border: none; -} -.theme-next #ds-thread #ds-reset .ds-service-list .ds-more-services:hover { - background: none; -} -.theme-next #ds-reset .duoshuo-ua-admin { - display: inline-block; - color: #f00; -} -.theme-next #ds-reset .duoshuo-ua-platform, -.theme-next #ds-reset .duoshuo-ua-browser { - color: #ccc; -} -.theme-next #ds-reset .duoshuo-ua-platform .fa, -.theme-next #ds-reset .duoshuo-ua-browser .fa { - display: inline-block; - margin-right: 3px; -} -.theme-next #ds-reset .duoshuo-ua-separator { - display: inline-block; - margin-left: 5px; -} -.theme-next .this_ua { - background-color: #ccc !important; - border-radius: 4px; - padding: 0 5px !important; - margin: 1px 1px !important; - border: 1px solid #bbb !important; - color: #fff; - display: inline-block !important; -} -.theme-next .this_ua.admin { - background-color: #d9534f !important; - border-color: #d9534f !important; -} -.theme-next .this_ua.platform.iOS, -.theme-next .this_ua.platform.Mac, -.theme-next .this_ua.platform.Windows { - background-color: #39b3d7 !important; - border-color: #46b8da !important; -} -.theme-next .this_ua.platform.Linux { - background-color: #3a3a3a !important; - border-color: #1f1f1f !important; -} -.theme-next .this_ua.platform.Android { - background-color: #00c47d !important; - border-color: #01b171 !important; -} -.theme-next .this_ua.browser.Mobile, -.theme-next .this_ua.browser.Chrome { - background-color: #5cb85c !important; - border-color: #4cae4c !important; -} -.theme-next .this_ua.browser.Firefox { - background-color: #f0ad4e !important; - border-color: #eea236 !important; -} -.theme-next .this_ua.browser.Maxthon, -.theme-next .this_ua.browser.IE { - background-color: #428bca !important; - border-color: #357ebd !important; -} -.theme-next .this_ua.browser.baidu, -.theme-next .this_ua.browser.UCBrowser, -.theme-next .this_ua.browser.Opera { - background-color: #d9534f !important; - border-color: #d43f3a !important; -} -.theme-next .this_ua.browser.Android, -.theme-next .this_ua.browser.QQBrowser { - background-color: #78ace9 !important; - border-color: #4cae4c !important; -} -#gitment-display-button { - display: inline-block; - padding: 0 15px; - color: #0a9caf; - cursor: pointer; - font-size: 14px; - border: 1px solid #0a9caf; - border-radius: 4px; -} -#gitment-display-button:hover { - color: #fff; - background: #0a9caf; -} -.post-spread { - margin-top: 20px; - text-align: center; -} -.jiathis_style { - display: inline-block; -} -.jiathis_style a { - border: none; -} -.fa { - font-family: FontAwesome !important; -} -.post-spread { - margin-top: 20px; - text-align: center; -} -.bdshare-slide-button-box a { - border: none; -} -.bdsharebuttonbox { - display: inline-block; -} -.bdsharebuttonbox a { - border: none; -} -.local-search-pop-overlay { - position: fixed; - width: 100%; - height: 100%; - top: 0; - left: 0; - z-index: 2080; - background-color: rgba(0,0,0,0.3); -} -.local-search-popup { - display: none; - position: fixed; - top: 10%; - left: 50%; - margin-left: -350px; - width: 700px; - height: 80%; - padding: 0; - background: #fff; - color: #333; - z-index: 9999; - border-radius: 5px; -} -@media (max-width: 767px) { - .local-search-popup { - padding: 0; - top: 0; - left: 0; - margin: 0; - width: 100%; - height: 100%; - border-radius: 0; - } -} -.local-search-popup ul.search-result-list { - padding: 0; - margin: 0 5px; -} -.local-search-popup p.search-result { - border-bottom: 1px dashed #ccc; - padding: 5px 0; -} -.local-search-popup a.search-result-title { - font-weight: bold; - font-size: 16px; -} -.local-search-popup .search-keyword { - border-bottom: 1px dashed #f00; - font-weight: bold; - color: #f00; -} -.local-search-popup .local-search-header { - padding: 5px; - height: 36px; - background: #f5f5f5; - border-top-left-radius: 5px; - border-top-right-radius: 5px; -} -.local-search-popup #local-search-result { - overflow: auto; - position: relative; - padding: 5px 25px; - height: calc(100% - 55px); -} -.local-search-popup .local-search-input-wrapper { - display: inline-block; - width: calc(100% - 90px); - height: 36px; - line-height: 36px; - padding: 0 5px; -} -.local-search-popup .local-search-input-wrapper input { - padding: 8px 0; - height: 20px; - display: block; - width: 100%; - outline: none; - border: none; - background: transparent; - vertical-align: middle; -} -.local-search-popup .search-icon, -.local-search-popup .popup-btn-close { - display: inline-block; - font-size: 18px; - color: #999; - height: 36px; - width: 18px; - padding-left: 10px; - padding-right: 10px; -} -.local-search-popup .search-icon { - float: left; -} -.local-search-popup .popup-btn-close { - border-left: 1px solid #eee; - float: right; - cursor: pointer; -} -.local-search-popup #no-result { - position: absolute; - left: 50%; - top: 50%; - -webkit-transform: translate(-50%, -50%); - -webkit-transform: translate(-50%, -50%); - -moz-transform: translate(-50%, -50%); - -ms-transform: translate(-50%, -50%); - -o-transform: translate(-50%, -50%); - transform: translate(-50%, -50%); - color: #ccc; -} -.site-uv, -.site-pv, -.page-pv { - display: inline-block; -} -.site-uv .busuanzi-value, -.site-pv .busuanzi-value, -.page-pv .busuanzi-value { - margin: 0 5px; -} -.site-uv { - margin-right: 10px; -} -.site-uv::after { - content: "|"; - padding-left: 10px; -} -.page-archive .archive-page-counter { - position: relative; - top: 3px; - left: 20px; -} -@media (max-width: 767px) { - .page-archive .archive-page-counter { - top: 5px; - } -} -.page-archive .posts-collapse .archive-move-on { - position: absolute; - top: 11px; - left: 0; - margin-left: -6px; - width: 10px; - height: 10px; - opacity: 0.5; - background: #555; - border: 1px solid #fff; - border-radius: 50%; -} -.category-all-page .category-all-title { - text-align: center; -} -.category-all-page .category-all { - margin-top: 20px; -} -.category-all-page .category-list { - margin: 0; - padding: 0; - list-style: none; -} -.category-all-page .category-list-item { - margin: 5px 10px; -} -.category-all-page .category-list-count { - color: #bbb; -} -.category-all-page .category-list-count:before { - display: inline; - content: " ("; -} -.category-all-page .category-list-count:after { - display: inline; - content: ") "; -} -.category-all-page .category-list-child { - padding-left: 10px; -} -#schedule ul#event-list { - padding-left: 30px; -} -#schedule ul#event-list hr { - margin: 20px 0 45px 0 !important; - background: #222; -} -#schedule ul#event-list hr:after { - display: inline-block; - content: 'NOW'; - background: #222; - color: #fff; - font-weight: bold; - text-align: right; - padding: 0 5px; -} -#schedule ul#event-list li.event { - margin: 20px 0px; - background: #f9f9f9; - padding-left: 10px; - min-height: 40px; -} -#schedule ul#event-list li.event h2.event-summary { - margin: 0; - padding-bottom: 3px; -} -#schedule ul#event-list li.event h2.event-summary:before { - display: inline-block; - font-family: FontAwesome; - font-size: 8px; - content: '\f111'; - vertical-align: middle; - margin-right: 25px; - color: #bbb; -} -#schedule ul#event-list li.event span.event-relative-time { - display: inline-block; - font-size: 12px; - font-weight: 400; - padding-left: 12px; - color: #bbb; -} -#schedule ul#event-list li.event span.event-details { - display: block; - color: #bbb; - margin-left: 56px; - padding-top: 3px; - padding-bottom: 6px; - text-indent: -24px; - line-height: 18px; -} -#schedule ul#event-list li.event span.event-details:before { - text-indent: 0; - display: inline-block; - width: 14px; - font-family: FontAwesome; - text-align: center; - margin-right: 9px; - color: #bbb; -} -#schedule ul#event-list li.event span.event-details.event-location:before { - content: '\f041'; -} -#schedule ul#event-list li.event span.event-details.event-duration:before { - content: '\f017'; -} -#schedule ul#event-list li.event-past { - background: #fcfcfc; -} -#schedule ul#event-list li.event-past > * { - opacity: 0.6; -} -#schedule ul#event-list li.event-past h2.event-summary { - color: #bbb; -} -#schedule ul#event-list li.event-past h2.event-summary:before { - color: #dfdfdf; -} -#schedule ul#event-list li.event-now { - background: #222; - color: #fff; - padding: 15px 0 15px 10px; -} -#schedule ul#event-list li.event-now h2.event-summary:before { - -webkit-transform: scale(1.2); - -moz-transform: scale(1.2); - -ms-transform: scale(1.2); - -o-transform: scale(1.2); - transform: scale(1.2); - color: #fff; - animation: dot-flash 1s alternate infinite ease-in-out; -} -#schedule ul#event-list li.event-now * { - color: #fff !important; -} -@-moz-keyframes dot-flash { - from { - opacity: 1; - -webkit-transform: scale(1.1); - -moz-transform: scale(1.1); - -ms-transform: scale(1.1); - -o-transform: scale(1.1); - transform: scale(1.1); - } - to { - opacity: 0; - -webkit-transform: scale(1); - -moz-transform: scale(1); - -ms-transform: scale(1); - -o-transform: scale(1); - transform: scale(1); - } -} -@-webkit-keyframes dot-flash { - from { - opacity: 1; - -webkit-transform: scale(1.1); - -moz-transform: scale(1.1); - -ms-transform: scale(1.1); - -o-transform: scale(1.1); - transform: scale(1.1); - } - to { - opacity: 0; - -webkit-transform: scale(1); - -moz-transform: scale(1); - -ms-transform: scale(1); - -o-transform: scale(1); - transform: scale(1); - } -} -@-o-keyframes dot-flash { - from { - opacity: 1; - -webkit-transform: scale(1.1); - -moz-transform: scale(1.1); - -ms-transform: scale(1.1); - -o-transform: scale(1.1); - transform: scale(1.1); - } - to { - opacity: 0; - -webkit-transform: scale(1); - -moz-transform: scale(1); - -ms-transform: scale(1); - -o-transform: scale(1); - transform: scale(1); - } -} -@keyframes dot-flash { - from { - opacity: 1; - -webkit-transform: scale(1.1); - -moz-transform: scale(1.1); - -ms-transform: scale(1.1); - -o-transform: scale(1.1); - transform: scale(1.1); - } - to { - opacity: 0; - -webkit-transform: scale(1); - -moz-transform: scale(1); - -ms-transform: scale(1); - -o-transform: scale(1); - transform: scale(1); - } -} -.page-post-detail .sidebar-toggle-line { - background: #fc6423; -} -.page-post-detail .comments { - overflow: hidden; -} -.header { - position: relative; - margin: 0 auto; - width: 75%; -} -@media (min-width: 768px) and (max-width: 991px) { - .header { - width: auto; - } -} -@media (max-width: 767px) { - .header { - width: auto; - } -} -.header-inner { - position: absolute; - top: 0; - overflow: hidden; - padding: 0; - width: 240px; - background: #fff; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12); - border-radius: initial; -} -@media (min-width: 1600px) { - .container .header-inner { - width: 240px; - } -} -@media (min-width: 768px) and (max-width: 991px) { - .header-inner { - position: relative; - width: auto; - border-radius: initial; - } -} -@media (max-width: 767px) { - .header-inner { - position: relative; - width: auto; - border-radius: initial; - } -} -.main:before, -.main:after { - content: " "; - display: table; -} -.main:after { - clear: both; -} -@media (min-width: 768px) and (max-width: 991px) { - .main { - padding-bottom: 100px; - } -} -@media (max-width: 767px) { - .main { - padding-bottom: 100px; - } -} -.container .main-inner { - width: 75%; -} -@media (min-width: 768px) and (max-width: 991px) { - .container .main-inner { - width: auto; - } -} -@media (max-width: 767px) { - .container .main-inner { - width: auto; - } -} -.content-wrap { - float: right; - box-sizing: border-box; - padding: 40px; - width: calc(100% - 252px); - background: #fff; - min-height: 700px; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12); - border-radius: initial; -} -@media (min-width: 768px) and (max-width: 991px) { - .content-wrap { - width: 100%; - padding: 20px; - border-radius: initial; - } -} -@media (max-width: 767px) { - .content-wrap { - width: 100%; - padding: 20px; - min-height: auto; - border-radius: initial; - } -} -.sidebar { - position: static; - float: left; - margin-top: 300px; - width: 240px; - background: #eee; - box-shadow: none; -} -@media (min-width: 768px) and (max-width: 991px) { - .sidebar { - display: none; - } -} -@media (max-width: 767px) { - .sidebar { - display: none; - } -} -.sidebar-toggle { - display: none; -} -.footer-inner { - width: 75%; - padding-left: 260px; -} -@media (min-width: 768px) and (max-width: 991px) { - .footer-inner { - width: auto; - padding-left: 0 !important; - padding-right: 0 !important; - } -} -@media (max-width: 767px) { - .footer-inner { - width: auto; - padding-left: 0 !important; - padding-right: 0 !important; - } -} -.sidebar-position-right .header-inner { - right: 0; -} -.sidebar-position-right .content-wrap { - float: left; -} -.sidebar-position-right .sidebar { - float: right; -} -.sidebar-position-right .footer-inner { - padding-left: 0; - padding-right: 260px; -} -.site-brand-wrapper { - position: relative; -} -.site-meta { - padding: 20px 0; - color: #fff; - background: #222; -} -@media (min-width: 768px) and (max-width: 991px) { - .site-meta { - box-shadow: 0 0 16px rgba(0,0,0,0.5); - } -} -@media (max-width: 767px) { - .site-meta { - box-shadow: 0 0 16px rgba(0,0,0,0.5); - } -} -.brand { - padding: 0; - background: none; -} -.brand:hover { - color: #fff; -} -.site-subtitle { - margin: 10px 10px 0; - font-weight: initial; -} -.site-search form { - display: none; -} -.site-nav { - border-top: none; -} -@media (min-width: 768px) and (max-width: 991px) { - .site-nav { - display: none !important; - } -} -@media (min-width: 768px) and (max-width: 991px) { - .site-nav-on { - display: block !important; - } -} -.menu .menu-item { - display: block; - margin: 0; -} -.menu .menu-item a { - position: relative; - box-sizing: border-box; - padding: 5px 20px; - text-align: left; - line-height: inherit; - transition-property: background-color; - transition-duration: 0.2s; - transition-timing-function: ease-in-out; - transition-delay: 0s; -} -.menu .menu-item a:hover, -.menu-item-active a { - background: #f9f9f9; - border-bottom-color: #fff; -} -.menu .menu-item br { - display: none; -} -.menu-item-active a:after { - content: " "; - position: absolute; - top: 50%; - margin-top: -3px; - right: 15px; - width: 6px; - height: 6px; - border-radius: 50%; - background-color: #bbb; -} -.btn-bar { - background-color: #fff; -} -.site-nav-toggle { - left: 20px; - top: 50%; - -webkit-transform: translateY(-50%); - -webkit-transform: translateY(-50%); - -moz-transform: translateY(-50%); - -ms-transform: translateY(-50%); - -o-transform: translateY(-50%); - transform: translateY(-50%); -} -@media (min-width: 768px) and (max-width: 991px) { - .site-nav-toggle { - display: block; - } -} -.use-motion .sidebar .motion-element { - opacity: 1; -} -.sidebar { - margin-left: -100%; - right: auto; - bottom: auto; - -webkit-transform: none; -} -.sidebar-inner { - box-sizing: border-box; - width: 240px; - color: #555; - background: #fff; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; -} -.sidebar-inner.affix { - position: fixed; - top: 12px; -} -.sidebar-inner.affix-bottom { - position: absolute; -} -.site-overview { - text-align: left; -} -.site-author:before, -.site-author:after { - content: " "; - display: table; -} -.site-author:after { - clear: both; -} -.sidebar a { - color: #555; -} -.sidebar a:hover { - color: #222; -} -.site-state-item { - padding: 0 10px; -} -.links-of-author-item a:before { - display: none; -} -.links-of-author-item a { - border-bottom: none; - text-decoration: underline; -} -.feed-link { - border-top: 1px dotted #ccc; - border-bottom: 1px dotted #ccc; - text-align: center; -} -.feed-link a { - display: block; - color: #fc6423; - border: none; -} -.feed-link a:hover { - background: none; - color: #e34603; -} -.feed-link a:hover i { - color: #e34603; -} -.links-of-author { - display: flex; - flex-wrap: wrap; - justify-content: center; -} -.links-of-author-item { - margin: 5px 0 0; - width: 50%; -} -.links-of-author-item a { - max-width: 216px; - box-sizing: border-box; - display: inline-block; - margin-right: 0; - margin-bottom: 0; - padding: 0 5px; - overflow: hidden; - white-space: nowrap; - text-overflow: ellipsis; -} -.links-of-author-item a { - display: block; - text-decoration: none; -} -.links-of-author-item a:hover { - border-radius: 4px; - background: #eee; -} -.links-of-author-item .fa { - margin-right: 2px; - font-size: 16px; -} -.links-of-author-item .fa-globe { - font-size: 15px; -} -.links-of-blogroll { - text-align: center; - margin-top: 20px; - padding: 3px 0 0; - border-top: 1px dotted #ccc; -} -.links-of-blogroll-title { - margin-top: 0; -} -.links-of-blogroll-item { - padding: 0; -} -.links-of-blogroll-inline:before, -.links-of-blogroll-inline:after { - content: " "; - display: table; -} -.links-of-blogroll-inline:after { - clear: both; -} -.links-of-blogroll-inline .links-of-blogroll-item { - margin: 5px 0 0; - width: 50%; - display: inline-block; - width: unset; -} -.links-of-blogroll-inline .links-of-blogroll-item a { - max-width: 216px; - box-sizing: border-box; - display: inline-block; - margin-right: 0; - margin-bottom: 0; - padding: 0 5px; - overflow: hidden; - white-space: nowrap; - text-overflow: ellipsis; -} -.content-wrap { - padding: initial; - background: initial; - box-shadow: initial; - border-radius: initial; -} -.post-block { - padding: 40px; - background: #fff; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12); - border-radius: initial; -} -#posts > article + article .post-block { - margin-top: 12px; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; -} -.comments { - padding: 40px; - margin: initial; - margin-top: 12px; - background: #fff; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; -} -.posts-expand { - padding-top: initial; -} -.post-nav-divider { - width: 4%; -} -.post-nav-item { - width: 48%; -} -.post-eof, -.post-spread { - display: none !important; -} -.pagination { - margin: 12px 0 0; - border-top: initial; - background: #fff; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; - padding: 10px 0 10px; -} -.pagination .prev, -.pagination .next, -.pagination .page-number { - margin-bottom: initial; - top: initial; -} -.main { - padding-bottom: initial; -} -.footer { - bottom: auto; -} -.post-header h1, -.post-header h2 { - margin: initial; -} -.posts-expand .post-title-link { - line-height: inherit; -} -.posts-expand .post-title { - font-size: 1.7em; -} -.post-body h1 { - font-size: 1.6em; - border-bottom: 1px solid #eee; -} -.post-body h2 { - font-size: 1.45em; - border-bottom: 1px solid #eee; -} -.post-body h3 { - font-size: 1.3em; - border-bottom: 1px dotted #eee; -} -.post-body h4 { - font-size: 1.2em; -} -.post-body h5 { - font-size: 1.07em; -} -.post-body h6 { - font-size: 1.03em; -} -@media (min-width: 768px) and (max-width: 991px) { - .content-wrap { - padding: 10px; - } - .posts-expand { - margin: initial; - } - .posts-expand .post-button { - margin-top: 20px; - } - .post-block { - padding: 20px; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; - } - #posts > article + article .post-block { - margin-top: 10px; - } - .comments { - margin-top: 10px; - padding: 10px 20px; - } - .pagination { - margin: 10px 0 0; - } -} -@media (max-width: 767px) { - .content-wrap { - padding: 8px; - } - .posts-expand { - margin: initial; - } - .posts-expand .post-button { - margin-top: 12px; - } - .posts-expand img { - padding: initial !important; - } - .post-block { - padding: 12px; - min-height: auto; - box-shadow: 0 2px 2px 0 rgba(0,0,0,0.12), 0 3px 1px -2px rgba(0,0,0,0.06), 0 1px 5px 0 rgba(0,0,0,0.12), 0 -1px 0.5px 0 rgba(0,0,0,0.09); - border-radius: initial; - } - #posts > article + article .post-block { - margin-top: 8px; - } - .comments { - margin-top: 8px; - padding: 0 12px; - } - .pagination { - margin: 8px 0 0; - } -} diff --git a/index.html b/index.html deleted file mode 100644 index 150b492..0000000 --- a/index.html +++ /dev/null @@ -1,2312 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/lib/fastclick/README.html b/lib/fastclick/README.html deleted file mode 100644 index c9ab89c..0000000 --- a/lib/fastclick/README.html +++ /dev/null @@ -1,70 +0,0 @@ -

FastClick

FastClick is a simple, easy-to-use library for eliminating the 300ms delay between a physical tap and the firing of a click event on mobile browsers. The aim is to make your application feel less laggy and more responsive while avoiding any interference with your current logic.

-

FastClick is developed by FT Labs, part of the Financial Times.

-

Explication en français.

-

日本語で説明

-

Why does the delay exist?

According to Google:

-
-

…mobile browsers will wait approximately 300ms from the time that you tap the button to fire the click event. The reason for this is that the browser is waiting to see if you are actually performing a double tap.

-
-

Compatibility

The library has been deployed as part of the FT Web App and is tried and tested on the following mobile browsers:

- -

When it isn’t needed

FastClick doesn’t attach any listeners on desktop browsers.

-

Chrome 32+ on Android with width=device-width in the viewport meta tag doesn’t have a 300ms delay, therefore listeners aren’t attached.

-
<meta name="viewport" content="width=device-width, initial-scale=1">
-
-

Same goes for Chrome on Android (all versions) with user-scalable=no in the viewport meta tag. But be aware that user-scalable=no also disables pinch zooming, which may be an accessibility concern.

-

For IE11+, you can use touch-action: manipulation; to disable double-tap-to-zoom on certain elements (like links and buttons). For IE10 use -ms-touch-action: manipulation.

-

Usage

Include fastclick.js in your JavaScript bundle or add it to your HTML page like this:

-
<script type='application/javascript' src='/path/to/fastclick.js'></script>
-
-

The script must be loaded prior to instantiating FastClick on any element of the page.

-

To instantiate FastClick on the body, which is the recommended method of use:

-
if ('addEventListener' in document) {
-    document.addEventListener('DOMContentLoaded', function() {
-        FastClick.attach(document.body);
-    }, false);
-}
-
-

Or, if you’re using jQuery:

-
$(function() {
-    FastClick.attach(document.body);
-});
-
-

If you’re using Browserify or another CommonJS-style module system, the FastClick.attach function will be returned when you call require('fastclick'). As a result, the easiest way to use FastClick with these loaders is as follows:

-
var attachFastClick = require('fastclick');
-attachFastClick(document.body);
-
-

Minified

Run make to build a minified version of FastClick using the Closure Compiler REST API. The minified file is saved to build/fastclick.min.js or you can download a pre-minified version.

-

Note: the pre-minified version is built using our build service which exposes the FastClick object through Origami.fastclick and will have the Browserify/CommonJS API (see above).

-
var attachFastClick = Origami.fastclick;
-attachFastClick(document.body);
-
-

AMD

FastClick has AMD (Asynchronous Module Definition) support. This allows it to be lazy-loaded with an AMD loader, such as RequireJS. Note that when using the AMD style require, the full FastClick object will be returned, not FastClick.attach

-
var FastClick = require('fastclick');
-FastClick.attach(document.body, options);
-
-

Package managers

You can install FastClick using Component, npm or Bower.

-

For Ruby, there’s a third-party gem called fastclick-rails. For .NET there’s a NuGet package.

-

Advanced

Ignore certain elements with needsclick

Sometimes you need FastClick to ignore certain elements. You can do this easily by adding the needsclick class.

-
<a class="needsclick">Ignored by FastClick</a>
-
-

Use case 1: non-synthetic click required

Internally, FastClick uses document.createEvent to fire a synthetic click event as soon as touchend is fired by the browser. It then suppresses the additional click event created by the browser after that. In some cases, the non-synthetic click event created by the browser is required, as described in the triggering focus example.

-

This is where the needsclick class comes in. Add the class to any element that requires a non-synthetic click.

-

Use case 2: Twitter Bootstrap 2.2.2 dropdowns

Another example of when to use the needsclick class is with dropdowns in Twitter Bootstrap 2.2.2. Bootstrap add its own touchstart listener for dropdowns, so you want to tell FastClick to ignore those. If you don’t, touch devices will automatically close the dropdown as soon as it is clicked, because both FastClick and Bootstrap execute the synthetic click, one opens the dropdown, the second closes it immediately after.

-
<a class="dropdown-toggle needsclick" data-toggle="dropdown">Dropdown</a>
-
-

Examples

FastClick is designed to cope with many different browser oddities. Here are some examples to illustrate this:

- -

Tests

There are no automated tests. The files in tests/ are manual reduced test cases. We’ve had a think about how best to test these cases, but they tend to be very browser/device specific and sometimes subjective which means it’s not so trivial to test.

-

Credits and collaboration

FastClick is maintained by Rowan Beentje, Matthew Caruana Galizia and Matthew Andrews at FT Labs. All open source code released by FT Labs is licenced under the MIT licence. We welcome comments, feedback and suggestions. Please feel free to raise an issue or pull request.

diff --git a/lib/fastclick/bower.json b/lib/fastclick/bower.json deleted file mode 100644 index cdbbf93..0000000 --- a/lib/fastclick/bower.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"fastclick","main":"lib/fastclick.js","ignore":["**/.*","component.json","package.json","Makefile","tests","examples"]} \ No newline at end of file diff --git a/lib/font-awesome/bower.json b/lib/font-awesome/bower.json deleted file mode 100644 index 772570a..0000000 --- a/lib/font-awesome/bower.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"font-awesome","description":"Font Awesome","keywords":[],"homepage":"http://fontawesome.io","dependencies":{},"devDependencies":{},"license":["OFL-1.1","MIT","CC-BY-3.0"],"main":["less/font-awesome.less","scss/font-awesome.scss"],"ignore":["*/.*","*.json","src","*.yml","Gemfile","Gemfile.lock","*.md"]} \ No newline at end of file diff --git a/lib/jquery_lazyload/CONTRIBUTING.html b/lib/jquery_lazyload/CONTRIBUTING.html deleted file mode 100644 index c732c08..0000000 --- a/lib/jquery_lazyload/CONTRIBUTING.html +++ /dev/null @@ -1,22 +0,0 @@ -

Contributing to Lazy Load

Only one feature or change per pull request

Make pull requests only one feature or change at the time. For example you have fixed a bug. You also have optimized some code. Optimization is not related to a bug. These should be submitted as separate pull requests. This way I can easily choose what to include. It is also easier to understand the code changes. Commit messages should be descriptive and full sentences.

-

Do not commit minified versions. Do not touch the version number. Make the pull requests against 1.9.x branch.

-

Write meaningful commit messages

Proper commit message is full sentence. It starts with capital letter but does not end with period. Headlines do not end with period. The GitHub default Update filename.js is not enough. When needed include also longer explanation what the commit does.

-
Capitalized, short (50 chars or less) summary
-
-More detailed explanatory text, if necessary.  Wrap it to about 72
-characters or so.  In some contexts, the first line is treated as the
-subject of an email and the rest of the text as the body.  The blank
-line separating the summary from the body is critical (unless you omit
-the body entirely); tools like rebase can get confused if you run the
-two together.
-

When in doubt see Tim Pope’s blogpost A Note About Git Commit Messages

-

Follow the existing coding standards

When contributing to open source project it is polite to follow the original authors coding standars. They might be different than yours. It is not a holy war. Just follow then original.

-
var snake_case = "something";
-
-function camelCase(options) {
-}
-
-if (true !== false) {
-    console.log("here be dragons");
-}
-
diff --git a/lib/jquery_lazyload/README.html b/lib/jquery_lazyload/README.html deleted file mode 100644 index a24769b..0000000 --- a/lib/jquery_lazyload/README.html +++ /dev/null @@ -1,20 +0,0 @@ -

Lazy Load Plugin for jQuery

Lazy Load delays loading of images in long web pages. Images outside of viewport wont be loaded before user scrolls to them. This is opposite of image preloading.

-

Using Lazy Load on long web pages containing many large images makes the page load faster. Browser will be in ready state after loading visible images. In some cases it can also help to reduce server load.

-

Lazy Load is inspired by YUI ImageLoader Utility by Matt Mlinac.

-

How to Use?

Lazy Load depends on jQuery. Include them both in end of your HTML code:

-
<script src="jquery.js" type="text/javascript"></script>
-<script src="jquery.lazyload.js" type="text/javascript"></script>
-
-

You must alter your HTML code. URL of the real image must be put into data-original attribute. It is good idea to give Lazy Loaded image a specific class. This way you can easily control which images plugin is binded to. Note that you should have width and height attributes in your image tag.

-
<img class="lazy" data-original="img/example.jpg" width="640" height="480">
-
-

then in your code do:

-
$("img.lazy").lazyload();
-
-

This causes all images of class lazy to be lazy loaded.

-

More information on Lazy Load project page.

-

Install

You can install with bower or npm.

-
$ bower install jquery.lazyload
-$ npm install jquery-lazyload
-
-

License

All code licensed under the MIT License. All images licensed under Creative Commons Attribution 3.0 Unported License. In other words you are basically free to do whatever you want. Just don’t remove my name from the source.

diff --git a/lib/jquery_lazyload/bower.json b/lib/jquery_lazyload/bower.json deleted file mode 100644 index 6ffd9bc..0000000 --- a/lib/jquery_lazyload/bower.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"jquery_lazyload","version":"1.9.4","homepage":"http://www.appelsiini.net/projects/lazyload","authors":["Mika Tuupola "],"description":"jQuery plugin for lazy loading images","main":["jquery.lazyload.js","jquery.scrollstop.js"],"license":"MIT","ignore":["**/.*","**/*.min.js","**/*.html","**/*.textile","Gruntfile.js","lazyload.jquery.json","package.json","node_modules","bower_components","test","img"]} \ No newline at end of file diff --git a/lib/velocity/bower.json b/lib/velocity/bower.json deleted file mode 100644 index bf66fe8..0000000 --- a/lib/velocity/bower.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"velocity","version":"1.2.2","homepage":"http://velocityjs.org","authors":[{"name":"Julian Shapiro","homepage":"http://julian.com/"}],"description":"Accelerated JavaScript animation.","main":["./velocity.js","./velocity.ui.js"],"keywords":["animation","jquery","animate","lightweight","smooth","ui","velocity.js","velocityjs","javascript"],"license":"MIT","ignore":["*.json","!/bower.json","LICENSE","*.md"],"dependencies":{"jquery":"*"},"repository":{"type":"git","url":"http://github.com/julianshapiro/velocity.git"}} \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..41baf37 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,3839 @@ +{ + "name": "hexo-site", + "version": "0.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "JSONStream": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.5.tgz", + "integrity": "sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ==", + "requires": { + "jsonparse": "^1.2.0", + "through": ">=2.2.7 <3" + } + }, + "a-sync-waterfall": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/a-sync-waterfall/-/a-sync-waterfall-1.0.1.tgz", + "integrity": "sha512-RYTOHHdWipFUliRFMCS4X2Yn2X8M87V/OpSqWzKKOGhzqyUxzyVmhHDH9sAvG+ZuQf/TAOFsLCpMw09I1ufUnA==" + }, + "abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" + }, + "accepts": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.5.tgz", + "integrity": "sha1-63d99gEXI6OxTopywIBcjoZ0a9I=", + "requires": { + "mime-types": "~2.1.18", + "negotiator": "0.6.1" + } + }, + "align-text": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/align-text/-/align-text-0.1.4.tgz", + "integrity": "sha1-DNkKVhCT810KmSVsIrcGlDP60Rc=", + "requires": { + "kind-of": "^3.0.2", + "longest": "^1.0.1", + "repeat-string": "^1.5.2" + } + }, + "amdefine": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", + "integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU=" + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "requires": { + "color-convert": "^1.9.0" + } + }, + "anymatch": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-1.3.2.tgz", + "integrity": "sha512-0XNayC8lTHQ2OI8aljNCN3sSx6hsr/1+rlcDAotXJR7C1oZZHCNsfpbKwMjRA3Uqb5tF1Rae2oloTr4xpq+WjA==", + "requires": { + "micromatch": "^2.1.5", + "normalize-path": "^2.0.0" + } + }, + "archy": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", + "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=" + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "^1.0.1" + } + }, + "arr-flatten": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", + "integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==" + }, + "arr-union": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", + "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=" + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "asap": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", + "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" + }, + "assign-symbols": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", + "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=" + }, + "async": { + "version": "0.2.10", + "resolved": "https://registry.npmjs.org/async/-/async-0.2.10.tgz", + "integrity": "sha1-trvgsGdLnXGXCMo43owjfLUmw9E=" + }, + "async-each": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.1.tgz", + "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0=" + }, + "atob": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", + "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==" + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" + }, + "base": { + "version": "0.11.2", + "resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", + "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", + "requires": { + "cache-base": "^1.0.1", + "class-utils": "^0.3.5", + "component-emitter": "^1.2.1", + "define-property": "^1.0.0", + "isobject": "^3.0.1", + "mixin-deep": "^1.2.0", + "pascalcase": "^0.1.1" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "requires": { + "is-descriptor": "^1.0.0" + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "requires": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + } + } + }, + "basic-auth": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-2.0.1.tgz", + "integrity": "sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg==", + "requires": { + "safe-buffer": "5.1.2" + } + }, + "binary-extensions": { + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.13.0.tgz", + "integrity": "sha512-EgmjVLMn22z7eGGv3kcnHwSnJXmFHjISTY9E/S5lIcTD3Oxw05QTcBLNkJFzcb3cNueUdF/IN4U+d78V0zO8Hw==" + }, + "bluebird": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.3.tgz", + "integrity": "sha512-/qKPUQlaW1OyR51WeCPBvRnAlnZFUJkCSG5HzGnuIqhgyJtF+T94lFnn33eiazjRm2LAHVy2guNnaq48X9SJuw==" + }, + "boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "^1.8.1", + "preserve": "^0.2.0", + "repeat-element": "^1.1.2" + } + }, + "browser-fingerprint": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/browser-fingerprint/-/browser-fingerprint-0.0.1.tgz", + "integrity": "sha1-jfPNyiW/fVs1QtYVRdcwBT/OYEo=" + }, + "bytes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", + "integrity": "sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg=" + }, + "cache-base": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", + "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", + "requires": { + "collection-visit": "^1.0.0", + "component-emitter": "^1.2.1", + "get-value": "^2.0.6", + "has-value": "^1.0.0", + "isobject": "^3.0.1", + "set-value": "^2.0.0", + "to-object-path": "^0.3.0", + "union-value": "^1.0.0", + "unset-value": "^1.0.0" + }, + "dependencies": { + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "camel-case": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/camel-case/-/camel-case-3.0.0.tgz", + "integrity": "sha1-yjw2iKTpzzpM2nd9xNy8cTJJz3M=", + "requires": { + "no-case": "^2.2.0", + "upper-case": "^1.1.1" + } + }, + "camelcase": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-2.1.1.tgz", + "integrity": "sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8=" + }, + "center-align": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/center-align/-/center-align-0.1.3.tgz", + "integrity": "sha1-qg0yYptu6XIgBBHL1EYckHvCt60=", + "requires": { + "align-text": "^0.1.3", + "lazy-cache": "^1.0.3" + } + }, + "chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + } + }, + "cheerio": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-0.22.0.tgz", + "integrity": "sha1-qbqoYKP5tZWmuBsahocxIe06Jp4=", + "requires": { + "css-select": "~1.2.0", + "dom-serializer": "~0.1.0", + "entities": "~1.1.1", + "htmlparser2": "^3.9.1", + "lodash.assignin": "^4.0.9", + "lodash.bind": "^4.1.4", + "lodash.defaults": "^4.0.1", + "lodash.filter": "^4.4.0", + "lodash.flatten": "^4.2.0", + "lodash.foreach": "^4.3.0", + "lodash.map": "^4.4.0", + "lodash.merge": "^4.4.0", + "lodash.pick": "^4.2.1", + "lodash.reduce": "^4.4.0", + "lodash.reject": "^4.4.0", + "lodash.some": "^4.4.0" + } + }, + "chokidar": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-1.7.0.tgz", + "integrity": "sha1-eY5ol3gVHIB2tLNg5e3SjNortGg=", + "requires": { + "anymatch": "^1.3.0", + "async-each": "^1.0.0", + "fsevents": "^1.0.0", + "glob-parent": "^2.0.0", + "inherits": "^2.0.1", + "is-binary-path": "^1.0.0", + "is-glob": "^2.0.0", + "path-is-absolute": "^1.0.0", + "readdirp": "^2.0.0" + } + }, + "class-utils": { + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/class-utils/-/class-utils-0.3.6.tgz", + "integrity": "sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==", + "requires": { + "arr-union": "^3.1.0", + "define-property": "^0.2.5", + "isobject": "^3.0.0", + "static-extend": "^0.1.1" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "^0.1.0" + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "cliui": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-3.2.0.tgz", + "integrity": "sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0=", + "requires": { + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wrap-ansi": "^2.0.0" + }, + "dependencies": { + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + } + } + }, + "code-point-at": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" + }, + "collection-visit": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/collection-visit/-/collection-visit-1.0.0.tgz", + "integrity": "sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA=", + "requires": { + "map-visit": "^1.0.0", + "object-visit": "^1.0.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" + }, + "command-exists": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/command-exists/-/command-exists-1.2.8.tgz", + "integrity": "sha512-PM54PkseWbiiD/mMsbvW351/u+dafwTJ0ye2qB60G1aGQP9j3xK2gmMDc+R34L3nDtx4qMCitXT75mkbkGJDLw==" + }, + "component-emitter": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", + "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=" + }, + "compressible": { + "version": "2.0.16", + "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.16.tgz", + "integrity": "sha512-JQfEOdnI7dASwCuSPWIeVYwc/zMsu/+tRhoUvEfXz2gxOA2DNjmG5vhtFdBlhWPPGo+RdT9S3tgc/uH5qgDiiA==", + "requires": { + "mime-db": ">= 1.38.0 < 2" + } + }, + "compression": { + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/compression/-/compression-1.7.3.tgz", + "integrity": "sha512-HSjyBG5N1Nnz7tF2+O7A9XUhyjru71/fwgNb7oIsEVHR0WShfs2tIS/EySLgiTe98aOK18YDlMXpzjCXY/n9mg==", + "requires": { + "accepts": "~1.3.5", + "bytes": "3.0.0", + "compressible": "~2.0.14", + "debug": "2.6.9", + "on-headers": "~1.0.1", + "safe-buffer": "5.1.2", + "vary": "~1.1.2" + } + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" + }, + "connect": { + "version": "3.6.6", + "resolved": "https://registry.npmjs.org/connect/-/connect-3.6.6.tgz", + "integrity": "sha1-Ce/2xVr3I24TcTWnJXSFi2eG9SQ=", + "requires": { + "debug": "2.6.9", + "finalhandler": "1.1.0", + "parseurl": "~1.3.2", + "utils-merge": "1.0.1" + } + }, + "copy-descriptor": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz", + "integrity": "sha1-Z29us8OZl8LuGsOpJP1hJHSPV40=" + }, + "core-js": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-1.2.7.tgz", + "integrity": "sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY=" + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" + }, + "cross-spawn": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", + "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", + "requires": { + "lru-cache": "^4.0.1", + "which": "^1.2.9" + } + }, + "css-parse": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/css-parse/-/css-parse-1.7.0.tgz", + "integrity": "sha1-Mh9s9zeCpv91ERE5D8BeLGV9jJs=" + }, + "css-select": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-1.2.0.tgz", + "integrity": "sha1-KzoRBTnFNV8c2NMUYj6HCxIeyFg=", + "requires": { + "boolbase": "~1.0.0", + "css-what": "2.1", + "domutils": "1.5.1", + "nth-check": "~1.0.1" + } + }, + "css-what": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-2.1.3.tgz", + "integrity": "sha512-a+EPoD+uZiNfh+5fxw2nO9QwFa6nJe2Or35fGY6Ipw1R3R4AGz1d1TEZrCegvw2YTmZ0jXirGYlzxxpYSHwpEg==" + }, + "cuid": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/cuid/-/cuid-1.3.8.tgz", + "integrity": "sha1-S4deCWm612T37AcGz0T1+wgx9rc=", + "requires": { + "browser-fingerprint": "0.0.1", + "core-js": "^1.1.1", + "node-fingerprint": "0.0.2" + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "requires": { + "ms": "2.0.0" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" + }, + "decode-uri-component": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.0.tgz", + "integrity": "sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU=" + }, + "define-property": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-2.0.2.tgz", + "integrity": "sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==", + "requires": { + "is-descriptor": "^1.0.2", + "isobject": "^3.0.1" + }, + "dependencies": { + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "requires": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + } + } + }, + "depd": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", + "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" + }, + "destroy": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", + "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" + }, + "dom-serializer": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.1.tgz", + "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==", + "requires": { + "domelementtype": "^1.3.0", + "entities": "^1.1.1" + } + }, + "domelementtype": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz", + "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==" + }, + "domhandler": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz", + "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", + "requires": { + "domelementtype": "1" + } + }, + "domutils": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.5.1.tgz", + "integrity": "sha1-3NhIiib1Y9YQeeSMn3t+Mjc2gs8=", + "requires": { + "dom-serializer": "0", + "domelementtype": "1" + } + }, + "ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" + }, + "ejs": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/ejs/-/ejs-2.6.1.tgz", + "integrity": "sha512-0xy4A/twfrRCnkhfk8ErDi5DqdAsAqeGxht4xkCUrsvhhbQNs7E+4jV0CN7+NKIY0aHE72+XvqtBIXzD31ZbXQ==" + }, + "encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=" + }, + "entities": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==" + }, + "escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" + }, + "etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "^0.1.0" + } + }, + "expand-range": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz", + "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", + "requires": { + "fill-range": "^2.1.0" + } + }, + "extend-shallow": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-3.0.2.tgz", + "integrity": "sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg=", + "requires": { + "assign-symbols": "^1.0.0", + "is-extendable": "^1.0.1" + }, + "dependencies": { + "is-extendable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", + "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "requires": { + "is-plain-object": "^2.0.4" + } + } + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "^1.0.0" + } + }, + "filename-regex": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.1.tgz", + "integrity": "sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY=" + }, + "fill-range": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.4.tgz", + "integrity": "sha512-cnrcCbj01+j2gTG921VZPnHbjmdAf8oQV/iGeV2kZxGSyfYjjTyY79ErsK1WJWMpw6DaApEX72binqJE+/d+5Q==", + "requires": { + "is-number": "^2.1.0", + "isobject": "^2.0.0", + "randomatic": "^3.0.0", + "repeat-element": "^1.1.2", + "repeat-string": "^1.5.2" + } + }, + "finalhandler": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.0.tgz", + "integrity": "sha1-zgtoVbRYU+eRsvzGgARtiCU91/U=", + "requires": { + "debug": "2.6.9", + "encodeurl": "~1.0.1", + "escape-html": "~1.0.3", + "on-finished": "~2.3.0", + "parseurl": "~1.3.2", + "statuses": "~1.3.1", + "unpipe": "~1.0.0" + } + }, + "for-in": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", + "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=" + }, + "for-own": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/for-own/-/for-own-0.1.5.tgz", + "integrity": "sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4=", + "requires": { + "for-in": "^1.0.1" + } + }, + "fragment-cache": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/fragment-cache/-/fragment-cache-0.2.1.tgz", + "integrity": "sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk=", + "requires": { + "map-cache": "^0.2.2" + } + }, + "fresh": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" + }, + "fsevents": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.7.tgz", + "integrity": "sha512-Pxm6sI2MeBD7RdD12RYsqaP0nMiwx8eZBXCa6z2L+mRHm2DYrOYwihmhjpkdjUHwQhslWQjRpEgNq4XvBmaAuw==", + "optional": true, + "requires": { + "nan": "^2.9.2", + "node-pre-gyp": "^0.10.0" + }, + "dependencies": { + "abbrev": { + "version": "1.1.1", + "bundled": true, + "optional": true + }, + "ansi-regex": { + "version": "2.1.1", + "bundled": true + }, + "aproba": { + "version": "1.2.0", + "bundled": true, + "optional": true + }, + "are-we-there-yet": { + "version": "1.1.5", + "bundled": true, + "optional": true, + "requires": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "balanced-match": { + "version": "1.0.0", + "bundled": true + }, + "brace-expansion": { + "version": "1.1.11", + "bundled": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "chownr": { + "version": "1.1.1", + "bundled": true, + "optional": true + }, + "code-point-at": { + "version": "1.1.0", + "bundled": true + }, + "concat-map": { + "version": "0.0.1", + "bundled": true + }, + "console-control-strings": { + "version": "1.1.0", + "bundled": true + }, + "core-util-is": { + "version": "1.0.2", + "bundled": true, + "optional": true + }, + "debug": { + "version": "2.6.9", + "bundled": true, + "optional": true, + "requires": { + "ms": "2.0.0" + } + }, + "deep-extend": { + "version": "0.6.0", + "bundled": true, + "optional": true + }, + "delegates": { + "version": "1.0.0", + "bundled": true, + "optional": true + }, + "detect-libc": { + "version": "1.0.3", + "bundled": true, + "optional": true + }, + "fs-minipass": { + "version": "1.2.5", + "bundled": true, + "optional": true, + "requires": { + "minipass": "^2.2.1" + } + }, + "fs.realpath": { + "version": "1.0.0", + "bundled": true, + "optional": true + }, + "gauge": { + "version": "2.7.4", + "bundled": true, + "optional": true, + "requires": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "glob": { + "version": "7.1.3", + "bundled": true, + "optional": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "has-unicode": { + "version": "2.0.1", + "bundled": true, + "optional": true + }, + "iconv-lite": { + "version": "0.4.24", + "bundled": true, + "optional": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3" + } + }, + "ignore-walk": { + "version": "3.0.1", + "bundled": true, + "optional": true, + "requires": { + "minimatch": "^3.0.4" + } + }, + "inflight": { + "version": "1.0.6", + "bundled": true, + "optional": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.3", + "bundled": true + }, + "ini": { + "version": "1.3.5", + "bundled": true, + "optional": true + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "bundled": true, + "requires": { + "number-is-nan": "^1.0.0" + } + }, + "isarray": { + "version": "1.0.0", + "bundled": true, + "optional": true + }, + "minimatch": { + "version": "3.0.4", + "bundled": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "bundled": true + }, + "minipass": { + "version": "2.3.5", + "bundled": true, + "requires": { + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" + } + }, + "minizlib": { + "version": "1.2.1", + "bundled": true, + "optional": true, + "requires": { + "minipass": "^2.2.1" + } + }, + "mkdirp": { + "version": "0.5.1", + "bundled": true, + "requires": { + "minimist": "0.0.8" + } + }, + "ms": { + "version": "2.0.0", + "bundled": true, + "optional": true + }, + "needle": { + "version": "2.2.4", + "bundled": true, + "optional": true, + "requires": { + "debug": "^2.1.2", + "iconv-lite": "^0.4.4", + "sax": "^1.2.4" + } + }, + "node-pre-gyp": { + "version": "0.10.3", + "bundled": true, + "optional": true, + "requires": { + "detect-libc": "^1.0.2", + "mkdirp": "^0.5.1", + "needle": "^2.2.1", + "nopt": "^4.0.1", + "npm-packlist": "^1.1.6", + "npmlog": "^4.0.2", + "rc": "^1.2.7", + "rimraf": "^2.6.1", + "semver": "^5.3.0", + "tar": "^4" + } + }, + "nopt": { + "version": "4.0.1", + "bundled": true, + "optional": true, + "requires": { + "abbrev": "1", + "osenv": "^0.1.4" + } + }, + "npm-bundled": { + "version": "1.0.5", + "bundled": true, + "optional": true + }, + "npm-packlist": { + "version": "1.2.0", + "bundled": true, + "optional": true, + "requires": { + "ignore-walk": "^3.0.1", + "npm-bundled": "^1.0.1" + } + }, + "npmlog": { + "version": "4.1.2", + "bundled": true, + "optional": true, + "requires": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "bundled": true + }, + "object-assign": { + "version": "4.1.1", + "bundled": true, + "optional": true + }, + "once": { + "version": "1.4.0", + "bundled": true, + "requires": { + "wrappy": "1" + } + }, + "os-homedir": { + "version": "1.0.2", + "bundled": true, + "optional": true + }, + "os-tmpdir": { + "version": "1.0.2", + "bundled": true, + "optional": true + }, + "osenv": { + "version": "0.1.5", + "bundled": true, + "optional": true, + "requires": { + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" + } + }, + "path-is-absolute": { + "version": "1.0.1", + "bundled": true, + "optional": true + }, + "process-nextick-args": { + "version": "2.0.0", + "bundled": true, + "optional": true + }, + "rc": { + "version": "1.2.8", + "bundled": true, + "optional": true, + "requires": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "bundled": true, + "optional": true + } + } + }, + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "optional": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "rimraf": { + "version": "2.6.3", + "bundled": true, + "optional": true, + "requires": { + "glob": "^7.1.3" + } + }, + "safe-buffer": { + "version": "5.1.2", + "bundled": true + }, + "safer-buffer": { + "version": "2.1.2", + "bundled": true, + "optional": true + }, + "sax": { + "version": "1.2.4", + "bundled": true, + "optional": true + }, + "semver": { + "version": "5.6.0", + "bundled": true, + "optional": true + }, + "set-blocking": { + "version": "2.0.0", + "bundled": true, + "optional": true + }, + "signal-exit": { + "version": "3.0.2", + "bundled": true, + "optional": true + }, + "string-width": { + "version": "1.0.2", + "bundled": true, + "requires": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "optional": true, + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "bundled": true, + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-json-comments": { + "version": "2.0.1", + "bundled": true, + "optional": true + }, + "tar": { + "version": "4.4.8", + "bundled": true, + "optional": true, + "requires": { + "chownr": "^1.1.1", + "fs-minipass": "^1.2.5", + "minipass": "^2.3.4", + "minizlib": "^1.1.1", + "mkdirp": "^0.5.0", + "safe-buffer": "^5.1.2", + "yallist": "^3.0.2" + } + }, + "util-deprecate": { + "version": "1.0.2", + "bundled": true, + "optional": true + }, + "wide-align": { + "version": "1.1.3", + "bundled": true, + "optional": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "wrappy": { + "version": "1.0.2", + "bundled": true + }, + "yallist": { + "version": "3.0.3", + "bundled": true + } + } + }, + "get-value": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", + "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=" + }, + "glob": { + "version": "6.0.4", + "resolved": "https://registry.npmjs.org/glob/-/glob-6.0.4.tgz", + "integrity": "sha1-DwiGD2oVUSey+t1PnOJLGqtuTSI=", + "optional": true, + "requires": { + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "2 || 3", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-base": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/glob-base/-/glob-base-0.3.0.tgz", + "integrity": "sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q=", + "requires": { + "glob-parent": "^2.0.0", + "is-glob": "^2.0.0" + } + }, + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "requires": { + "is-glob": "^2.0.0" + } + }, + "graceful-fs": { + "version": "4.1.15", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz", + "integrity": "sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==" + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" + }, + "has-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", + "integrity": "sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc=", + "requires": { + "get-value": "^2.0.6", + "has-values": "^1.0.0", + "isobject": "^3.0.0" + }, + "dependencies": { + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "has-values": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-values/-/has-values-1.0.0.tgz", + "integrity": "sha1-lbC2P+whRmGab+V/51Yo1aOe/k8=", + "requires": { + "is-number": "^3.0.0", + "kind-of": "^4.0.0" + }, + "dependencies": { + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "kind-of": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", + "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "hexo": { + "version": "3.8.0", + "resolved": "https://registry.npmjs.org/hexo/-/hexo-3.8.0.tgz", + "integrity": "sha512-qMk0TZ+ErKMD25R+HMHFvbyTAcKszmGZYtQHT2pzVnZgitkJCShZ7b2qDbedtWBBizhutNbKkhQ4D3Dqivaviw==", + "requires": { + "abbrev": "^1.0.7", + "archy": "^1.0.0", + "bluebird": "^3.4.0", + "chalk": "^2.3.1", + "cheerio": "0.22.0", + "hexo-cli": "^1.1.0", + "hexo-front-matter": "^0.2.2", + "hexo-fs": "^0.2.0", + "hexo-i18n": "^0.2.1", + "hexo-log": "^0.2.0", + "hexo-util": "^0.6.3", + "js-yaml": "^3.6.1", + "lodash": "^4.17.5", + "minimatch": "^3.0.4", + "moment": "^2.19.4", + "moment-timezone": "^0.5.14", + "nunjucks": "^3.1.2", + "pretty-hrtime": "^1.0.2", + "resolve": "^1.5.0", + "strip-ansi": "^4.0.0", + "strip-indent": "^2.0.0", + "swig-extras": "0.0.1", + "swig-templates": "^2.0.2", + "text-table": "^0.2.0", + "tildify": "^1.2.0", + "titlecase": "^1.1.2", + "warehouse": "^2.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" + }, + "hexo-cli": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/hexo-cli/-/hexo-cli-1.1.0.tgz", + "integrity": "sha512-IWQPppwgmj1iBUcP5mpcMg3Tre6a8Qlr8ejXw6naZiJNSepSgh4mS3KiNPKDa2qQIgPDqJYJzNVFLw+RLA9CkA==", + "requires": { + "abbrev": "^1.0.7", + "bluebird": "^3.4.0", + "chalk": "^1.1.3", + "command-exists": "^1.2.0", + "hexo-fs": "^0.2.0", + "hexo-log": "^0.2.0", + "hexo-util": "^0.6.0", + "minimist": "^1.2.0", + "object-assign": "^4.1.0", + "resolve": "^1.5.0", + "tildify": "^1.2.0" + }, + "dependencies": { + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + } + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" + } + } + }, + "hexo-bunyan": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/hexo-bunyan/-/hexo-bunyan-1.0.0.tgz", + "integrity": "sha512-RymT8Ck+K77mLt9BEYNb4uyfC7RIQnU5N3laXowMrS28jj2h89VHJCOnhV00mmta4fHRqNa07kP1Hrn17nvMkQ==", + "requires": { + "moment": "^2.10.6", + "mv": "~2", + "safe-json-stringify": "~1" + } + }, + "hexo-front-matter": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/hexo-front-matter/-/hexo-front-matter-0.2.3.tgz", + "integrity": "sha1-x8qO9CDqNr2F6ECKLoyb9J76YF4=", + "requires": { + "js-yaml": "^3.6.1" + } + }, + "hexo-fs": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/hexo-fs/-/hexo-fs-0.2.3.tgz", + "integrity": "sha512-rLB1rMVUW3csAljvJgHfyjemL0BrmcUZfBf9hJe6S0pA53igFa3ON0PFwomvoLs1Wdmjs9Awnw9Tru4PjWFSlQ==", + "requires": { + "bluebird": "^3.4.0", + "chokidar": "^1.5.2", + "escape-string-regexp": "^1.0.5", + "graceful-fs": "^4.1.4" + } + }, + "hexo-generator-archive": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/hexo-generator-archive/-/hexo-generator-archive-0.1.5.tgz", + "integrity": "sha512-jPbMtibqkJnAX3hCwhYhK3r6cqy9OKQsVEScjk7LDok+iPmFmkKCNdU/OccxGe1CWAZpT+ta4+LknwNeHG2G4w==", + "requires": { + "hexo-pagination": "0.0.2", + "object-assign": "^2.0.0" + }, + "dependencies": { + "object-assign": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz", + "integrity": "sha1-Q8NuXVaf+OSBbE76i+AtJpZ8GKo=" + } + } + }, + "hexo-generator-category": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/hexo-generator-category/-/hexo-generator-category-0.1.3.tgz", + "integrity": "sha1-uealhiUwqDvdfaTIGcG58+TMtLI=", + "requires": { + "hexo-pagination": "0.0.2", + "object-assign": "^2.0.0" + }, + "dependencies": { + "object-assign": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz", + "integrity": "sha1-Q8NuXVaf+OSBbE76i+AtJpZ8GKo=" + } + } + }, + "hexo-generator-index": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/hexo-generator-index/-/hexo-generator-index-0.2.1.tgz", + "integrity": "sha1-kEIin8rHmq9wBXXaGTMr8/fuXF0=", + "requires": { + "hexo-pagination": "0.0.2", + "object-assign": "^4.0.1" + } + }, + "hexo-generator-tag": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/hexo-generator-tag/-/hexo-generator-tag-0.2.0.tgz", + "integrity": "sha1-xXFYRrtB5X2cIMHWbX2yGhq/emI=", + "requires": { + "hexo-pagination": "0.0.2", + "object-assign": "^4.0.1" + } + }, + "hexo-i18n": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/hexo-i18n/-/hexo-i18n-0.2.1.tgz", + "integrity": "sha1-hPFBQyvwnYtVjth4xygWS20c1t4=", + "requires": { + "sprintf-js": "^1.0.2" + } + }, + "hexo-log": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/hexo-log/-/hexo-log-0.2.0.tgz", + "integrity": "sha512-fzoc+GQexxPPILTjoOQILnA3ZG2MFgqMBVel4xvJ11pXptw9+f97ynTgDAExXafyp9Nz2ChXRuqlCYgPtZSlxQ==", + "requires": { + "chalk": "^1.1.1", + "hexo-bunyan": "^1.0.0" + }, + "dependencies": { + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" + } + } + }, + "hexo-pagination": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/hexo-pagination/-/hexo-pagination-0.0.2.tgz", + "integrity": "sha1-jPRwx9sN5bGKOSanbesZQBXffys=", + "requires": { + "utils-merge": "^1.0.0" + } + }, + "hexo-renderer-ejs": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/hexo-renderer-ejs/-/hexo-renderer-ejs-0.3.1.tgz", + "integrity": "sha512-XN8pYJU+Wr3dT8ipqEPRlOBySJpd1C5NUBBzgZpVSVBC/6L36O0YZI/Qd5NxQqwfGfSuKQ8N5iMyjmRXSR1MdA==", + "requires": { + "ejs": "^2.3.4", + "object-assign": "^4.0.1" + } + }, + "hexo-renderer-marked": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/hexo-renderer-marked/-/hexo-renderer-marked-0.3.2.tgz", + "integrity": "sha512-joSLeHB0YRkuViIPQlRz4A+zfJKPNHT+rABFgPHiT1zL9eeTUPxoLL4h7kcgOwRLAontVScaxP2Sie15mNitFg==", + "requires": { + "hexo-util": "^0.6.2", + "marked": "^0.3.9", + "object-assign": "^4.1.1", + "strip-indent": "^2.0.0" + } + }, + "hexo-renderer-stylus": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/hexo-renderer-stylus/-/hexo-renderer-stylus-0.3.3.tgz", + "integrity": "sha1-xU6ifh/Y48ipp6hM+6itNUEiyn8=", + "requires": { + "nib": "^1.1.2", + "stylus": "^0.54.5" + } + }, + "hexo-server": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/hexo-server/-/hexo-server-0.3.3.tgz", + "integrity": "sha512-70zQaf4Z+bj37Kvq7tEyn9WHH+Xj7uqbvOlGp8pHaOzWLp/riX3rMq3nnQKA2P8dKkBaM0/72IqjJPWu2Zt2WA==", + "requires": { + "bluebird": "^3.5.1", + "chalk": "^1.1.3", + "compression": "^1.7.3", + "connect": "^3.6.6", + "mime": "^1.6.0", + "morgan": "^1.9.0", + "object-assign": "^4.1.1", + "opn": "^5.3.0", + "serve-static": "^1.13.2" + }, + "dependencies": { + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" + } + } + }, + "hexo-util": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/hexo-util/-/hexo-util-0.6.3.tgz", + "integrity": "sha512-zPxaqCWZz3/25SAB4FlrRtWktJ+Pr+vBiv/nyHpXKgXPt1m70liViKlRwWLqDmRjJ72x6/k4qCEeXHajvcGHUw==", + "requires": { + "bluebird": "^3.4.0", + "camel-case": "^3.0.0", + "cross-spawn": "^4.0.0", + "highlight.js": "^9.4.0", + "html-entities": "^1.2.0", + "striptags": "^2.1.1" + } + }, + "highlight.js": { + "version": "9.14.2", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.14.2.tgz", + "integrity": "sha512-Nc6YNECYpxyJABGYJAyw7dBAYbXEuIzwzkqoJnwbc1nIpCiN+3ioYf0XrBnLiyyG0JLuJhpPtt2iTSbXiKLoyA==" + }, + "html-entities": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-1.2.1.tgz", + "integrity": "sha1-DfKTUfByEWNRXfueVUPl9u7VFi8=" + }, + "htmlparser2": { + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", + "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", + "requires": { + "domelementtype": "^1.3.1", + "domhandler": "^2.3.0", + "domutils": "^1.5.1", + "entities": "^1.1.1", + "inherits": "^2.0.1", + "readable-stream": "^3.1.1" + } + }, + "http-errors": { + "version": "1.6.3", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz", + "integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=", + "requires": { + "depd": "~1.1.2", + "inherits": "2.0.3", + "setprototypeof": "1.1.0", + "statuses": ">= 1.4.0 < 2" + }, + "dependencies": { + "statuses": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", + "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" + } + } + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + }, + "invert-kv": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-1.0.0.tgz", + "integrity": "sha1-EEqOSqym09jNFXqO+L+rLXo//bY=" + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "^3.0.2" + } + }, + "is-binary-path": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-1.0.1.tgz", + "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", + "requires": { + "binary-extensions": "^1.0.0" + } + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "^3.0.2" + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "^0.1.6", + "is-data-descriptor": "^0.1.4", + "kind-of": "^5.0.0" + }, + "dependencies": { + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "is-dotfile": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-dotfile/-/is-dotfile-1.0.3.tgz", + "integrity": "sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE=" + }, + "is-equal-shallow": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/is-equal-shallow/-/is-equal-shallow-0.1.3.tgz", + "integrity": "sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ=", + "requires": { + "is-primitive": "^2.0.0" + } + }, + "is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=" + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "requires": { + "number-is-nan": "^1.0.0" + } + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "^1.0.0" + } + }, + "is-number": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-2.1.0.tgz", + "integrity": "sha1-Afy7s5NGOlSPL0ZszhbezknbkI8=", + "requires": { + "kind-of": "^3.0.2" + } + }, + "is-plain-object": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", + "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "requires": { + "isobject": "^3.0.1" + }, + "dependencies": { + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "is-posix-bracket": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz", + "integrity": "sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q=" + }, + "is-primitive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-primitive/-/is-primitive-2.0.0.tgz", + "integrity": "sha1-IHurkWOEmcB7Kt8kCkGochADRXU=" + }, + "is-windows": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", + "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==" + }, + "is-wsl": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-1.1.0.tgz", + "integrity": "sha1-HxbkqiKwTRM2tmGIpmrzxgDDpm0=" + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" + }, + "isobject": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "requires": { + "isarray": "1.0.0" + } + }, + "js-yaml": { + "version": "3.12.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.12.1.tgz", + "integrity": "sha512-um46hB9wNOKlwkHgiuyEVAybXBjwFUV0Z/RaHJblRd9DXltue9FTYvzCr9ErQrK9Adz5MU4gHWVaNUfdmrC8qA==", + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "jsonparse": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", + "integrity": "sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA=" + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + }, + "lazy-cache": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/lazy-cache/-/lazy-cache-1.0.4.tgz", + "integrity": "sha1-odePw6UEdMuAhF07O24dpJpEbo4=" + }, + "lcid": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/lcid/-/lcid-1.0.0.tgz", + "integrity": "sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU=", + "requires": { + "invert-kv": "^1.0.0" + } + }, + "lodash": { + "version": "4.17.11", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", + "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + }, + "lodash.assignin": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/lodash.assignin/-/lodash.assignin-4.2.0.tgz", + "integrity": "sha1-uo31+4QesKPoBEIysOJjqNxqKKI=" + }, + "lodash.bind": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/lodash.bind/-/lodash.bind-4.2.1.tgz", + "integrity": "sha1-euMBfpOWIqwxt9fX3LGzTbFpDTU=" + }, + "lodash.defaults": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/lodash.defaults/-/lodash.defaults-4.2.0.tgz", + "integrity": "sha1-0JF4cW/+pN3p5ft7N/bwgCJ0WAw=" + }, + "lodash.filter": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.filter/-/lodash.filter-4.6.0.tgz", + "integrity": "sha1-ZosdSYFgOuHMWm+nYBQ+SAtMSs4=" + }, + "lodash.flatten": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/lodash.flatten/-/lodash.flatten-4.4.0.tgz", + "integrity": "sha1-8xwiIlqWMtK7+OSt2+8kCqdlph8=" + }, + "lodash.foreach": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.foreach/-/lodash.foreach-4.5.0.tgz", + "integrity": "sha1-Gmo16s5AEoDH8G3d7DUWWrJ+PlM=" + }, + "lodash.map": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.map/-/lodash.map-4.6.0.tgz", + "integrity": "sha1-dx7Hg540c9nEzeKLGTlMNWL09tM=" + }, + "lodash.merge": { + "version": "4.6.1", + "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.1.tgz", + "integrity": "sha512-AOYza4+Hf5z1/0Hztxpm2/xiPZgi/cjMqdnKTUWTBSKchJlxXXuUSxCCl8rJlf4g6yww/j6mA8nC8Hw/EZWxKQ==" + }, + "lodash.pick": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/lodash.pick/-/lodash.pick-4.4.0.tgz", + "integrity": "sha1-UvBWEP/53tQiYRRB7R/BI6AwAbM=" + }, + "lodash.reduce": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.reduce/-/lodash.reduce-4.6.0.tgz", + "integrity": "sha1-8atrg5KZrUj3hKu/R2WW8DuRTTs=" + }, + "lodash.reject": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.reject/-/lodash.reject-4.6.0.tgz", + "integrity": "sha1-gNZJLcFHCGS79YNTO2UfQqn1JBU=" + }, + "lodash.some": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.some/-/lodash.some-4.6.0.tgz", + "integrity": "sha1-G7nzFO9ri63tE7VJFpsqlF62jk0=" + }, + "longest": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/longest/-/longest-1.0.1.tgz", + "integrity": "sha1-MKCy2jj3N3DoKUoNIuZiXtd9AJc=" + }, + "lower-case": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/lower-case/-/lower-case-1.1.4.tgz", + "integrity": "sha1-miyr0bno4K6ZOkv31YdcOcQujqw=" + }, + "lru-cache": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", + "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", + "requires": { + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" + } + }, + "map-cache": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/map-cache/-/map-cache-0.2.2.tgz", + "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=" + }, + "map-visit": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", + "integrity": "sha1-7Nyo8TFE5mDxtb1B8S80edmN+48=", + "requires": { + "object-visit": "^1.0.0" + } + }, + "markdown": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/markdown/-/markdown-0.5.0.tgz", + "integrity": "sha1-KCBbVlqK51kt4gdGPWY33BgnIrI=", + "requires": { + "nopt": "~2.1.1" + } + }, + "marked": { + "version": "0.3.19", + "resolved": "https://registry.npmjs.org/marked/-/marked-0.3.19.tgz", + "integrity": "sha512-ea2eGWOqNxPcXv8dyERdSr/6FmzvWwzjMxpfGB/sbMccXoct+xY+YukPD+QTUZwyvK7BZwcr4m21WBOW41pAkg==" + }, + "math-random": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/math-random/-/math-random-1.0.4.tgz", + "integrity": "sha512-rUxjysqif/BZQH2yhd5Aaq7vXMSx9NdEsQcyA07uEzIvxgI7zIr33gGsh+RU0/XjmQpCW7RsVof1vlkvQVCK5A==" + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "^2.0.0", + "array-unique": "^0.2.1", + "braces": "^1.8.2", + "expand-brackets": "^0.1.4", + "extglob": "^0.3.1", + "filename-regex": "^2.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.1", + "kind-of": "^3.0.2", + "normalize-path": "^2.0.1", + "object.omit": "^2.0.0", + "parse-glob": "^3.0.4", + "regex-cache": "^0.4.2" + } + }, + "mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" + }, + "mime-db": { + "version": "1.38.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.38.0.tgz", + "integrity": "sha512-bqVioMFFzc2awcdJZIzR3HjZFX20QhilVS7hytkKrv7xFAn8bM1gzc/FOX2awLISvWe0PV8ptFKcon+wZ5qYkg==" + }, + "mime-types": { + "version": "2.1.22", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.22.tgz", + "integrity": "sha512-aGl6TZGnhm/li6F7yx82bJiBZwgiEa4Hf6CNr8YO+r5UHr53tSTYZb102zyU50DOWWKeOv0uQLRL0/9EiKWCog==", + "requires": { + "mime-db": "~1.38.0" + } + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + }, + "mixin-deep": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.1.tgz", + "integrity": "sha512-8ZItLHeEgaqEvd5lYBXfm4EZSFCX29Jb9K+lAHhDKzReKBQKj3R+7NOF6tjqYi9t4oI8VUfaWITJQm86wnXGNQ==", + "requires": { + "for-in": "^1.0.2", + "is-extendable": "^1.0.1" + }, + "dependencies": { + "is-extendable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", + "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "requires": { + "is-plain-object": "^2.0.4" + } + } + } + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "requires": { + "minimist": "0.0.8" + }, + "dependencies": { + "minimist": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" + } + } + }, + "moment": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.24.0.tgz", + "integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg==" + }, + "moment-timezone": { + "version": "0.5.23", + "resolved": "https://registry.npmjs.org/moment-timezone/-/moment-timezone-0.5.23.tgz", + "integrity": "sha512-WHFH85DkCfiNMDX5D3X7hpNH3/PUhjTGcD0U1SgfBGZxJ3qUmJh5FdvaFjcClxOvB3rzdfj4oRffbI38jEnC1w==", + "requires": { + "moment": ">= 2.9.0" + } + }, + "morgan": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/morgan/-/morgan-1.9.1.tgz", + "integrity": "sha512-HQStPIV4y3afTiCYVxirakhlCfGkI161c76kKFca7Fk1JusM//Qeo1ej2XaMniiNeaZklMVrh3vTtIzpzwbpmA==", + "requires": { + "basic-auth": "~2.0.0", + "debug": "2.6.9", + "depd": "~1.1.2", + "on-finished": "~2.3.0", + "on-headers": "~1.0.1" + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "mv": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/mv/-/mv-2.1.1.tgz", + "integrity": "sha1-rmzg1vbV4KT32JN5jQPB6pVZtqI=", + "optional": true, + "requires": { + "mkdirp": "~0.5.1", + "ncp": "~2.0.0", + "rimraf": "~2.4.0" + } + }, + "nan": { + "version": "2.12.1", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.12.1.tgz", + "integrity": "sha512-JY7V6lRkStKcKTvHO5NVSQRv+RV+FIL5pvDoLiAtSL9pKlC5x9PKQcZDsq7m4FO4d57mkhC6Z+QhAh3Jdk5JFw==", + "optional": true + }, + "nanomatch": { + "version": "1.2.13", + "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.13.tgz", + "integrity": "sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==", + "requires": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "fragment-cache": "^0.2.1", + "is-windows": "^1.0.2", + "kind-of": "^6.0.2", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "dependencies": { + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=" + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + } + } + }, + "ncp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ncp/-/ncp-2.0.0.tgz", + "integrity": "sha1-GVoh1sRuNh0vsSgbo4uR6d9727M=", + "optional": true + }, + "negotiator": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.1.tgz", + "integrity": "sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk=" + }, + "nib": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/nib/-/nib-1.1.2.tgz", + "integrity": "sha1-amnt5AgblcDe+L4CSkyK4MLLtsc=", + "requires": { + "stylus": "0.54.5" + } + }, + "no-case": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/no-case/-/no-case-2.3.2.tgz", + "integrity": "sha512-rmTZ9kz+f3rCvK2TD1Ue/oZlns7OGoIWP4fc3llxxRXlOkHKoWPPWJOfFYpITabSow43QJbRIoHQXtt10VldyQ==", + "requires": { + "lower-case": "^1.1.1" + } + }, + "node-fingerprint": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/node-fingerprint/-/node-fingerprint-0.0.2.tgz", + "integrity": "sha1-Mcur63GmeufdWn3AQuUcPHWGhQE=" + }, + "nopt": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-2.1.2.tgz", + "integrity": "sha1-bMzZd7gBMqB3MdbozljCyDA8+a8=", + "requires": { + "abbrev": "1" + } + }, + "normalize-path": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", + "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", + "requires": { + "remove-trailing-separator": "^1.0.1" + } + }, + "nth-check": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", + "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", + "requires": { + "boolbase": "~1.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" + }, + "nunjucks": { + "version": "3.1.7", + "resolved": "https://registry.npmjs.org/nunjucks/-/nunjucks-3.1.7.tgz", + "integrity": "sha512-MrjI68cobXQnyMK/LeY7BgYZ+7o4xn1UNGOe1y8ACVo4cn/1FXc1S4ySqHbmzFqxq/qtMWrehysTuXdbTvf7JA==", + "requires": { + "a-sync-waterfall": "^1.0.0", + "asap": "^2.0.3", + "chokidar": "^2.0.0", + "yargs": "^3.32.0" + }, + "dependencies": { + "anymatch": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", + "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", + "optional": true, + "requires": { + "micromatch": "^3.1.4", + "normalize-path": "^2.1.1" + }, + "dependencies": { + "normalize-path": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", + "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", + "optional": true, + "requires": { + "remove-trailing-separator": "^1.0.1" + } + } + } + }, + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "optional": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=" + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "requires": { + "arr-flatten": "^1.1.0", + "array-unique": "^0.3.2", + "extend-shallow": "^2.0.1", + "fill-range": "^4.0.0", + "isobject": "^3.0.1", + "repeat-element": "^1.1.2", + "snapdragon": "^0.8.1", + "snapdragon-node": "^2.0.1", + "split-string": "^3.0.2", + "to-regex": "^3.0.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "chokidar": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-2.1.2.tgz", + "integrity": "sha512-IwXUx0FXc5ibYmPC2XeEj5mpXoV66sR+t3jqu2NS2GYwCktt3KF1/Qqjws/NkegajBA4RbZ5+DDwlOiJsxDHEg==", + "optional": true, + "requires": { + "anymatch": "^2.0.0", + "async-each": "^1.0.1", + "braces": "^2.3.2", + "fsevents": "^1.2.7", + "glob-parent": "^3.1.0", + "inherits": "^2.0.3", + "is-binary-path": "^1.0.0", + "is-glob": "^4.0.0", + "normalize-path": "^3.0.0", + "path-is-absolute": "^1.0.0", + "readdirp": "^2.2.1", + "upath": "^1.1.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "optional": true, + "requires": { + "debug": "^2.3.3", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "posix-character-classes": "^0.1.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "optional": true, + "requires": { + "is-descriptor": "^0.1.0" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "optional": true, + "requires": { + "is-extendable": "^0.1.0" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "optional": true, + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "optional": true, + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "optional": true, + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "optional": true, + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "optional": true, + "requires": { + "is-accessor-descriptor": "^0.1.6", + "is-data-descriptor": "^0.1.4", + "kind-of": "^5.0.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "optional": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "optional": true, + "requires": { + "array-unique": "^0.3.2", + "define-property": "^1.0.0", + "expand-brackets": "^2.1.4", + "extend-shallow": "^2.0.1", + "fragment-cache": "^0.2.1", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "optional": true, + "requires": { + "is-descriptor": "^1.0.0" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "optional": true, + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "requires": { + "extend-shallow": "^2.0.1", + "is-number": "^3.0.0", + "repeat-string": "^1.6.1", + "to-regex-range": "^2.1.0" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "glob-parent": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz", + "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", + "optional": true, + "requires": { + "is-glob": "^3.1.0", + "path-dirname": "^1.0.0" + }, + "dependencies": { + "is-glob": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", + "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", + "optional": true, + "requires": { + "is-extglob": "^2.1.0" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "optional": true, + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "optional": true, + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "optional": true, + "requires": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + } + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-glob": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.0.tgz", + "integrity": "sha1-lSHHaEXMJhCoUgPd8ICpWML/q8A=", + "optional": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "optional": true, + "requires": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "braces": "^2.3.1", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "extglob": "^2.0.4", + "fragment-cache": "^0.2.1", + "kind-of": "^6.0.2", + "nanomatch": "^1.2.9", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.2" + } + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "optional": true + } + } + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" + }, + "object-copy": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/object-copy/-/object-copy-0.1.0.tgz", + "integrity": "sha1-fn2Fi3gb18mRpBupde04EnVOmYw=", + "requires": { + "copy-descriptor": "^0.1.0", + "define-property": "^0.2.5", + "kind-of": "^3.0.3" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "^0.1.0" + } + } + } + }, + "object-visit": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/object-visit/-/object-visit-1.0.1.tgz", + "integrity": "sha1-95xEk68MU3e1n+OdOV5BBC3QRbs=", + "requires": { + "isobject": "^3.0.0" + }, + "dependencies": { + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "object.omit": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/object.omit/-/object.omit-2.0.1.tgz", + "integrity": "sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo=", + "requires": { + "for-own": "^0.1.4", + "is-extendable": "^0.1.1" + } + }, + "object.pick": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/object.pick/-/object.pick-1.3.0.tgz", + "integrity": "sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c=", + "requires": { + "isobject": "^3.0.1" + }, + "dependencies": { + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "on-finished": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", + "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", + "requires": { + "ee-first": "1.1.1" + } + }, + "on-headers": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.1.tgz", + "integrity": "sha1-ko9dD0cNSTQmUepnlLCFfBAGk/c=" + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "requires": { + "wrappy": "1" + } + }, + "opn": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/opn/-/opn-5.4.0.tgz", + "integrity": "sha512-YF9MNdVy/0qvJvDtunAOzFw9iasOQHpVthTCvGzxt61Il64AYSGdK+rYwld7NAfk9qJ7dt+hymBNSc9LNYS+Sw==", + "requires": { + "is-wsl": "^1.1.0" + } + }, + "optimist": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", + "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", + "requires": { + "minimist": "~0.0.1", + "wordwrap": "~0.0.2" + }, + "dependencies": { + "minimist": { + "version": "0.0.10", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", + "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=" + } + } + }, + "os-homedir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=" + }, + "os-locale": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-1.4.0.tgz", + "integrity": "sha1-IPnxeuKe00XoveWDsT0gCYA8FNk=", + "requires": { + "lcid": "^1.0.0" + } + }, + "parse-glob": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/parse-glob/-/parse-glob-3.0.4.tgz", + "integrity": "sha1-ssN2z7EfNVE7rdFz7wu246OIORw=", + "requires": { + "glob-base": "^0.3.0", + "is-dotfile": "^1.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.0" + } + }, + "parseurl": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.2.tgz", + "integrity": "sha1-/CidTtiZMRlGDBViUyYs3I3mW/M=" + }, + "pascalcase": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/pascalcase/-/pascalcase-0.1.1.tgz", + "integrity": "sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ=" + }, + "path-dirname": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/path-dirname/-/path-dirname-1.0.2.tgz", + "integrity": "sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA=", + "optional": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" + }, + "path-parse": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", + "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" + }, + "posix-character-classes": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", + "integrity": "sha1-AerA/jta9xoqbAL+q7jB/vfgDqs=" + }, + "preserve": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/preserve/-/preserve-0.2.0.tgz", + "integrity": "sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks=" + }, + "pretty-hrtime": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz", + "integrity": "sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=" + }, + "process-nextick-args": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", + "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==" + }, + "pseudomap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", + "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=" + }, + "randomatic": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/randomatic/-/randomatic-3.1.1.tgz", + "integrity": "sha512-TuDE5KxZ0J461RVjrJZCJc+J+zCkTb1MbH9AQUq68sMhOMcy9jLcb3BrZKgp9q9Ncltdg4QVqWrH02W2EFFVYw==", + "requires": { + "is-number": "^4.0.0", + "kind-of": "^6.0.0", + "math-random": "^1.0.1" + }, + "dependencies": { + "is-number": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-4.0.0.tgz", + "integrity": "sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ==" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + } + } + }, + "range-parser": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.0.tgz", + "integrity": "sha1-9JvmtIeJTdxA3MlKMi9hEJLgDV4=" + }, + "readable-stream": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.1.1.tgz", + "integrity": "sha512-DkN66hPyqDhnIQ6Jcsvx9bFjhw214O4poMBcIMgPVpQvNy9a0e0Uhg5SqySyDKAmUlwt8LonTBz1ezOnM8pUdA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "readdirp": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz", + "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==", + "requires": { + "graceful-fs": "^4.1.11", + "micromatch": "^3.1.10", + "readable-stream": "^2.0.2" + }, + "dependencies": { + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=" + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=" + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "requires": { + "arr-flatten": "^1.1.0", + "array-unique": "^0.3.2", + "extend-shallow": "^2.0.1", + "fill-range": "^4.0.0", + "isobject": "^3.0.1", + "repeat-element": "^1.1.2", + "snapdragon": "^0.8.1", + "snapdragon-node": "^2.0.1", + "split-string": "^3.0.2", + "to-regex": "^3.0.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "requires": { + "debug": "^2.3.3", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "posix-character-classes": "^0.1.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "^0.1.0" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "^0.1.6", + "is-data-descriptor": "^0.1.4", + "kind-of": "^5.0.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "requires": { + "array-unique": "^0.3.2", + "define-property": "^1.0.0", + "expand-brackets": "^2.1.4", + "extend-shallow": "^2.0.1", + "fragment-cache": "^0.2.1", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "requires": { + "is-descriptor": "^1.0.0" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "requires": { + "extend-shallow": "^2.0.1", + "is-number": "^3.0.0", + "repeat-string": "^1.6.1", + "to-regex-range": "^2.1.0" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "requires": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "requires": { + "kind-of": "^3.0.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "requires": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "braces": "^2.3.1", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "extglob": "^2.0.4", + "fragment-cache": "^0.2.1", + "kind-of": "^6.0.2", + "nanomatch": "^1.2.9", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.2" + } + }, + "readable-stream": { + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "regex-cache": { + "version": "0.4.4", + "resolved": "https://registry.npmjs.org/regex-cache/-/regex-cache-0.4.4.tgz", + "integrity": "sha512-nVIZwtCjkC9YgvWkpM55B5rBhBYRZhAaJbgcFYXXsHnbZ9UZI9nnVWYZpBlCqv9ho2eZryPnWrZGsOdPwVWXWQ==", + "requires": { + "is-equal-shallow": "^0.1.3" + } + }, + "regex-not": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/regex-not/-/regex-not-1.0.2.tgz", + "integrity": "sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==", + "requires": { + "extend-shallow": "^3.0.2", + "safe-regex": "^1.1.0" + } + }, + "remove-trailing-separator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", + "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=" + }, + "repeat-element": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.3.tgz", + "integrity": "sha512-ahGq0ZnV5m5XtZLMb+vP76kcAM5nkLqk0lpqAuojSKGgQtn4eRi4ZZGm2olo2zKFH+sMsWaqOCW1dqAnOru72g==" + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=" + }, + "resolve": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.10.0.tgz", + "integrity": "sha512-3sUr9aq5OfSg2S9pNtPA9hL1FVEAjvfOC4leW0SNf/mpnaakz2a9femSd6LqAww2RaFctwyf1lCqnTHuF1rxDg==", + "requires": { + "path-parse": "^1.0.6" + } + }, + "resolve-url": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", + "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=" + }, + "ret": { + "version": "0.1.15", + "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", + "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==" + }, + "right-align": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/right-align/-/right-align-0.1.3.tgz", + "integrity": "sha1-YTObci/mo1FWiSENJOFMlhSGE+8=", + "requires": { + "align-text": "^0.1.1" + } + }, + "rimraf": { + "version": "2.4.5", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.4.5.tgz", + "integrity": "sha1-7nEM5dk6j9uFb7Xqj/Di11k0sto=", + "optional": true, + "requires": { + "glob": "^6.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "safe-json-stringify": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/safe-json-stringify/-/safe-json-stringify-1.2.0.tgz", + "integrity": "sha512-gH8eh2nZudPQO6TytOvbxnuhYBOvDBBLW52tz5q6X58lJcd/tkmqFR+5Z9adS8aJtURSXWThWy/xJtJwixErvg==", + "optional": true + }, + "safe-regex": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", + "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", + "requires": { + "ret": "~0.1.10" + } + }, + "sax": { + "version": "0.5.8", + "resolved": "https://registry.npmjs.org/sax/-/sax-0.5.8.tgz", + "integrity": "sha1-1HLbIo6zMcJQaw6MFVJK25OdEsE=" + }, + "send": { + "version": "0.16.2", + "resolved": "https://registry.npmjs.org/send/-/send-0.16.2.tgz", + "integrity": "sha512-E64YFPUssFHEFBvpbbjr44NCLtI1AohxQ8ZSiJjQLskAdKuriYEP6VyGEsRDH8ScozGpkaX1BGvhanqCwkcEZw==", + "requires": { + "debug": "2.6.9", + "depd": "~1.1.2", + "destroy": "~1.0.4", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "~1.6.2", + "mime": "1.4.1", + "ms": "2.0.0", + "on-finished": "~2.3.0", + "range-parser": "~1.2.0", + "statuses": "~1.4.0" + }, + "dependencies": { + "mime": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.4.1.tgz", + "integrity": "sha512-KI1+qOZu5DcW6wayYHSzR/tXKCDC5Om4s1z2QJjDULzLcmf3DvzS7oluY4HCTrc+9FiKmWUgeNLg7W3uIQvxtQ==" + }, + "statuses": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.4.0.tgz", + "integrity": "sha512-zhSCtt8v2NDrRlPQpCNtw/heZLtfUDqxBM1udqikb/Hbk52LK4nQSwr10u77iopCW5LsyHpuXS0GnEc48mLeew==" + } + } + }, + "serve-static": { + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.13.2.tgz", + "integrity": "sha512-p/tdJrO4U387R9oMjb1oj7qSMaMfmOyd4j9hOFoxZe2baQszgHcSWjuya/CiT5kgZZKRudHNOA0pYXOl8rQ5nw==", + "requires": { + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "parseurl": "~1.3.2", + "send": "0.16.2" + } + }, + "set-value": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.0.tgz", + "integrity": "sha512-hw0yxk9GT/Hr5yJEYnHNKYXkIA8mVJgd9ditYZCe16ZczcaELYYcfvaXesNACk2O8O0nTiPQcQhGUQj8JLzeeg==", + "requires": { + "extend-shallow": "^2.0.1", + "is-extendable": "^0.1.1", + "is-plain-object": "^2.0.3", + "split-string": "^3.0.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "setprototypeof": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.0.tgz", + "integrity": "sha512-BvE/TwpZX4FXExxOxZyRGQQv651MSwmWKZGqvmPcRIjDqWub67kTKuIMx43cZZrS/cBBzwBcNDWoFxt2XEFIpQ==" + }, + "snapdragon": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", + "integrity": "sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==", + "requires": { + "base": "^0.11.1", + "debug": "^2.2.0", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "map-cache": "^0.2.2", + "source-map": "^0.5.6", + "source-map-resolve": "^0.5.0", + "use": "^3.1.0" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "^0.1.0" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + } + } + }, + "snapdragon-node": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/snapdragon-node/-/snapdragon-node-2.1.1.tgz", + "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", + "requires": { + "define-property": "^1.0.0", + "isobject": "^3.0.0", + "snapdragon-util": "^3.0.1" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "requires": { + "is-descriptor": "^1.0.0" + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "requires": { + "kind-of": "^6.0.0" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "requires": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + } + } + }, + "snapdragon-util": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/snapdragon-util/-/snapdragon-util-3.0.1.tgz", + "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", + "requires": { + "kind-of": "^3.2.0" + } + }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" + }, + "source-map-resolve": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.2.tgz", + "integrity": "sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA==", + "requires": { + "atob": "^2.1.1", + "decode-uri-component": "^0.2.0", + "resolve-url": "^0.2.1", + "source-map-url": "^0.4.0", + "urix": "^0.1.0" + } + }, + "source-map-url": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.0.tgz", + "integrity": "sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=" + }, + "split-string": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", + "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", + "requires": { + "extend-shallow": "^3.0.0" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" + }, + "static-extend": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", + "integrity": "sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY=", + "requires": { + "define-property": "^0.2.5", + "object-copy": "^0.1.0" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "^0.1.0" + } + } + } + }, + "statuses": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.3.1.tgz", + "integrity": "sha1-+vUbnrdKrvOzrPStX2Gr8ky3uT4=" + }, + "string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "requires": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "dependencies": { + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + } + } + }, + "string_decoder": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.2.0.tgz", + "integrity": "sha512-6YqyX6ZWEYguAxgZzHGL7SsCeGx3V2TtOTqZz1xSTSWnqsbWwbptafNyvf/ACquZUXV3DANr5BDIwNYe1mN42w==", + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "^3.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + } + } + }, + "strip-indent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-2.0.0.tgz", + "integrity": "sha1-XvjbKV0B5u1sv3qrlpmNeCJSe2g=" + }, + "striptags": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/striptags/-/striptags-2.2.1.tgz", + "integrity": "sha1-TEULcI1BuL85zyTEn/I0/Gqr/TI=" + }, + "stylus": { + "version": "0.54.5", + "resolved": "https://registry.npmjs.org/stylus/-/stylus-0.54.5.tgz", + "integrity": "sha1-QrlWCTHKcJDOhRWnmLqeaqPW3Hk=", + "requires": { + "css-parse": "1.7.x", + "debug": "*", + "glob": "7.0.x", + "mkdirp": "0.5.x", + "sax": "0.5.x", + "source-map": "0.1.x" + }, + "dependencies": { + "glob": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.0.6.tgz", + "integrity": "sha1-IRuvr0nlJbjNkyYNFKsTYVKz9Xo=", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.2", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "source-map": { + "version": "0.1.43", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.1.43.tgz", + "integrity": "sha1-wkvBRspRfBRx9drL4lcbK3+eM0Y=", + "requires": { + "amdefine": ">=0.0.4" + } + } + } + }, + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "requires": { + "has-flag": "^3.0.0" + } + }, + "swig-extras": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/swig-extras/-/swig-extras-0.0.1.tgz", + "integrity": "sha1-tQP+3jcqucJMasaMr2VrzvGHIyg=", + "requires": { + "markdown": "~0.5.0" + } + }, + "swig-templates": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/swig-templates/-/swig-templates-2.0.3.tgz", + "integrity": "sha512-QojPTuZWdpznSZWZDB63/grsZuDwT/7geMeGlftbJXDoYBIZEnTcKvz4iwYDv3SwfPX9/B4RtGRSXNnm3S2wwg==", + "requires": { + "optimist": "~0.6", + "uglify-js": "2.6.0" + } + }, + "text-table": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", + "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=" + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" + }, + "tildify": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/tildify/-/tildify-1.2.0.tgz", + "integrity": "sha1-3OwD9V3Km3qj5bBPIYF+tW5jWIo=", + "requires": { + "os-homedir": "^1.0.0" + } + }, + "titlecase": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/titlecase/-/titlecase-1.1.2.tgz", + "integrity": "sha1-eBE9EQgIa4MmMxoyR96o9aSeqFM=" + }, + "to-object-path": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/to-object-path/-/to-object-path-0.3.0.tgz", + "integrity": "sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68=", + "requires": { + "kind-of": "^3.0.2" + } + }, + "to-regex": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/to-regex/-/to-regex-3.0.2.tgz", + "integrity": "sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==", + "requires": { + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "regex-not": "^1.0.2", + "safe-regex": "^1.1.0" + } + }, + "to-regex-range": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-2.1.1.tgz", + "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", + "requires": { + "is-number": "^3.0.0", + "repeat-string": "^1.6.1" + }, + "dependencies": { + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "requires": { + "kind-of": "^3.0.2" + } + } + } + }, + "uglify-js": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-2.6.0.tgz", + "integrity": "sha1-JeqhzDVQ45QQzu+v0c+7a20V8AE=", + "requires": { + "async": "~0.2.6", + "source-map": "~0.5.1", + "uglify-to-browserify": "~1.0.0", + "yargs": "~3.10.0" + }, + "dependencies": { + "camelcase": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-1.2.1.tgz", + "integrity": "sha1-m7UwTS4LVmmLLHWLCKPqqdqlijk=" + }, + "cliui": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-2.1.0.tgz", + "integrity": "sha1-S0dXYP+AJkx2LDoXGQMukcf+oNE=", + "requires": { + "center-align": "^0.1.1", + "right-align": "^0.1.1", + "wordwrap": "0.0.2" + } + }, + "window-size": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/window-size/-/window-size-0.1.0.tgz", + "integrity": "sha1-VDjNLqk7IC76Ohn+iIeu58lPnJ0=" + }, + "wordwrap": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.2.tgz", + "integrity": "sha1-t5Zpu0LstAn4PVg8rVLKF+qhZD8=" + }, + "yargs": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-3.10.0.tgz", + "integrity": "sha1-9+572FfdfB0tOMDnTvvWgdFDH9E=", + "requires": { + "camelcase": "^1.0.2", + "cliui": "^2.1.0", + "decamelize": "^1.0.0", + "window-size": "0.1.0" + } + } + } + }, + "uglify-to-browserify": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz", + "integrity": "sha1-bgkk1r2mta/jSeOabWMoUKD4grc=" + }, + "union-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.0.tgz", + "integrity": "sha1-XHHDTLW61dzr4+oM0IIHulqhrqQ=", + "requires": { + "arr-union": "^3.1.0", + "get-value": "^2.0.6", + "is-extendable": "^0.1.1", + "set-value": "^0.4.3" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + }, + "set-value": { + "version": "0.4.3", + "resolved": "https://registry.npmjs.org/set-value/-/set-value-0.4.3.tgz", + "integrity": "sha1-fbCPnT0i3H945Trzw79GZuzfzPE=", + "requires": { + "extend-shallow": "^2.0.1", + "is-extendable": "^0.1.1", + "is-plain-object": "^2.0.1", + "to-object-path": "^0.3.0" + } + } + } + }, + "unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" + }, + "unset-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", + "integrity": "sha1-g3aHP30jNRef+x5vw6jtDfyKtVk=", + "requires": { + "has-value": "^0.3.1", + "isobject": "^3.0.0" + }, + "dependencies": { + "has-value": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/has-value/-/has-value-0.3.1.tgz", + "integrity": "sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8=", + "requires": { + "get-value": "^2.0.3", + "has-values": "^0.1.4", + "isobject": "^2.0.0" + }, + "dependencies": { + "isobject": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "requires": { + "isarray": "1.0.0" + } + } + } + }, + "has-values": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/has-values/-/has-values-0.1.4.tgz", + "integrity": "sha1-bWHeldkd/Km5oCCJrThL/49it3E=" + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + } + } + }, + "upath": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/upath/-/upath-1.1.0.tgz", + "integrity": "sha512-bzpH/oBhoS/QI/YtbkqCg6VEiPYjSZtrHQM6/QnJS6OL9pKUFLqb3aFh4Scvwm45+7iAgiMkLhSbaZxUqmrprw==", + "optional": true + }, + "upper-case": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/upper-case/-/upper-case-1.1.3.tgz", + "integrity": "sha1-9rRQHC7EzdJrp4vnIilh3ndiFZg=" + }, + "urix": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", + "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=" + }, + "use": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz", + "integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==" + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + }, + "utils-merge": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", + "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" + }, + "vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" + }, + "warehouse": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/warehouse/-/warehouse-2.2.0.tgz", + "integrity": "sha1-XQnWSUKZK+Zn2PfIagnCuK6gQGI=", + "requires": { + "JSONStream": "^1.0.7", + "bluebird": "^3.2.2", + "cuid": "~1.3.8", + "graceful-fs": "^4.1.3", + "is-plain-object": "^2.0.1", + "lodash": "^4.2.1" + } + }, + "which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "requires": { + "isexe": "^2.0.0" + } + }, + "window-size": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/window-size/-/window-size-0.1.4.tgz", + "integrity": "sha1-+OGqHuWlPsW/FR/6CXQqatdpeHY=" + }, + "wordwrap": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", + "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=" + }, + "wrap-ansi": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", + "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", + "requires": { + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1" + }, + "dependencies": { + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "^2.0.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" + }, + "y18n": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.1.tgz", + "integrity": "sha1-bRX7qITAhnnA136I53WegR4H+kE=" + }, + "yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" + }, + "yargs": { + "version": "3.32.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-3.32.0.tgz", + "integrity": "sha1-AwiOnr+edWtpdRYR0qXvWRSCyZU=", + "requires": { + "camelcase": "^2.0.1", + "cliui": "^3.0.3", + "decamelize": "^1.1.1", + "os-locale": "^1.4.0", + "string-width": "^1.0.1", + "window-size": "^0.1.4", + "y18n": "^3.2.0" + } + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..d75b1e5 --- /dev/null +++ b/package.json @@ -0,0 +1,19 @@ +{ + "name": "hexo-site", + "version": "0.0.0", + "private": true, + "hexo": { + "version": "3.8.0" + }, + "dependencies": { + "hexo": "^3.8.0", + "hexo-generator-archive": "^0.1.5", + "hexo-generator-category": "^0.1.3", + "hexo-generator-index": "^0.2.1", + "hexo-generator-tag": "^0.2.0", + "hexo-renderer-ejs": "^0.3.1", + "hexo-renderer-stylus": "^0.3.3", + "hexo-renderer-marked": "^0.3.2", + "hexo-server": "^0.3.3" + } +} \ No newline at end of file diff --git a/page/2/index.html b/page/2/index.html deleted file mode 100644 index ee87da0..0000000 --- a/page/2/index.html +++ /dev/null @@ -1,1978 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/scaffolds/draft.md b/scaffolds/draft.md new file mode 100644 index 0000000..498e95b --- /dev/null +++ b/scaffolds/draft.md @@ -0,0 +1,4 @@ +--- +title: {{ title }} +tags: +--- diff --git a/scaffolds/page.md b/scaffolds/page.md new file mode 100644 index 0000000..f01ba3c --- /dev/null +++ b/scaffolds/page.md @@ -0,0 +1,4 @@ +--- +title: {{ title }} +date: {{ date }} +--- diff --git a/scaffolds/post.md b/scaffolds/post.md new file mode 100644 index 0000000..1f9b9a4 --- /dev/null +++ b/scaffolds/post.md @@ -0,0 +1,5 @@ +--- +title: {{ title }} +date: {{ date }} +tags: +--- diff --git a/CNAME b/source/CNAME similarity index 100% rename from CNAME rename to source/CNAME diff --git "a/source/_drafts/2018-11-8-\345\270\270\347\224\250Collections\351\233\206\345\220\210\345\256\236\347\216\260\345\216\237\347\220\206--hashMap.md" "b/source/_drafts/2018-11-8-\345\270\270\347\224\250Collections\351\233\206\345\220\210\345\256\236\347\216\260\345\216\237\347\220\206--hashMap.md" new file mode 100644 index 0000000..11bac3d --- /dev/null +++ "b/source/_drafts/2018-11-8-\345\270\270\347\224\250Collections\351\233\206\345\220\210\345\256\236\347\216\260\345\216\237\347\220\206--hashMap.md" @@ -0,0 +1,5 @@ +--- +layout: post +category: 技术 +uuid: 454790a9-e3d0-54c6-83bc-79660abbc7fa +--- diff --git "a/source/_drafts/2018-5-3-redis\345\205\245\351\227\250.md" "b/source/_drafts/2018-5-3-redis\345\205\245\351\227\250.md" new file mode 100644 index 0000000..6c57b9a --- /dev/null +++ "b/source/_drafts/2018-5-3-redis\345\205\245\351\227\250.md" @@ -0,0 +1,29 @@ +--- +layout: post +title: redis 入门 +category: redis +permalink: /redis/info.html +--- +### 什么是Redis? +Redis是一个开源(BSD许可)、具有数据结构的内存存储工具。可以作为数据库、缓存等工具来使用。它支持的数据类型 +有:string、hash、list、set、sorted set、bitmap、hyperloglog、geo。Redis支持主从复制、Lua脚本、LRU淘汰算法、 +事物、不同级别的持久化配置。同时还有哨兵来保证高可用,以及集群自动分区 + +### Redis的特性 +1. 内存存储,速度快 +1. 多种数据类型 +1. 主从复制 +1. 持久化 +1. 分布式 +1. 哨兵 +1. 发布与订阅 +1. 单线程原子操作 +1. 事物 + +### Redis的安装 + +### 数据结构介绍 + +### Redis可以用来做什么? +https://cloud.tencent.com/developer/article/1041390 +1. diff --git "a/source/_drafts/2018-5-3-redis\351\233\206\347\276\244.md" "b/source/_drafts/2018-5-3-redis\351\233\206\347\276\244.md" new file mode 100644 index 0000000..d143989 --- /dev/null +++ "b/source/_drafts/2018-5-3-redis\351\233\206\347\276\244.md" @@ -0,0 +1,6 @@ +--- +layout: post +title: redis 集群 +category: redis +permalink: /redis/cluster.html +--- diff --git "a/source/_drafts/mysql\344\270\255\347\232\204\351\224\201.md" "b/source/_drafts/mysql\344\270\255\347\232\204\351\224\201.md" new file mode 100644 index 0000000..c405769 --- /dev/null +++ "b/source/_drafts/mysql\344\270\255\347\232\204\351\224\201.md" @@ -0,0 +1,40 @@ +--- +title: Mysql 中的锁 +date: 2018-04-04 +category: 工具 +--- +参考: [锁的概念](https://www.jianshu.com/p/88231c4944f7)、 [锁的分析](https://blog.csdn.net/claram/article/details/54023216) + +正式介绍之前,先来捋一捋mysql中有哪些锁的名词。 +1. 乐观锁 +2. 悲观锁 +3. 共享锁(读锁) +4. 排它锁(写锁) +5. 行锁 +6. 表锁 + +看是有这么多的名词,其实可以把它们分成三个层级。 +1. 锁的分类 --> 乐观锁、悲观锁 +2. 悲观锁的实现方式 --> 共享锁、排它锁 +3. 锁的作用域 --> 行锁、表锁 + +具体关系,请看下图: +![mysql 锁的关系](http://qiniu.blog.sslfer.com/9e2f8dabc0b2ac1dbe14df29c1f308b8.png) + +概述:mysql的锁可以分为两类,一类是乐观锁,另一类是悲观锁。乐观锁是要自己实现的,是一种代码逻辑锁,并没有在mysql中正在的加锁。悲观锁mysql有两种实现,一种是共享锁,另一种是排它锁。 + +### 乐观锁 +是代码层面的逻辑控制。如果用数据库控制的话,一般就是新增一个字段来当锁。 +![锁的表](http://qiniu.blog.sslfer.com/268ab6ae571ce1c4b8d0445a9762aa94.png) +假如要修改name字段。做法如下: +```sql +-- 得到锁的值为0 +select * from tableName where id = 1; + +-- 修改name值 +update tableName set name='李四', lock=lock+1 where id=1 and lock = 0; -- 传入上面得到的lock值,修改成功要同时修改lock的值 +``` +因为没有真正的锁住表。这种操作非常适合数据多查询的表。 +什么是:查询多的? + +这里就一个疑问了,如果没有修改成功,该如何从新提交更新的操作呢? diff --git "a/source/_posts/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201.md" "b/source/_posts/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201.md" new file mode 100644 index 0000000..31aa324 --- /dev/null +++ "b/source/_posts/\345\237\272\347\241\200/\345\216\237\347\240\201\343\200\201\345\217\215\347\240\201\345\222\214\350\241\245\347\240\201.md" @@ -0,0 +1,101 @@ +--- +title: 原码、反码和补码 +date: 2018-10-29 +category: 基础 +id: 6a052db2-636b-542c-84a0-0d4d2424f93c +--- +工科的出现是为了解决某些问题,那原码、反码和补码同样也是为了解决某些问题而产生的。那到底是要解决什么问题呢? +全国人民都知道,pc电脑又叫计算机,计算机的最基本的功能就是计算,也就是数字的加减乘除。那好,我们来看看计算机到底是如何做加减乘除的。 + +在做计算前。需要先说明一下,计算机存储任何数据都是用二进制编码。文字是二进制、图像是二进制、视频是二进制同样数字也是二进制。这种二进制存储方式就是俗称的数字化。 +还有很重要的一点就是:计算机不会做减法。当我第一次听说的时候,很诧异,也很好奇。为什么呢?原来人们在设计计算机电路的时候,只保留了加法电路,从而简化了电路的设计与实现简单。只保留做加法的功能就能简化电路? +我的回答是肯定的。在数学中:2-1 = 2+(-1)、2*3 = 2+2+2、4/3 = 4-3 = 4+(-3)。用加法就可以做数字的运算。 +数字是有正负的,那计算机是如何表达正负的呢?计算机先驱们规定:**最高位0表示正数,1表示负数**。 + +## 一、方式一 +现在要计算机计算:3+2=? 用4位二进制来表示。**直接写出十进制的二进制码**。 +计算规则为:二进制码相加,溢出就丢掉。 + +3+2 = 0011 + 0010 = 0101 = +5 结果正确 + +计算:3-2=? 用4位二进制表示 +3-2 = 3+(-2) = 0011 + 1010 = 1101 = -5 错误 + +计算:3-3=? 用4位二进制表示 +3-3 = 3+(-3) = 0011 + 1011 = 1110 = -6 错误 + +计算:2-3=? 用4位二进制表示 +2-3 = 2+(-3) = 0010 + 1011 = 1101 = -5 错误 + +计算:-3-2=? 用4位二进制表示 +-3-2 = -3-2 = 1011 + 1010 = 1 0111 = 0111 = 7 错误 +> 10111等于0111是因为给的是4位,最高位溢出,所以得到了0111 + +小结:从上面5个计算结果来看,发现做减法一定是错误的(-3-2不是减法,而是需要强制写符号位的加法),做加法就没问题。 +那我们得出的结论是: +1. 做减法错误 +2. 0的表示有两种:0000 = +0,1000 = -0 +3. 符号位需要强制写入 + +## 二、方式二 +为了解决上面出现的几个问题,在上面的基础上做些调整:**正数不管,负数除开符号位,也就是最高位不管,其他的位置全部取反,是0变成1,1变成0**。 +计算规则为:在方式一的基础上,正数不用取反,负数取反,然后得到的二进制码相加,有溢出的话,就把剩下的部分加一,最后把加一所得的二进制码取反就是结果 + +还是分别计算上面的几个式子: +3+2 = 0011 + 0010 = 0011 + 0010 = 0100 = 0101 正确 + +3-2 = 3+(-2) = 0011 + 1010 = 0011 + 1101 = 1 0000 = 0001 = 0001 = 1 正确 +> 解释一下:1 0000 怎么就等于 0001了呢?其实是这样的,因为我们给的是4位,10000 长度为5位,所以最高位的1就溢出被丢弃掉了。因此,10000在4位的时候其实是为 +> 0000,为了到达计算的准确性,只要有进位(溢出)我们就用结果加一。 + +3-3 = 3+(-3) = 0011 + 1011 = 0011 + 1100 = 1111 = 1000 = -0 结果正确,符号错误 + +2-3 = 2+(-3) = 0010 + 1011 = 0010 + 1100 = 1110 = 1001 = -1 正确 + +-3-2 = 1011 + 1010 = 1100 + 1101 = 1 1001 = 1010 = 1101 = -5 正确 + +小结:减法可以正确计算,但是溢出需要加一才能得正确的结果。同时又有+0和-0的结果出现,需要取绝对值才是正确的值。得出的结论是: +1. 减法正确 +2. 0的表示有两种:0000 = 0000 = +0,1000 = 1111 = -0 +3. 溢出需要加一才能得到准确结果 +4. 在计算和取得最后结果之前,都需要做取反操作 +5. 当结果为0的时候需要取绝对值 + +## 三、方式三 +上面的方式二,虽然可以准确的做减法,但是同时也引入的一些新的问题,比如无法准确得到结果0、溢出需要加一操作等等。 +在使用计算机的时候,经常会听到性能一词。上面的计算方式明显不合乎追求高性能的做法。那有没有什么方法可以解决这个问题呢,计算机发展了这么多年肯定是有的。 +那我们就看看新的方法。 + +在方式二的取反基础上加一得到新的二进制编码,也就是:**正数不管,负数除开符号位,也就是最高位不管,其他的位置全部取反,是0变成1,1变成0,然后加1**。 +计算规则为:整数不管,负数取反然后做加法操作,溢出位不管,得到溢出之后的结果再做取反加一就是几个二进制码了 + +还是分别计算上面的几个式子: +3+2 = 0011 + 0010 = 0011 + 0010 = 0011 + 0010 = 0101 = 0101 = 5 正确 + +3-2 = 3+(-2) = (0011 + 1010)二进制 = (0011 + 1101)取反 = (0011 + 1110)加一 = 1 0001 = (0001)溢出 = (0001)正数不管 = 1 正确 + +3-3 = 3+(-3) = 0011 + 1011 = 0011 + 1100 = 0011 + 1101 = 1 0000 = 0000 = 0 正确 + +2-3 = 2+(-3) = (0010 + 1011)二进制 = (0010 + 1100)取反 = (0010 + 1101)加一 = 1111 = (1000)取反 = (1001)加一 = -1 正确 + +-3-2 = -3+(-2) = (1011 + 1010)二进制 = (1100 + 1101)取反 = (1101 + 1110)加一 = 1 1011 = (1011)溢出 = (1100)取反 = (1101)加一 = -5 正确 + +小结:计算结果全部正确,没有特殊的需要判断的操作,因此解决了+0和-0的问题,也没有了溢出加一操作。所以计算都是相同操作。 +因此得出的结论为: +1. 所有计算结果准确,且计算方式相同 +2. 没有+0和-0的结果 +3. 0000表示0,1000表示负的最小值,例如:8位就是:-128 + +“都到这里了,还是没有说原码、反码和补码的事“,肯定有朋友是这么想的。其实我已经说过了。方式一就是原码,方式二就是反码,方式三就是补码。那接下来我们来总结一下。 + +## 四、总结 +原码、反码和补码都是为了计算而产生的。只不过补码是为了解决原码和反码所带来的问题。现在的计算机一般都是用反码来计算。因此如果要问某种数据类型取值范围的话, +应该先得到该类型所占的字节数,然后根据1byte = 8bit可以得出取值范围为:-2^(n\*8-1)~2^(n\*8-1)-1。比如:java的int占多少位。就是-2^(4\*8-1)~2^(4\*8-1)-1 = +-2^31~2^31-1。 + +## 五、补码的推导 +// TODO + +参考: +* [有符号数处理\-\-维基百科](https://zh.wikipedia.org/wiki/%E6%9C%89%E7%AC%A6%E8%99%9F%E6%95%B8%E8%99%95%E7%90%86) +* [原码, 反码, 补码 详解\-\-张子秋](https://www.cnblogs.com/zhangziqiu/archive/2011/03/30/ComputerCode.html) diff --git "a/source/_posts/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242.md" "b/source/_posts/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242.md" new file mode 100644 index 0000000..3d6a736 --- /dev/null +++ "b/source/_posts/\345\237\272\347\241\200/\350\277\233\345\210\266\344\271\213\351\227\264\347\232\204\350\275\254\346\215\242.md" @@ -0,0 +1,141 @@ +--- +title: 进制之间的转换 +date: 2018-10-12 +category: 基础 +id: 473bc463-32c4-5ba3-85d5-34c26aee7e70 +--- +这篇文章是计算机基础的开篇,同时也是我这个非科班的从头学习计算知识的总结。 + +接下来你将看到: +* 什么是基数 +* 什么是权 +* 十进制转换为二、八、十六进制 +* 二、八、十六进制转换为十进制 +* 二进制和八进制之间的互转 +* 二进制和十六进制之间的互转 + +## 一、什么是进制? +> 进位制是一种记数方式,亦称进位计数法或位值计数法。利用这种记数法,可以使用有限种数字符号来表示所有的数值 --维基百科 + +## 二、常见用途 +1. **二进制**广泛用于计算机 +1. **三进制**用于军队编制 +1. **八进制**广泛用于计算机 +1. **十进制**最为常用 +1. **十二进制**用于计算时辰、月份、一打物品 +1. **十六进制**广泛用于计算机 +1. **二十进制**曾被玛雅文明使用 +1. **六十进制**用于计算时间与角度单元。如秒、分 + +## 三、转换之前要明白的 + +**基数**:计数系统拥有的计数字符的个数。 +> 例如:二进制的字符有:0、1,一共有2个字符。那二进制的基数就是2 +> 八进制的字符有:0、1、2、3、4、5、6、7,一共有8个字符。基数就是8 +> 十进制的字符有:0、1、2、3、4、5、6、7、8、9,一共有10个字符。基数就是10 +> 十六进制的字符有:0、1、2、3、4、5、6、7、8、9、A、B、C、D、E、F,一共有16个字符。基数就是16 + +**数字的位置**:小数点前的从0开始数;小数点后的从-1开始数。简单的理解就是:个位是位置0,向左位置+1,向右位置-1(可以为负数)。 +> 例如数字:7654.321。7的位置是3、6的位置是2、5的位置是1、4的位置是0、3的是-1、2的是-2、1的是-3 + +**权(位置决定的值)**: **基数**的(位置)次方的值。比如有一个十进制的数字:123.4。那各个数字的权为:1的为10^2、2的为10^1、3的为10^0、4的为10^-1 + +**任何数值都是各位数值本身的值与其权之积的总和**: +> 例如:二进制数 10101 = 1\*2^4 + 0\*2^3 + 1\*2^2 + 0\*2^1 + 1\*2^0 +> 十进制数 1023 = 1\*10^3 + 0\*10^2 + 2\*10^1 + 3\*10^0 + + +## 四、xxx进制转为十进制 +任何进制转换为十进制,都是按权展开,权值相加 + +### 1. 二进制 --> 十进制 +1001100.011 = ?(十进制) += 1\*2^6 + 1\*2^3 + 1\*2^2 + 1\*2^-2 + 1\*2^-3 += 64 + 8 + 4 + 0.25 + 0.125 += 76.375 + +### 2. 八进制 --> 十进制 +23574.23 = ?(十进制) += 2\*8^4 + 3\*8^3 + 5\*8^2 + 7\*8^1 + 4\*8^0 + 2\*8^-1 + 3*8^-2 += 8192 + 1536 + 320 + 56 + 4 + 0.25 + 0.046875 += 10108.296875 + +### 3. 十六进制 --> 十进制 +3b3d9.3a = ?(十进制) += 3\*16^4 + b\*16^3 + 3\*16^2 + d\*16^1 + 9\*16^0 + 3\*16^-1 + a*16^-2 += 3\*16^4 + 11\*16^3 + 3\*16^2 + 13\*16^1 + 9\*16^0 + 3\*16^-1 + 10*16^-2 += 196608 + 45056 + 768 + 208 + 9 + 0.1875 + 0.0390625 += 242649.2265625 + +## 五、十进制转为xxx进制 +十进制转换为其他进制的方法是:整数部分,不断除以基数 **(一直除到商等于0为止)**,余数倒排;小数部分,不断乘以基数,取积的整数部分,余下的小数继续乘以基数,直到为0为止。(因为小数部分是不断乘以基数有可能会无限乘下去,这就是精度问题的产生原因) + +### 1. 十进制 --> 二进制 +1239.31 = ?(二进制) +整数部分: += 1239 / 2 等于 619 于 1 += 619 / 2 等于 309 于 1 += 309 / 2 等于 154 于 1 += 154 / 2 等于 77 于 0 += 77 / 2 等于 38 于 1 += 38 / 2 等于 19 于 0 += 19 / 2 等于 9 于 1 += 9 / 2 等于 4 于 1 += 4 / 2 等于 2 于 0 += 2 / 2 等于 1 于 0 += 1 / 2 等于 0 于 1 + +小数部分: += 0.31 * 2 等于 0.62 整数为 0 += 0.62 * 2 等于 1.24 整数为 1 += 0.24 * 2 等于 0.48 整数为 0 += 0.48 * 2 等于 0.96 整数为 0 += 0.96 * 2 等于 1.92 整数为 1 += 0.92 * 2 等于 1.84 整数为 1 +... + +最后得到的结果是(整数部分倒排,小数部分正排):1239.31 ≈ 10011010111.010011 + +### 2. 十进制 --> 八进制 + +计算方式不变,还是和十进制转二进制一样,只是基数从2变为了8。具体详细的计算就略过了。 + +### 3. 十进制 --> 十六进制 + +基数变为16,其他不变。略 + + +## 六、二进八进制互转 + +核心思想就是:3位二进制数表示1位8进制数。小数点为分隔符。 + +### 1. 二进制 --> 八进制 + +小数点为分隔符,向前向后数,不足3位的补0。3为合并为1位 + +1001001011.01101 = ?(八进制) += 001 001 001 011.011 010 += 1 1 1 3.3 2 += 1113.32 + +### 2. 八进制 --> 二进制 + +3位展开 + +37436.24 = ?(二进制) += 011 111 100 011 110.010 100 += 011111100011110.010100 + +## 七、二进制十六进制互转 +四位展开或者四位合并 + +### 1. 二进制 --> 十六进制 + +略。和二进制转为八进制一个方式,只是3位合并变为了4位合并。 + +### 2. 十六进制 --> 二进制 + +略。和八进制转换为二进制一样。只是展开为3位变成了展开为4位。 + +## 八、总结 +// TODO \ No newline at end of file diff --git "a/source/_posts/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247.md" "b/source/_posts/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247.md" new file mode 100644 index 0000000..b29c131 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/Google \346\220\234\347\264\242\346\212\200\345\267\247.md" @@ -0,0 +1,66 @@ +--- +title: Google 搜索技巧 +date: 2018-4-4 +category: 工具 +id: fd427d9a-0a6c-53a4-9e86-f6991829e90c +--- +首先介绍google常用的命令 +1. 双引号(完全匹配搜索) +2. 减号(排除关键字) +3. 星号(通配符) +4. inurl(在url中出现) +5. inanchor(超链接上的文字) +6. intitle(在title中出现) +7. filetype(指定文件类型) +8. site(限定搜索某个域名) + +### 1.双引号 +说明:限定搜索出来的内容必须包含被引号引用的字符串。不区分中英文双引号 +格式:“xxxx” + +举个例子:搜索 重庆出租车。结果包含了:**重庆出租车**、**重庆**、**出租车** +![重庆出租车](http://qiniu.blog.sslfer.com/6e311bffce984ee36426c138e9d2d14b.png) +![重庆出租车其他结果](http://qiniu.blog.sslfer.com/cf4adf56cbafc7fc8adf4baf41a32344.png) +更改搜索方式:“重庆出租车” +![“重庆出租车”](http://qiniu.blog.sslfer.com/4c4856fe819f6951b90c4d7823625b7c.png) +![“重庆出租车-15页”](http://qiniu.blog.sslfer.com/6238f9242cdf5f6e7cca426a440573a3.png) + +### 2.减号 +说明:排除搜索出来的内容包含某个关键字 +格式:苹果 -apple,注意需要用空格来隔开 + +例如:搜索苹果,本意是要搜索可以吃的苹果相关内容,结果出现了以下不如意的内容: +![不如意的苹果](http://qiniu.blog.sslfer.com/e7b3aec88f26e04fd270ff4f9b650261.png) +排除官网 苹果 -官网,结果如下 +![苹果排除官网](http://qiniu.blog.sslfer.com/8ea8cf4ae9c18cba5a9334423b14823c.png) +继续排除,直到结果满意,苹果 -apple -官网 -公司 -地点 -系统 +![苹果满意的结果](http://qiniu.blog.sslfer.com/7d437601b346477f99bfb765a87ec6bb.png) + +### 3.星号 +说明:通配符,代表一个或多个字符 +格式:重庆\*车、出租车\*、\*重庆 + +### 4.inurl +说明:在链接中搜索 +格式:inurl:/admin/login.asp +![inurl-admin-login](http://qiniu.blog.sslfer.com/d9e387491a48897fec27d3641c7f4e58.png) + +### 5.inanchor +说明:搜索的是超链接上的文字。可能返回的页面不一定带有这个超链接。 +格式:inanchor:下载。这个的意思就是:搜索包含下载这个超链接的页面。 +![下载是超链接](http://qiniu.blog.sslfer.com/54e7b715e16c689d44045f0a40448bb6.png) + +### 6.intitle +说明:标题包含的 +格式:intitle:后台登录 +![后台登录](http://qiniu.blog.sslfer.com/9c44f3ab15a6b160597b81a7698ff799.png) + +### 7.filetype +说明:限定搜索出来的格式 +格式:filetype:doc +![filetype](http://qiniu.blog.sslfer.com/1b02a68128dac5813390dbe99a10d9a4.png) + +### 8.site +说明:限定某个网址 +格式:下载 site:baidu.com +![baidu下载](http://qiniu.blog.sslfer.com/07e489ea60ffa471c89258233967a918.png) diff --git "a/source/_posts/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217.md" "b/source/_posts/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217.md" new file mode 100644 index 0000000..a3de838 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/centos7\344\277\256\346\224\271\346\272\220\351\225\234\345\203\217.md" @@ -0,0 +1,29 @@ +--- +title: Centos7 修改源镜像 +date: 2018-3-31 +category: 工具 +id: 675c6c40-5fd5-5f63-8af9-e5fedf20a22a +--- +默认的源在国内访问一点慢。修改为阿里云的 + +```shell +先安装 wget +yum install wget -y + +备份当前的yum源 +mv /etc/yum.repos.d /etc/yum.repos.d.backup4comex + +新建空的yum源设置目录 +mkdir /etc/yum.repos.d + +下载安装阿里云的yum源配置 +wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo + +情况仓库缓存 +yum clean all + +重新创建缓存 +yum makecache + +大功告成 +``` diff --git "a/source/_posts/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6.md" "b/source/_posts/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6.md" new file mode 100644 index 0000000..f47d1e3 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/centos7\345\256\211\350\243\205mysql5.6.md" @@ -0,0 +1,37 @@ +--- +title: CentOS7 安装 mysql5.6 +date: 2018-3-31 +category: 工具 +id: b8c75212-4125-53f4-9814-34c5c2345617 +--- +安装步骤如下: +```shell +1.安装mysql的源 +rpm -Uvh http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm + +2.查看可以安装的mysql +yum repolist enabled | grep "mysql.*-community.*" + +3.执行安装 +yum -y install mysql-community-server + +4.安装成功,加入开机启动 +systemctl enable mysqld + +5.启动mysql +systemctl start mysqld.service + +6.配置myslq +mysql_secure_installation + +配置项: + 1.设置root用户密码 + 2.删除匿名用户 + 3.禁止root远程登录 + 4.删除test数据库 + 5.刷新权限 + +7.配置root远程登录 +GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION; + +``` diff --git "a/source/_posts/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201.md" "b/source/_posts/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201.md" new file mode 100644 index 0000000..e4dc9b8 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/git bash \344\270\255\346\226\207\344\271\261\347\240\201.md" @@ -0,0 +1,24 @@ +--- +title: Git Bash 中文乱码 +date: 2018-9-3 +category: 工具 +tags: [git] +id: 41c9072e-e270-54d2-9a58-88512f1ac552 +--- + + +#### git status 乱码 +执行:git status 命令时,本来该显示中文的地方,都显示成了数字,特别难受。 +![2018-09-03-19-43-15](http://qiniu.blog.sslfer.com/2018-09-03-19-43-15.png) + +解决办法如下: +执行:**git config \-\-global core.quotepath false** 就恢复正常了 + +![2018-09-03-19-46-25](http://qiniu.blog.sslfer.com/2018-09-03-19-46-25.png) + +#### git log 乱码 +```shell +git config --global i18n.commitencoding utf-8 +git config --global i18n.logoutputencoding utf-8 +export LESSCHARSET=utf-8 +``` \ No newline at end of file diff --git "a/source/_posts/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225.md" "b/source/_posts/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225.md" new file mode 100644 index 0000000..ab5251a --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/markdown\345\237\272\346\234\254\350\257\255\346\263\225.md" @@ -0,0 +1,40 @@ +--- +title: Markdown 基本语法 +date: 2018-3-28 +category: 工具 +id: 37ff7c42-56bd-5798-8231-bde4dfbd3377 +--- + +[参考地址](http://xianbai.me/learn-md/article/about/readme.html "title:参考地址") + +标题:{ \# } 几个\#就代表着几级标题。 + +引用:{ \> } + +有序列表:{ 1. } 注意有空格 + +换行:{ 两个空格 } + +无序列表:{ \* 或者 + 或者 - } + +代码:{ \`\`\`java } + +分割线:{ \*\*\* } + +链接:{ \[a标签里的文字\](真正的链接地址 "title提示文字") } title提示文字可以没有,如果要有的话,前面不要忘了空格 + +自动链接:{ <链接地址> } + +参考:{ 参考 图片-参考方式 } + +图片-行内: { \!\[备注文字\]\(具体的图片地址 "图片提示文字"\) } markdown不是调整图片大小,可以使用img标签来设置 + +图片-参考方式:{ \!\[备注文字][参考标识] [参考标识]:url "图片提示文字" } 例如:![GitHub][github] + +\[github]: https://avatars2.githubusercontent.com/u/3265208?v=3&s=100 "GitHub,Social Coding" + +*斜体*:{ \*斜体文字* } + +**加粗**:{ \**加粗文字** } + +~~删除线~~:{ \~~删除的文字~~ } diff --git "a/source/_posts/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273.md" "b/source/_posts/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273.md" new file mode 100644 index 0000000..88cba14 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/mysql\350\257\273\345\206\231\345\210\206\347\246\273.md" @@ -0,0 +1,81 @@ +--- +title: Mysql 读写分离 +date: 2018-3-31 +category: 工具 +id: 8cfbd408-99a7-5159-80d1-8137643ae2fb +--- +mysql版本为:5.6 +要读写分离,就要配置mysql的同步。 +mysql的同步又分为:异步同步(默认),半同步同步。 + +### 同步原理 +[mysql主从复制-介绍](https://blog.csdn.net/jesseyoung/article/details/41942467) + +### 同步配置步骤 +```shell +1.开启master的log-bin,并配置server-id,设置要同步的数据库 +[mysqld] +log-bin=mysql-master-bin +server-id=1 +# 设置要同步的数据库 +binlog-do-db=test +# 设置不同的数据库 +binlog-ignore-db=information_schema +binlog-ignore-db=performance_schema +binlog-ignore-db=mysql + + +2.在master上创建一个可以用来同步的账户,并赋上相应的权限 +grant REPLICATION SLAVE on *.* to 'repl'@'%' identifiled by '密码'; + +3.(看情况可选操作)停止master新提交数据 +FLUSH TABLES WITH READ LOCK; +UNLOCK TABLES; + +4.查看master状态 +SHOW MASTER STATUS; +#在主库上查看已连接的slave主机 +show slave hosts; +#查看所有binlog日志 +show binary logs; +#查看所有binlog 事件 +show binlog events in 'mysql-bin.000003'; + +5.配置slave节点 +[mysqld] +log-bin=mysql-slave-bin +server-id=2 +# 设置要同步的数据库 +binlog-do-db=test +# 设置不同的数据库 +binlog-ignore-db=information_schema +binlog-ignore-db=performance_schema +binlog-ignore-db=mysql + +6.在slave上连接master +change master to master_host='192.168.1.11',master_user='repl',master_password='654321',master_log_file='mysql-master-bin.000003',master_log_pos=397; +7.在salve启动slave功能 +start slave; +# 停止 +stop slave; + +8.查看是否启动成功 +show slave status \G; + +以下两个参数为Yes则为启动成功 +Slave_IO_Running: Yes +Slave_SQL_Running: Yes + +``` +以上是使用了默认(statement)的bin-log记录模式以及异步复制。 + +```shell +# 修改bin-log记录模式 +binlog_format=mixed +# 半同步复制 +rpl_semi_sync_master_enabled=ON + +``` +### 读写分离步骤 +使用的时360的Atlas +[Atlas安装官方文档](https://github.com/Qihoo360/Atlas/wiki/Atlas%E7%9A%84%E5%AE%89%E8%A3%85) diff --git "a/source/_posts/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205.md" "b/source/_posts/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205.md" new file mode 100644 index 0000000..25d5daa --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/rabbitmq centos \345\256\211\350\243\205.md" @@ -0,0 +1,47 @@ +--- +title: Rabbitmq CentOS 安装 +date: 2018-8-20 +category: 工具 +id: c6addbb6-e6f1-5da7-a03c-614adae59eae +--- + +在安装之前,我们需要准备的运行环境有: +> 1. Erlang (是一种通用的面向并发的编程语言) +> 1. socat (端口转发工具)) + +另外需要明确的一点是,使用Centos的版本。以下是Centos6安装 +ps.Centos7也是一样的安装步骤,只是下载的软件版本不一样 + + +### Erlang的安装 +> wget https://dl.bintray.com/rabbitmq/rpm/erlang/21/el/6/x86_64/erlang-21.0.2-1.el6.x86_64.rpm +rpm -ivh erlang-21.0.2-1.el6.x86_64.rpm + +### socat的安装 +> yum -y install socat + +### rabbitmq的安装 +> wget https://dl.bintray.com/rabbitmq/all/rabbitmq-server/3.7.7/rabbitmq-server-3.7.7-1.el6.noarch.rpm +rpm -ivh rabbitmq-server-3.7.7-1.el6.noarch.rpm + +经过以上的步骤,rabbitmq应该已经是安装成功了。那接下来就是rabbitmq的配置 + +```shell +# 服务的启动 +service rabbitmq-server start # 启动mq服务 +rabbitmq-plugins enable rabbitmq_management # 开启web管理 +chkconfig rabbitmq-server on # 开启开机启动 + +# 端口的开启 +iptables -I INPUT -p tcp -m tcp --dport 15672 -j ACCEPT # 开启端口 +iptables -I INPUT -p tcp -m tcp --dport 5672 -j ACCEPT # 开启端口 +service iptables save # 保持规则(要不然重启之后上面的两个规则丢失) +service iptables restart # 重启iptables服务(可以不用执行) + +# 用户的添加(默认的guest只能在localhost中登录,当然也可以更改权限) +rabbitmqctl add_user admin 123456 # 添加 用户:admin 密码:123456 +rabbitmqctl set_user_tags admin administrator # 给admin管理员的角色 +rabbitmqctl set_permissions -p "/" admin '.*' '.*' '.*' # 设置用户权限(接受来自所有Host的所有操作) +``` + +访问你的主机:xxxx:15672 开启rabbitmq之旅吧! diff --git "a/source/_posts/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250.md" "b/source/_posts/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250.md" new file mode 100644 index 0000000..3ae0b77 --- /dev/null +++ "b/source/_posts/\345\267\245\345\205\267/\347\274\226\347\250\213\345\231\250\346\225\221\347\240\226\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250.md" @@ -0,0 +1,76 @@ +--- +title: 编程器救砖小米mini路由器 +date: 2017-11-21 +category: 工具 +tags: [救砖 , 小米mini路由器] +id: e2c32f3b-5991-5806-b5cf-4994bf0caad2 +--- + +这个教程也适用修复sn码。**申明: 刷机有风险,需谨慎。一切后果与本人无关**。 + +### 变砖原因 + +刚把路由器买来的时候,就迫不及待的刷成了PandoraBox,用了一段时间之后,想刷回官方的系统,在 +刷回实际操作的时候,选错了方法,还是使用了刷PandoraBox的方式。导致路由器通电之后,一直 +处于黄灯状态。ssh无法连接路由器。使用usb刷系统,处于红灯状态。我下意识就知道成砖头了。 + +吐槽一下小米之家,变砖之后我就直接去了小米之家,他们的维修方式只有两种:一种是在保修期内直接 +换新的。另一种是保修期外返厂维修(他们是没有线刷设备的,维修不了)。我是过了保修期,又不想返 +厂。为什么呢?我敢肯定的是硬件没有坏、有一点硬件的知识、不着急用、想练练手。 + +### 工具的准备 + +- 电脑一台 +- CH341A编程器和驱动 +- 编程器夹子 +- 十字和一字螺丝刀 +- WinHex软件 +- 小米mini路由器编程器固件 + + +编程器和夹子都可以从某宝买来也不贵,但需要注意的是: **夹子的针脚数是8,别买错了** +驱动和编程固件[点击下载](http://qiniu.blog.sslfer.com/%E5%88%B7%E6%9C%BA%E9%A9%B1%E5%8A%A8%E5%92%8C%E5%88%B7%E6%9C%BA%E5%9B%BA%E4%BB%B6.zip) + +### 操作步骤 + +#### 1.拆路由器 + +一开始拿到路由器的时候,根本不知道从哪里下手,其实是要把他 ![背面的封条](http://qiniu.blog.sslfer.com/b843a3b47d108d19d5904890e5d5d2ca.png) 撕掉(放到一边备用),就会露出螺丝来。 +撕下来之后,就到了破开外壳了。用一字螺丝刀把路由器的这两边 ![撬开地方](http://qiniu.blog.sslfer.com/9ce6eba2ae3eb2e9a1fcce44e4ef4102.png) 撬开,再用一点劲就可以掰开了。备用。 + +#### 2.修改编程固件 + +这个步骤是修复sn码,如果你不修复的话,无法绑定小米账号,也就无法用手机端管理路由器。不修复,能不能救活路由器我就不知道了,因为没有测试过。 + +用WinHex打开小米mini编程器固件(**文件-打开-选择小米mini编程器固件**),使用快捷键 **ALT+G**,输入 **00FF0004** 如图(图片来自网络)![修改sn](http://qiniu.blog.sslfer.com/ae940eafc8146b1b68ed967fbee62d65.png) 就到了要我们修改的地方了。上图黄色标注的地方就是要替换的sn,我们自己路由器的sn就在从拆开路由器时,撕下来的标签上写着的。 + +这里修改sn的时候,并不是可以直接就把黄色标注的地方修改过来,而是需要在左边16进制区域进行修改。需要注意的是:16进制区域两个字母代表右边的一个数字。例如:00代表0,01代表1,以此类推09代表9。好在sn码全是数字,就可以自己使用刚刚的规则直接修改了。 + +在左边区域移动光标到要修改地方的起始位(移动的时候,右边的光标也会跟着移动,注意,右边移动两次,左边才移动一次。原因刚刚说过了)。把sn码逐个替换,替换完一个数字之后,看看右边显示的是不是我们想要的数字。 + +替换完成之后,还有一步重要的操作。**选块计算CRC32**,步骤是,标记一个起始位和一个截止未,计算这一段的 **CRC32(32bit)** 值。具体操作为:ALT+G 转到偏移量输入00FF0004,再按ALT+1(选块起始),按ALT+G转到偏移量输入00FF3FFF,再按ALT+2(选块结束),这样就选择好了块。再按CTRL+F2选择计算CRC32(注意类型)。就会得到一个值。记下这个值。 **倒序** 修改这个地方。如图(来自网络) ![填写CRC32值](http://qiniu.blog.sslfer.com/9124b5aa11981c2da89f3db2dec95e52.png) 修改完成之后,保存。这个就是我们等会要刷入路由器的固件了。 + +#### 3.刷机 + +这一步有两个难点。1.驱动的安装。2.正确的连接路由器和编程器。 + +驱动的安装,我就不说了。我是找了很多却动和换了3台电脑才成功了,重点说说连接路由器 +正确连接的关键是: **找到路由器闪存、夹子和编程器的第一个脚**。 +闪存器第一个脚是这个(来源网络): ![闪存器第一个脚](http://qiniu.blog.sslfer.com/c4eec85d9264ce180892307c3ed6c574.png) +夹子的第一个如图 +![夹子第一个脚](http://qiniu.blog.sslfer.com/91d43d7d460f105b0c8a286054efca06.png) +编程器的第一个脚如图 ![编程器第一个脚](http://qiniu.blog.sslfer.com/2151953c7a30b9c2a1990dc1c5418d4a.png) 注意放入的位置要和图片指示的位置一样。别上下搞反了。 + +这个三个地方的第一个脚全部连接好了之后,就可以用CH341A编程器软件刷机了。**注意的是,在使用编程器夹子的时候千万不要给路由器通电,切记!** + +步骤是:检测-[读取-保存]-擦除-查空-打开(第二步修改保存的固件)-编程-校验。 +读取和保存可以不操作,这步是保存刷机前路由器你的程序固件。编程的时候要等一段时间。一般都会校验通过的,通过了就代表着刷机成功了。赶快去下编程器,通电试试吧! + +来几张我实际刷机的图片 +![实际图片1](http://qiniu.blog.sslfer.com/c95cc33accc889d9cc2baaa2267cd344.png) +![实际图片2](http://qiniu.blog.sslfer.com/79528effff185b777c3505275c4fbe73.png) +![实际图片3](http://qiniu.blog.sslfer.com/404e68d343fbbd9055287dd8e25e07b5.png) + +### 总结 + +正确连接路由器和编程器是关键。驱动安装可能会出现错误,要有道耐心。 diff --git "a/source/_posts/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206.md" "b/source/_posts/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206.md" new file mode 100644 index 0000000..5be13d6 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/java\345\212\250\346\200\201\344\273\243\347\220\206.md" @@ -0,0 +1,110 @@ +--- +title: Java 动态代理 +date: 2018-3-27 +category: 技术 +id: e19b6759-8338-5054-a699-40fb7235f3b0 +--- +什么是[代理模式](/designPatterns/proxy.html)已经说明过了,那为什么Java又会有动态代理呢? + +### 静态代理模式的缺点 +1. 每代理一个类,都要编写一个代理类。如果需要代理大量的类那就不好维护代码了。 +2. 如果代理要增加一个代理方法的话,那么所有的代理都需要同时修改。 + +### 什么是Java动态代理 +代理实现的本质就是:生成一个代理类来代理执行。动态代理就是:动态生成一个代理类。也就是在 +程序运行期间,由JVM通过反射机制动态的生成一个代理类。 + +### Java动态代理的分类 +1. Jdk代理===接口代理 +2. Cglib代理===子类代理 + +### jdk代理的实现方式 + +```java +/** + * 定义一个卖火车票接口 + */ +public interface IticketSales { + void ticketSales(); +} + +/** + * 火车站实现买票接口 + */ +public Class TrainStation implement IticketSales { + + @Override + public void ticketSales(){ + System.out.println("火车站卖票"); + } + +} + +import java.lang.reflect.InvocationHandler; + +public Class TrainStationProxy implement InvocationHandler { + // 代理目标类 + Object target; + + public TrainStationProxy(){ + + } + + public TrainStationProxy(Object target){ + this.target = target; + } + + /** + * @Parama proxy 动态生成的代理类 + * @Parama method 动态生成的代理类的被代理方法 + * @Parama args 被代理方法的参数列表 + */ + @Override + public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { + + // 在目标对象的方法执行之前简单的打印一下 + System.out.println("------------------before------------------"); + + // 执行目标对象的方法 + Object result = method.invoke(target, args); + + // 在目标对象的方法执行之后简单的打印一下 + System.out.println("-------------------after------------------"); + + // 代理方法的返回值 + return result; + } + + /** + * 简化获取代理类的方式 + */ + public Object newProxyInstance(){ + Class targetClass = target.getClass(); + Proxy.newProxyInstance(targetClass.getClassLoader(), targetClass.getInterfaces(), this); + } +} + +/** + * 测试 + */ +public static void main(String[] args) { + IticketSales iticketSales = new TrainStation(); + + // 获取代理对象 + IticketSales trainStationProxy = (IticketSales) new TrainStationProxy(iticketSales).newProxyInstance(); + + // 调用方法 + trainStationProxy.ticketSales(); +} + +``` +### 问题: +1. 为什么jdk动态代理在没有实现接口类中不起作用? +2. 先生成的代理对象后,在调用的方法时,动态代理它怎么知道应该代理哪个方法,是不是把接口的所有方法都代理了? + +在回答问题之前,我们先去看看Jdk是如何实现动态代理的。 + + + + +### cglib代理的实现方式 diff --git "a/source/_posts/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273.md" "b/source/_posts/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273.md" new file mode 100644 index 0000000..4040c06 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/java\346\227\245\345\277\227\344\275\223\347\263\273.md" @@ -0,0 +1,35 @@ +--- +title: Java 日志体系 +date: 2018-4-17 +category: 技术 +id: 29a4624a-0b10-520d-bd68-c034e35d084c +--- +在工作中,我们可以接触到很多的日志jar包,比如:java.util.logging、log4j、log4j2、logback、slf4j等等。那我们应该怎么使用呢? + +### 一、日志分类和作用关系 +![日志关系](http://qiniu.blog.sslfer.com/b440fd2a566cf6df1fff7e6d1b5307dd.png) + +日志门面的说明: +我们常用的门面有两个,一个是apache的common-logging-api简称:**jcl**。另外一个是:slf4j-api 简称 **slf4j**。 + +### 二、常用门面的区别 +他们的区别在于:jcl是检测classpath下存在什么日志就用什么日志。slf4j需要手动的添加适配器包到classpath下,也就是手动设置要用到的日志。 + +### 三、日志的嫁接 +现在我们通常使用的是slf4j,同时也使用了spring。但是spring使用的是jcl门面。所有就需要做日志的嫁接了。如果不做的话,spring的日志我们是无法打印的。除非再给spring专门配一个日志打印。 +怎么嫁接呢? +1. 从classpath中移除之前的日志实现。 +2. 在classpath中引入一个叫:jcl-over-slf4j的jar包。 + +嫁接之后,spring日志具体的执行流程就变成这样了(实线箭头方向): +![jcl-over-slf4j](http://qiniu.blog.sslfer.com/b16f19a2d5fb1061026916e675f959d3.png) + +同样,想把slf4j嫁接到jcl,只需要移除之前的适配器,然后引入sl4j-jcl就可以了。 + +上面说的都是从一个门面嫁接到另一个门面。当然,从一个具体的日志实现,同样也是可以嫁接到日志门面的。比如:把log4j嫁接到slf4j上,只需要引入log4j-over-slf4j。 + +### 四、循环引用的问题 +这个问题是会引发**栈溢出**(StackOverflowError),具体是什么一个情况呢。如下图: +![栈溢出](http://qiniu.blog.sslfer.com/cc58213747bae479e850dd8a8db504cb.png) + +本来slf4j就是用的log4j来打印日志的,结果又加入了log4j嫁接到slf4j上的jar包。所以也就发生了循环。 diff --git "a/source/_posts/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273.md" "b/source/_posts/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273.md" new file mode 100644 index 0000000..cfbda34 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/mysql \344\272\213\345\212\241\351\232\224\347\246\273.md" @@ -0,0 +1,106 @@ +--- +title: Mysql 事务隔离 +date: 2018-9-5 +category: 技术 +tags: [mysql, spring] +id: f8e531b2-84c9-5e3e-96ff-caf779eeeba0 +--- + +### 一、数据库事务的基本特性 + +事物是区分文件存储系统和Nosql数据库的重要特征之一。它存在的意义是保证在并发情况下的curd的正确性。那怎样才能算是正确的呢? +那就是事物的4个特性,即ACID: +1. A:原子性(atomicty) + > 事物中的各个操作,要么全部成功,要么全部失败。 +1. C:一致性(consistency) + > 事物结束后,各个状态应该是一致的,是正确的。 +1. I:隔离性(isolation) + > 并发中的各个事物之间,彼此不能看到对方的中间状态。换句话说,不能查询到其他事物的修改。 +1. D:持久性(durability) + > 保存事物的所有修改 + +在高并发下是很难完全同时保证ACID的。除非把所有的事物都串行执行,但串行所带来的效率问题又是我们不愿意接受的。为了解决这个问题。数据库提出了 +事物的隔离级别。它允许我们在不同的业务场景下使用不同的策略来做ACID和效率之间的权衡。 + +事物的隔离级别分为以下4种: + +1. 读未提交 RU (Read uncommitted):可以读到其他事务没有commit的数据。 +1. 读提交 RC (Read committed):只能读到其他事务已经提交了的数据,但是自己事务中的数据,可以被其他事务修改。 +1. 可重复读 RR (Repeatable read): +1. 可串行(Serializable):所有事务依次执行,效率最低,保证ACID。 + +| 隔离级别 | 脏读 | 不可重复读 | 幻读 | +|---------|------|-------|------| +|未提交读 | 可能| 可能 | 可能 | +|提交读 |不可能| 可能 | 可能 | +|可重复读 |不可能| 不可能 | 可能 | +|可串行化 | 不可能| 不可能 | 不可能 | + +有了上面的定义和理论。我们就来实践一下具体隔离级别的。在实践之前,先准备好实践环境。 + +首先创建一张测试表 +```sql +CREATE TABLE `test` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `name` varchar(255) DEFAULT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8; +``` + +然后打开两个console。并且设置自动提交为off。 + +![2018-09-06-09-41-46](http://qiniu.blog.sslfer.com/2018-09-06-09-41-46.png) +![2018-09-06-09-42-05](http://qiniu.blog.sslfer.com/2018-09-06-09-42-05.png) + +到此,环境已经准备完毕,开始测试。 + +#### 读未提交(RU) + +先设置session的事务隔离级别为:read uncommitted(RU)。**两个console都要设置**。 +```sql +set session transaction isolation level read uncommitted; +``` + +测试流程如下: +![2018-09-06-10-00-54](http://qiniu.blog.sslfer.com/2018-09-06-10-00-54.png) + +可以看到当前事务读取到了其他事务未提交的修改(未确认 commit)。我们把没有commit的数据称为脏数据,因为没有commit的数据还可能发生rollback。 + +#### 读提交(RC) + +先设置session的事务隔离级别为:read committed(RC)。**两个console都要设置**。 +```sql +set session transaction isolation level read committed; +``` + +测试流程如下: +![2018-09-06-13-50-33](http://qiniu.blog.sslfer.com/2018-09-06-13-50-33.png) + +RC级别,不能读取其他事务未提交的数据,脏读问题也就解决了,但是可以发现,在同一次事务中多次查询是数据结果不一致。这也就导致不可重复读取的问题。 +如果要解决这个问题,那也就只能是RR级别了。另外,RC级别是Oracle的默认级别(未验证)。 + +#### 可重复读(RR) + +先设置session的事务隔离级别为:repeatable read(RR)。**两个console都要设置**。 +```sql +set session transaction isolation level repeatable read; +``` + +测试流程如下: +![2018-09-06-14-09-52](http://qiniu.blog.sslfer.com/2018-09-06-14-09-52.png) + +在这个级别中。可以发现,已经解决了在同一个事务中多次查询不一致的问题。但是幻读的问题还是存在,**myslq innodb 默认的事务隔离级别是:RR,但它自己解决了幻读**。 +那什么是幻读呢? + +幻读,简单讲就是在事务中前后读取的数据条数不一致。感觉就像是产生幻觉一样。那它和不可重复读有什么区别呢? +不可重复读:是数据的修改,即update、delete。 +幻读:也是数据新增,即insert。 + +举个例子:目前表中余额剩余1000块的人有10人。事务A查询余额为1000元的用户查询到了10人,未提交事务。之后,事务B向表中插入了一条余额也为1000的记录。 +事务A再次查询余额为1000的人,结果查询出了11条记录。这就是幻读。 + +#### 串行 +所以事务串行执行,事务隔离级别最高。效率最低。 + + +参考:https://blog.csdn.net/a837199685/article/details/54563740 \ No newline at end of file diff --git "a/source/_posts/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217.md" "b/source/_posts/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217.md" new file mode 100644 index 0000000..be09627 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/\344\273\243\347\220\206\346\250\241\345\274\217.md" @@ -0,0 +1,86 @@ +--- +title: 代理模式 +date: 2018-3-27 +layout: post +category: 技术 +id: 3d1a00a7-00e1-59d8-8a8c-6441c3ed3e31 +--- +### 一、什么是代理模式 +为其他对象提供一种代理,以控制对这个对象的访问。 + +### 二、具体控制了被代理对象的哪些访问? +1. 新增被代理对象不存在的方法 +2. 屏蔽被代理对象中的某些方法 +3. 扩展被代理的方法 + +### 三、实际应用场景 +场景一:购买火车票 +> 最开始我们购买火车票一定要去火车站购买。然而火车站大多却是在大城市的边缘地区,离我们生活的区域较远, +购买极其不方便。这个时候,就出现了火车票代售点。它不但可以购买车票,而且还提供预约购票等额外的功能。但是, +却又不提供退票功能(可能实际上有提供),要退票只能去火车站退。 + +场景二: + +### 四、代理的分类 +1. 静态代理 +2. 动态代理 [Java动态代理](/java/base/dynamicProxy.html) + +### 五、具体的实现方式 +静态代理: +在编写代码前,一定要记住,代理就用是一个类来代替另外一个类来处理事情。 +```java +/** + * 定义一个卖火车票接口 + */ +public interface IticketSales { + void ticketSales(); +} + +/** + * 火车站实现买票接口 + */ +public Class TrainStation implement IticketSales { + + @Override + public void ticketSales(){ + System.out.println("火车站卖票"); + } + +} + +/** + * 火车站实现买票接口 + */ +public Class TrainStationProxy implement IticketSales { + // 被代理对象 + private IticketSales target; + + public TrainStationProxy(){ + + } + + public TrainStationProxy(IticketSales target){ + this.target = target; + } + + @Override + public void ticketSales(){ + System.out.println("代售点--购票开始--欢迎来购买火车票"); + target.ticketSales(); + System.out.println("代售点--购票结束--祝你购票愉快,并送了一瓶水"); + } + +} + +public static void main(String[] args) { + // 被代理对象 + IticketSales trainStation = new TrainStation(); + + // 代理对象 + IticketSales trainStationProxy = TrainStationProxy(trainStation); + + // 执行购票方法 + trainStationProxy.ticketSales(); +} + +``` diff --git "a/source/_posts/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247.md" "b/source/_posts/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247.md" new file mode 100644 index 0000000..22c2723 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/\345\205\261\344\272\253\345\217\230\351\207\217\347\232\204\345\217\257\350\247\201\346\200\247.md" @@ -0,0 +1,54 @@ +--- +title: 共享变量的可见性 +date: 2018-3-26 +category: 技术 +id: 0163b9d0-8775-5323-8ea3-0d43898f87f8 +--- + +### 一、什么是多线程共享变量的可见性 +线程A对共享变量number的修改,在线程B中,能够及时的看到。 + +### 二、原子性 +又叫代码执行不可分割性。顾名思义就是在程序执行的时候,获取了CPU执行权利后,该代码就必须要在这个运行状态中,全部执行完。不能执行一部分后等待下一次该线程的运行状态执行。 + +### 三、什么是共享变量 +变量同时在多个线程中存在副本。那这个变量就是线程的共享变量。具体表现为:类的成员变量。 + +### 四、如何保证共享变量的可见性 +换句话说就是:怎样才能保证变量在一个线程中的修改,其他线程可以准确无误的读取到。 +要想实现这样的想法,那就要保证:变量在同一时刻,只能一个线程读取和修改。在Java中,提供了两个关键字来实现该操作。synchronized和volatile。 + +### 五、Java多线程简单的内存模型 +内存分为:主内存和线程工作内存。如下图: +![Java内存模型(JMM)](http://qiniu.blog.sslfer.com/11a575730e81de83b8bbf65f0597a000.png) + +Java中所有的变量都存在于主内存中,线程工作内存中存放了共享变量的副本。 + +线程对共享变量的操作只能在自己的工作内存中进行,不能直接读取主内存。 +不同线程之间不能访问其他线程的工作内存,线程间的变量传递只能通过主内存中转。 + +由上图可见:线程1对x的修改要想线程2及时看到要经过两个步骤: +1.把工程内存1中的共享变量刷新到主内存中。 +2.线程2从主内存中同步共享变量到工作内存2中。 + +### 六、synchronized(同步) +作用:保证代码块的原子性和共享变量的可见性。 +实现步骤: +1. 获取互斥锁。 +2. 清空工作内存。 +3. 把主内存中的共享变量存放到工作内存中。 +4. 执行synchronized代码块。 +5. 同步工作内存变量到主内存中。 +6. 释放互斥锁。 + +### 七、volatile +作用:保证共享变量的可见性。 +原理:在对volatile变量执行写操作后,立即强制线程把该共享变量的更新到主内存中。在执行读操作时,强制线程从主内存中读取该变量的值。 +注意事项:一般在多线程中使用volatile变量,对变量的写操作不能依赖变量本身。如:number++,num = num * 5等。 + +### 八、synchronized和volatile对比 +1. volatile只能保证共享变量的可见性。 +2. synchronized既能保证可见性,也能保证原子性。 +3. volatile不需要加锁。比synchronized更轻,还不会阻塞线程。 +4. volatile只能修饰变量,synchronized能修饰类、方法和代码块。 +5. synchronized能被编译器优惠,比如代码的重排序。 diff --git "a/source/_posts/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader.md" "b/source/_posts/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader.md" new file mode 100644 index 0000000..9e500ca --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/\347\261\273\345\212\240\350\275\275\345\231\250classLoader.md" @@ -0,0 +1,39 @@ +--- +title: 类加载器 ClassLoader +date: 2018-3-29 +category: 技术 +id: 0d8b4686-1c4d-5c2b-91a5-facc34d40228 +--- + +[参考](https://blog.csdn.net/briblue/article/details/54973413) + +### 什么是类加载器 +顾名思义就是加载类文件用的,也就是加载源代码文件编译后的class文件。只有加载到了jvm中才可以 +执行。 + +### 加载器的分类 +BootstrapClassLoader、ExtentionClassLoader、AppClassLoader、自定义的ClassLoader + +### 各个加载器的关系 +默认关系是: +BootstrapClassLoader 是 ExtentionClassLoader 的父加载器。 +ExtentionClassLoader 是 AppClassLoader 的父加载器。 +AppClassLoader 是 自定义的ClassLoader 的加载器。 + +注意:在java中,如果获取到的父加载器是null,那么就说明实际上是BootstrapClassLoader。 +所以,当我们要指明父加载器是BootstrapClassLoader的话,就直接设置为null即可。 + +### 加载类的过程(双亲委派) +![类加载过程](http://qiniu.blog.sslfer.com/7548088943b82ee61f06fbcdd1ad1cf1.png) + +总结:加载类是一层一层往上加载,如果找到了就一层层返回。如果找到顶层都还没有找到,那顶层加载器就开始加载。如果没有加载到,就调用下一层,一层层加载。直到最后一层加载,如果加载到就返回。没有就抛出ClassNotFindExcepton。 + +### ClassLoader 中重要的方法 +1. loadClass (加载class的执行步骤的定义) +2. findLoadedClass (查找加载过的class) +3. findClass (查找class 文件) +4. defineClass (class文件转换为类) + +### 自定义ClassLoader的使用场景 +1. 自定义加载不同地方的类 +2. 类的解密加载器 diff --git "a/source/_posts/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251.md" "b/source/_posts/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251.md" new file mode 100644 index 0000000..ac2630a --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/\347\274\223\345\255\230\345\207\273\347\251\277\344\270\216\347\274\223\345\255\230\351\233\252\345\264\251.md" @@ -0,0 +1,33 @@ +--- +title: 缓存击穿与缓存雪崩 +date: 2019-2-21 10:30:44 +category: 技术 +id: e211afaa-b668-50df-81f9-771a027d2dec +--- +全世界的程序猿都知道,在应对大流量、数据库的频繁查询的时候,由于数据库是承受不住的,所以一般都是在数据库的上方做一个缓存,也就是所谓的缓存层。 +不过,你有没有想过,如果缓存失效了怎么办,全都走数据库查询,那数据库不就gg了吗。 + +什么?缓存会失效,我不信。好吧,那我就说说缓存失效的场景吧。 + +#### 场景一 +数据库里打死都不会出现xxx信息,突然有一天,有一大波流量在查询xxx。由于数据库没有数据,理所当然在上方的缓存里也没有缓存该数据, +缓存里没有,那就必须查询数据库了呀,可是数据库又承受不住这么大的流量。所以该数据库就gg了。—— 缓存击穿 + +#### 场景二 +数据库里也有数据,同时缓存也缓存了该数据。巧了,热点数据同时大面积失效了。也就是同一时间过期了。相当于没有了缓存,和场景一一样, +全部流量都又去到了数据库了。此时数据库正在承受着不该承受的压力。—— 缓存雪崩 + +缓存击穿造成的原因:查询缓存了压根就不会存在的值;而缓存雪崩的原因是:同一时间大面积缓存数据失效。那有没有什么应对方法呢?答案可定是有的。 +具体的方案如下。 + +应对缓存击穿的方案如下: +1. 不是查询了数据库压根就没有的值嘛,只要我们把没有的值也缓存起来,不就可以嘛。比如 数据库返回null,在缓存里也缓存null就可以了。 +1. 布隆过滤器 +1. 流量控制 + +应对缓存雪崩的方案如下: +1. 设置随机过期时间 +1. 增加多级缓存 +1. 流量控制 + +我要说的就写完了,如有补充,请不吝赐教。 \ No newline at end of file diff --git "a/source/_posts/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207.md" "b/source/_posts/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207.md" new file mode 100644 index 0000000..de28808 --- /dev/null +++ "b/source/_posts/\346\212\200\346\234\257/\350\256\276\350\256\241\346\250\241\345\274\217\347\254\254\344\270\200\347\257\207.md" @@ -0,0 +1,50 @@ +--- +title: 设计模式第一篇 +date: 2017-11-23 +category: 技术 +id: acc456c1-0198-594a-b892-fd508bf971cb +--- + +参考网址: [参考地址](http://www.cnblogs.com/maowang1991/archive/2013/04/15/3023236.html) + +### 什么是设计模式 + +它是一种编程的技巧,重在提高代码的可复用性。即使你不知道设计模式,也不妨碍你编码。大不了写的是一次性代码,代码看起来乱一点。如在没有任何编码经验下学习设计模式,我觉得你会走火入魔,变得形式主义,这样大可不必。当然,也不必把它当成神物,设计模式是要在特定的场合下才能发挥它实际的效果。重申一遍,它只是编码技巧。 + +### 设计模式的6原则 + +**1.开闭原则** + +> 对扩展开发,对修改关闭。在程序需要扩展的时候,不能去修改原有的代码。 + +**2.里氏替换原则** + +> 任何基类可以出现的地方,子类一点可以出现。只有当子类替换掉基类,软件功能不受影响时,基类才真正的被复用。子类可以在其基础上扩展新的行为。他是对开闭原则的补充,实现开闭原则的关键步骤就是抽象化。 + +**3.依赖倒转原则** + +> 这是开闭原则的基础。依赖抽象,而不是依赖具体的实现 + +**4.接口隔离原则** + +> 用多个接口来定义多个功能,实现多个接口,比实现一个接口更低耦合。 + +**5.迪米特法则(最少知道原则)** + +> 一个类对自己依赖的类知道的越少越好。也就是说对于被依赖的类来说,无论逻辑有多复杂,都尽量的把逻辑封装在类的内部。高内聚 + +**6.合成复用原则** + +> 尽量使用合成、聚合的方式,而不是使用继承。 + +其实这些原则,也是我们编码的原则。只要在编码过程中注意有没有违法这些原则,如果没有,那你写的代码的方式就是设计模式。 + +### 设计模式的分类 + +总体来说分为三大类 + +- 创建型模式,共五种:工厂方法模式、抽象工厂模式、单例模式、建造者模式、原型模式。 +- 结构型模式,共七种:适配器模式、装饰器模式、代理模式、外观模式、桥接模式、组合模式、享元模式。 +- 行为型模式,共十一种:策略模式、模板方法模式、观察者模式、迭代子模式、责任链模式、命令模式、备忘录模式、状态模式、访问者模式、中介者模式、解释器模式。 + +其实还有两类:并发型模式和线程池模式。 diff --git a/source/categories/index.md b/source/categories/index.md new file mode 100644 index 0000000..e7ca05b --- /dev/null +++ b/source/categories/index.md @@ -0,0 +1,6 @@ +--- +title: 文章分类 +date: 2019-2-20 14:50:59 +type: "categories" +comments: false +--- \ No newline at end of file diff --git a/source/tags/index.md b/source/tags/index.md new file mode 100644 index 0000000..58212f9 --- /dev/null +++ b/source/tags/index.md @@ -0,0 +1,6 @@ +--- +title: 标签 +date: 2019-02-20 14:57:29 +type: "tags" +comments: false +--- diff --git a/tags/git/index.html b/tags/git/index.html deleted file mode 100644 index 3ba1cdb..0000000 --- a/tags/git/index.html +++ /dev/null @@ -1,713 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签: git | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tags/index.html b/tags/index.html deleted file mode 100644 index 79f9c88..0000000 --- a/tags/index.html +++ /dev/null @@ -1,709 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签 | 水上灵风 - - - - - - - - - - - - - - - - - - - - -
-
- - - -
-
-
-
- - -
- - - -
-
- -

标签

- - - -
- - - - -
- - -
-
- 目前共计 5 个标签 -
- -
- -
- - - -
- - - -
- - -
- - - - - -
- - - - - - - - - -
-
- -
- -
- - -
- - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tags/mysql/index.html b/tags/mysql/index.html deleted file mode 100644 index b3184b1..0000000 --- a/tags/mysql/index.html +++ /dev/null @@ -1,713 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签: mysql | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tags/spring/index.html b/tags/spring/index.html deleted file mode 100644 index a1ef5ab..0000000 --- a/tags/spring/index.html +++ /dev/null @@ -1,713 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签: spring | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/tags/\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" "b/tags/\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" deleted file mode 100644 index e7ba2c8..0000000 --- "a/tags/\345\260\217\347\261\263mini\350\267\257\347\224\261\345\231\250/index.html" +++ /dev/null @@ -1,713 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签: 小米mini路由器 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git "a/tags/\346\225\221\347\240\226/index.html" "b/tags/\346\225\221\347\240\226/index.html" deleted file mode 100644 index 3c6d6d0..0000000 --- "a/tags/\346\225\221\347\240\226/index.html" +++ /dev/null @@ -1,713 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 标签: 救砖 | 水上灵风 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/themes/landscape/.gitignore b/themes/landscape/.gitignore new file mode 100644 index 0000000..6e3a08a --- /dev/null +++ b/themes/landscape/.gitignore @@ -0,0 +1,3 @@ +.DS_Store +node_modules +tmp \ No newline at end of file diff --git a/themes/landscape/Gruntfile.js b/themes/landscape/Gruntfile.js new file mode 100644 index 0000000..59fd5df --- /dev/null +++ b/themes/landscape/Gruntfile.js @@ -0,0 +1,46 @@ +module.exports = function(grunt){ + grunt.initConfig({ + gitclone: { + fontawesome: { + options: { + repository: 'https://github.com/FortAwesome/Font-Awesome.git', + directory: 'tmp/fontawesome' + }, + }, + fancybox: { + options: { + repository: 'https://github.com/fancyapps/fancyBox.git', + directory: 'tmp/fancybox' + } + } + }, + copy: { + fontawesome: { + expand: true, + cwd: 'tmp/fontawesome/fonts/', + src: ['**'], + dest: 'source/css/fonts/' + }, + fancybox: { + expand: true, + cwd: 'tmp/fancybox/source/', + src: ['**'], + dest: 'source/fancybox/' + } + }, + _clean: { + tmp: ['tmp'], + fontawesome: ['source/css/fonts'], + fancybox: ['source/fancybox'] + } + }); + + require('load-grunt-tasks')(grunt); + + grunt.renameTask('clean', '_clean'); + + grunt.registerTask('fontawesome', ['gitclone:fontawesome', 'copy:fontawesome', '_clean:tmp']); + grunt.registerTask('fancybox', ['gitclone:fancybox', 'copy:fancybox', '_clean:tmp']); + grunt.registerTask('default', ['gitclone', 'copy', '_clean:tmp']); + grunt.registerTask('clean', ['_clean']); +}; \ No newline at end of file diff --git a/themes/landscape/LICENSE b/themes/landscape/LICENSE new file mode 100644 index 0000000..9ce4d32 --- /dev/null +++ b/themes/landscape/LICENSE @@ -0,0 +1,7 @@ +Copyright (c) 2013 Tommy Chen + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/themes/landscape/README.md b/themes/landscape/README.md new file mode 100644 index 0000000..90ecccd --- /dev/null +++ b/themes/landscape/README.md @@ -0,0 +1,112 @@ +# Landscape + +A brand new default theme for [Hexo]. + +- [Preview](http://hexo.io/hexo-theme-landscape/) + +## Installation + +### Install + +``` bash +$ git clone https://github.com/hexojs/hexo-theme-landscape.git themes/landscape +``` + +**Landscape requires Hexo 2.4 and above.** If you would like to enable the RSS, the [hexo-generate-feed] plugin is also required. + +### Enable + +Modify `theme` setting in `_config.yml` to `landscape`. + +### Update + +``` bash +cd themes/landscape +git pull +``` + +## Configuration + +``` yml +# Header +menu: + Home: / + Archives: /archives +rss: /atom.xml + +# Content +excerpt_link: Read More +fancybox: true + +# Sidebar +sidebar: right +widgets: +- category +- tag +- tagcloud +- archives +- recent_posts + +# Miscellaneous +google_analytics: +favicon: /favicon.png +twitter: +google_plus: +``` + +- **menu** - Navigation menu +- **rss** - RSS link +- **excerpt_link** - "Read More" link at the bottom of excerpted articles. `false` to hide the link. +- **fancybox** - Enable [Fancybox] +- **sidebar** - Sidebar style. You can choose `left`, `right`, `bottom` or `false`. +- **widgets** - Widgets displaying in sidebar +- **google_analytics** - Google Analytics ID +- **favicon** - Favicon path +- **twitter** - Twiiter ID +- **google_plus** - Google+ ID + +## Features + +### Fancybox + +Landscape uses [Fancybox] to showcase your photos. You can use Markdown syntax or fancybox tag plugin to add your photos. + +``` +![img caption](img url) + +{% fancybox img_url [img_thumbnail] [img_caption] %} +``` + +### Sidebar + +You can put your sidebar in left side, right side or bottom of your site by editing `sidebar` setting. + +Landscape provides 5 built-in widgets: + +- category +- tag +- tagcloud +- archives +- recent_posts + +All of them are enabled by default. You can edit them in `widget` setting. + +## Development + +### Requirements + +- [Grunt] 0.4+ +- Hexo 2.4+ + +### Grunt tasks + +- **default** - Download [Fancybox] and [Font Awesome]. +- **fontawesome** - Only download [Font Awesome]. +- **fancybox** - Only download [Fancybox]. +- **clean** - Clean temporarily files and downloaded files. + +[Hexo]: https://hexo.io/ +[Fancybox]: http://fancyapps.com/fancybox/ +[Font Awesome]: http://fontawesome.io/ +[Grunt]: http://gruntjs.com/ +[hexo-generate-feed]: https://github.com/hexojs/hexo-generator-feed diff --git a/themes/landscape/_config.yml b/themes/landscape/_config.yml new file mode 100644 index 0000000..ca22374 --- /dev/null +++ b/themes/landscape/_config.yml @@ -0,0 +1,37 @@ +# Header +menu: + Home: / + Archives: /archives +rss: /atom.xml + +# Content +excerpt_link: Read More +fancybox: true + +# Sidebar +sidebar: right +widgets: +- category +- tag +- tagcloud +- archive +- recent_posts + +# display widgets at the bottom of index pages (pagination == 2) +index_widgets: +# - category +# - tagcloud +# - archive + +# widget behavior +archive_type: 'monthly' +show_count: false + +# Miscellaneous +google_analytics: +gauges_analytics: +favicon: /favicon.png +twitter: +google_plus: +fb_admins: +fb_app_id: diff --git a/themes/landscape/languages/de.yml b/themes/landscape/languages/de.yml new file mode 100644 index 0000000..630055f --- /dev/null +++ b/themes/landscape/languages/de.yml @@ -0,0 +1,19 @@ +categories: Kategorien +search: Suche +tags: Tags +tagcloud: Tag Cloud +tweets: Tweets +prev: zurück +next: weiter +comment: Kommentare +archive_a: Archiv +archive_b: "Archive: %s" +page: Seite %d +recent_posts: letzter Beitrag +newer: Neuer +older: Älter +share: Teilen +powered_by: Powered by +rss_feed: RSS Feed +category: Kategorie +tag: Tag diff --git a/themes/landscape/languages/default.yml b/themes/landscape/languages/default.yml new file mode 100644 index 0000000..3ef7e92 --- /dev/null +++ b/themes/landscape/languages/default.yml @@ -0,0 +1,19 @@ +categories: Categories +search: Search +tags: Tags +tagcloud: Tag Cloud +tweets: Tweets +prev: Prev +next: Next +comment: Comments +archive_a: Archives +archive_b: "Archives: %s" +page: Page %d +recent_posts: Recent Posts +newer: Newer +older: Older +share: Share +powered_by: Powered by +rss_feed: RSS Feed +category: Category +tag: Tag \ No newline at end of file diff --git a/themes/landscape/languages/es.yml b/themes/landscape/languages/es.yml new file mode 100644 index 0000000..d862e87 --- /dev/null +++ b/themes/landscape/languages/es.yml @@ -0,0 +1,19 @@ +categories: Categorías +search: Buscar +tags: Tags +tagcloud: Nube de Tags +tweets: Tweets +prev: Previo +next: Siguiente +comment: Comentarios +archive_a: Archivos +archive_b: "Archivos: %s" +page: Página %d +recent_posts: Posts recientes +newer: Nuevo +older: Viejo +share: Compartir +powered_by: Construido por +rss_feed: RSS +category: Categoría +tag: Tag \ No newline at end of file diff --git a/themes/landscape/languages/fr.yml b/themes/landscape/languages/fr.yml new file mode 100644 index 0000000..c84f51b --- /dev/null +++ b/themes/landscape/languages/fr.yml @@ -0,0 +1,19 @@ +categories: Catégories +search: Rechercher +tags: Mot-clés +tagcloud: Nuage de mot-clés +tweets: Tweets +prev: Précédent +next: Suivant +comment: Commentaires +archive_a: Archives +archive_b: "Archives: %s" +page: Page %d +recent_posts: Articles récents +newer: Récent +older: Ancien +share: Partager +powered_by: Propulsé par +rss_feed: Flux RSS +category: Catégorie +tag: Mot-clé diff --git a/themes/landscape/languages/ja.yml b/themes/landscape/languages/ja.yml new file mode 100644 index 0000000..af0f7fe --- /dev/null +++ b/themes/landscape/languages/ja.yml @@ -0,0 +1,19 @@ +categories: カテゴリ +search: 検索 +tags: タグ +tagcloud: タグクラウド +tweets: ツイート +prev: 戻る +next: 次へ +comment: コメント +archive_a: アーカイブ +archive_b: "アーカイブ: %s" +page: ページ %d +recent_posts: 最近の投稿 +newer: 次の記事 +older: 前の記事 +share: 共有 +powered_by: Powered by +rss_feed: RSSフィード +category: カテゴリ +tag: タグ diff --git a/themes/landscape/languages/ko.yml b/themes/landscape/languages/ko.yml new file mode 100644 index 0000000..1d27b43 --- /dev/null +++ b/themes/landscape/languages/ko.yml @@ -0,0 +1,19 @@ +categories: 카테고리 +search: 검색 +tags: 태그 +tagcloud: 태그 클라우드 +tweets: 트윗 +prev: 이전 +next: 다음 +comment: 댓글 +archive_a: 아카이브 +archive_b: "아카이브: %s" +page: 페이지 %d +recent_posts: 최근 포스트 +newer: 최신 +older: 이전 +share: 공유 +powered_by: Powered by +rss_feed: RSS Feed +category: 카테고리 +tag: 태그 diff --git a/themes/landscape/languages/nl.yml b/themes/landscape/languages/nl.yml new file mode 100644 index 0000000..568d33e --- /dev/null +++ b/themes/landscape/languages/nl.yml @@ -0,0 +1,20 @@ + +categories: Categorieën +search: Zoeken +tags: Labels +tagcloud: Tag Cloud +tweets: Tweets +prev: Vorige +next: Volgende +comment: Commentaren +archive_a: Archieven +archive_b: "Archieven: %s" +page: Pagina %d +recent_posts: Recente berichten +newer: Nieuwer +older: Ouder +share: Delen +powered_by: Powered by +rss_feed: RSS Feed +category: Categorie +tag: Label diff --git a/themes/landscape/languages/no.yml b/themes/landscape/languages/no.yml new file mode 100644 index 0000000..b997691 --- /dev/null +++ b/themes/landscape/languages/no.yml @@ -0,0 +1,19 @@ +categories: Kategorier +search: Søk +tags: Tags +tagcloud: Tag Cloud +tweets: Tweets +prev: Forrige +next: Neste +comment: Kommentarer +archive_a: Arkiv +archive_b: "Arkiv: %s" +page: Side %d +recent_posts: Siste innlegg +newer: Newer +older: Older +share: Share +powered_by: Powered by +rss_feed: RSS Feed +category: Category +tag: Tag \ No newline at end of file diff --git a/themes/landscape/languages/pt.yml b/themes/landscape/languages/pt.yml new file mode 100644 index 0000000..3d74af3 --- /dev/null +++ b/themes/landscape/languages/pt.yml @@ -0,0 +1,19 @@ +categories: Categorias +search: Buscar +tags: Tags +tagcloud: Nuvem de Tags +tweets: Tweets +prev: Anterior +next: Próximo +comment: Comentários +archive_a: Arquivos +archive_b: "Arquivos: %s" +page: Página %d +recent_posts: Postagens Recentes +newer: Mais Recente +older: Mais Antigo +share: Compartilhar +powered_by: Desenvolvido por +rss_feed: Feed RSS +category: Categoria +tag: Tag diff --git a/themes/landscape/languages/ru.yml b/themes/landscape/languages/ru.yml new file mode 100644 index 0000000..625a83c --- /dev/null +++ b/themes/landscape/languages/ru.yml @@ -0,0 +1,19 @@ +categories: Категории +search: Поиск +tags: Метки +tagcloud: Облако меток +tweets: Твиты +prev: Назад +next: Вперед +comment: Комментарии +archive_a: Архив +archive_b: "Архив: %s" +page: Страница %d +recent_posts: Недавние записи +newer: Следующий +older: Предыдущий +share: Поделиться +powered_by: Создано с помощью +rss_feed: RSS-каналы +category: Категория +tag: Метка \ No newline at end of file diff --git a/themes/landscape/languages/zh-CN.yml b/themes/landscape/languages/zh-CN.yml new file mode 100644 index 0000000..51e1321 --- /dev/null +++ b/themes/landscape/languages/zh-CN.yml @@ -0,0 +1,19 @@ +categories: 分类 +search: 搜索 +tags: 标签 +tagcloud: 标签云 +tweets: 推文 +prev: 上一页 +next: 下一页 +comment: 留言 +archive_a: 归档 +archive_b: 归档:%s +page: 第 %d 页 +recent_posts: 最新文章 +newer: Newer +older: Older +share: Share +powered_by: Powered by +rss_feed: RSS Feed +category: Category +tag: Tag \ No newline at end of file diff --git a/themes/landscape/languages/zh-TW.yml b/themes/landscape/languages/zh-TW.yml new file mode 100644 index 0000000..76d2916 --- /dev/null +++ b/themes/landscape/languages/zh-TW.yml @@ -0,0 +1,19 @@ +categories: 分類 +search: 搜尋 +tags: 標籤 +tagcloud: 標籤雲 +tweets: 推文 +prev: 上一頁 +next: 下一頁 +comment: 留言 +archive_a: 彙整 +archive_b: 彙整:%s +page: 第 %d 頁 +recent_posts: 最新文章 +newer: Newer +older: Older +share: Share +powered_by: Powered by +rss_feed: RSS Feed +category: Category +tag: Tag \ No newline at end of file diff --git a/themes/landscape/layout/_partial/after-footer.ejs b/themes/landscape/layout/_partial/after-footer.ejs new file mode 100644 index 0000000..ff2d509 --- /dev/null +++ b/themes/landscape/layout/_partial/after-footer.ejs @@ -0,0 +1,25 @@ +<% if (config.disqus_shortname){ %> + +<% } %> + + + +<% if (theme.fancybox){ %> + <%- css('fancybox/jquery.fancybox') %> + <%- js('fancybox/jquery.fancybox.pack') %> +<% } %> + +<%- js('js/script') %> +<%- partial('gauges-analytics') %> diff --git a/themes/landscape/layout/_partial/archive-post.ejs b/themes/landscape/layout/_partial/archive-post.ejs new file mode 100644 index 0000000..36f2cc3 --- /dev/null +++ b/themes/landscape/layout/_partial/archive-post.ejs @@ -0,0 +1,8 @@ +
+
+
+ <%- partial('post/date', {class_name: 'archive-article-date', date_format: 'MMM D'}) %> + <%- partial('post/title', {class_name: 'archive-article-title'}) %> +
+
+
\ No newline at end of file diff --git a/themes/landscape/layout/_partial/archive.ejs b/themes/landscape/layout/_partial/archive.ejs new file mode 100644 index 0000000..9da934a --- /dev/null +++ b/themes/landscape/layout/_partial/archive.ejs @@ -0,0 +1,34 @@ +<% if (pagination == 2){ %> + <% page.posts.each(function(post){ %> + <%- partial('article', {post: post, index: true}) %> + <% }) %> +<% } else { %> + <% var last; %> + <% page.posts.each(function(post, i){ %> + <% var year = post.date.year(); %> + <% if (last != year){ %> + <% if (last != null){ %> + + <% } %> + <% last = year; %> +
+ +
+ <% } %> + <%- partial('archive-post', {post: post, even: i % 2 == 0}) %> + <% }) %> + <% if (page.posts.length){ %> +
+ <% } %> +<% } %> +<% if (page.total > 1){ %> + +<% } %> diff --git a/themes/landscape/layout/_partial/article.ejs b/themes/landscape/layout/_partial/article.ejs new file mode 100644 index 0000000..0f951a9 --- /dev/null +++ b/themes/landscape/layout/_partial/article.ejs @@ -0,0 +1,44 @@ +
+ +
+ <%- partial('post/gallery') %> + <% if (post.link || post.title){ %> +
+ <%- partial('post/title', {class_name: 'article-title'}) %> +
+ <% } %> +
+ <% if (post.excerpt && index){ %> + <%- post.excerpt %> + <% if (theme.excerpt_link){ %> +

+ <%= theme.excerpt_link %> +

+ <% } %> + <% } else { %> + <%- post.content %> + <% } %> +
+ +
+ <% if (!index){ %> + <%- partial('post/nav') %> + <% } %> +
+ +<% if (!index && post.comments && config.disqus_shortname){ %> +
+
+ +
+
+<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/footer.ejs b/themes/landscape/layout/_partial/footer.ejs new file mode 100644 index 0000000..3aca618 --- /dev/null +++ b/themes/landscape/layout/_partial/footer.ejs @@ -0,0 +1,11 @@ + \ No newline at end of file diff --git a/themes/landscape/layout/_partial/gauges-analytics.ejs b/themes/landscape/layout/_partial/gauges-analytics.ejs new file mode 100644 index 0000000..d64be38 --- /dev/null +++ b/themes/landscape/layout/_partial/gauges-analytics.ejs @@ -0,0 +1,18 @@ +<% if (theme.gauges_analytics){ %> + + + +<% } %> diff --git a/themes/landscape/layout/_partial/google-analytics.ejs b/themes/landscape/layout/_partial/google-analytics.ejs new file mode 100644 index 0000000..84e75f0 --- /dev/null +++ b/themes/landscape/layout/_partial/google-analytics.ejs @@ -0,0 +1,14 @@ +<% if (theme.google_analytics){ %> + + + +<% } %> diff --git a/themes/landscape/layout/_partial/head.ejs b/themes/landscape/layout/_partial/head.ejs new file mode 100644 index 0000000..43d5f93 --- /dev/null +++ b/themes/landscape/layout/_partial/head.ejs @@ -0,0 +1,36 @@ + + + + + <%- partial('google-analytics') %> + <% + var title = page.title; + + if (is_archive()){ + title = __('archive_a'); + + if (is_month()){ + title += ': ' + page.year + '/' + page.month; + } else if (is_year()){ + title += ': ' + page.year; + } + } else if (is_category()){ + title = __('category') + ': ' + page.category; + } else if (is_tag()){ + title = __('tag') + ': ' + page.tag; + } + %> + <% if (title){ %><%= title %> | <% } %><%= config.title %> + + <%- open_graph({twitter_id: theme.twitter, google_plus: theme.google_plus, fb_admins: theme.fb_admins, fb_app_id: theme.fb_app_id}) %> + <% if (theme.rss){ %> + + <% } %> + <% if (theme.favicon){ %> + + <% } %> + <% if (config.highlight.enable){ %> + + <% } %> + <%- css('css/style') %> + diff --git a/themes/landscape/layout/_partial/header.ejs b/themes/landscape/layout/_partial/header.ejs new file mode 100644 index 0000000..e8a305e --- /dev/null +++ b/themes/landscape/layout/_partial/header.ejs @@ -0,0 +1,32 @@ + \ No newline at end of file diff --git a/themes/landscape/layout/_partial/mobile-nav.ejs b/themes/landscape/layout/_partial/mobile-nav.ejs new file mode 100644 index 0000000..7c1d2af --- /dev/null +++ b/themes/landscape/layout/_partial/mobile-nav.ejs @@ -0,0 +1,5 @@ + \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/category.ejs b/themes/landscape/layout/_partial/post/category.ejs new file mode 100644 index 0000000..db2ed48 --- /dev/null +++ b/themes/landscape/layout/_partial/post/category.ejs @@ -0,0 +1,10 @@ +<% if (post.categories && post.categories.length){ %> +
+ <%- list_categories(post.categories, { + show_count: false, + class: 'article-category', + style: 'none', + separator: '►' + }) %> +
+<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/date.ejs b/themes/landscape/layout/_partial/post/date.ejs new file mode 100644 index 0000000..3f49613 --- /dev/null +++ b/themes/landscape/layout/_partial/post/date.ejs @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/gallery.ejs b/themes/landscape/layout/_partial/post/gallery.ejs new file mode 100644 index 0000000..886c8ec --- /dev/null +++ b/themes/landscape/layout/_partial/post/gallery.ejs @@ -0,0 +1,11 @@ +<% if (post.photos && post.photos.length){ %> +
+
+ <% post.photos.forEach(function(photo, i){ %> + + + + <% }) %> +
+
+<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/nav.ejs b/themes/landscape/layout/_partial/post/nav.ejs new file mode 100644 index 0000000..720798a --- /dev/null +++ b/themes/landscape/layout/_partial/post/nav.ejs @@ -0,0 +1,22 @@ +<% if (post.prev || post.next){ %> + +<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/tag.ejs b/themes/landscape/layout/_partial/post/tag.ejs new file mode 100644 index 0000000..e0f327f --- /dev/null +++ b/themes/landscape/layout/_partial/post/tag.ejs @@ -0,0 +1,6 @@ +<% if (post.tags && post.tags.length){ %> + <%- list_tags(post.tags, { + show_count: false, + class: 'article-tag' + }) %> +<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/post/title.ejs b/themes/landscape/layout/_partial/post/title.ejs new file mode 100644 index 0000000..69d646f --- /dev/null +++ b/themes/landscape/layout/_partial/post/title.ejs @@ -0,0 +1,15 @@ +<% if (post.link){ %> +

+ +

+<% } else if (post.title){ %> + <% if (index){ %> +

+ <%= post.title %> +

+ <% } else { %> +

+ <%= post.title %> +

+ <% } %> +<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_partial/sidebar.ejs b/themes/landscape/layout/_partial/sidebar.ejs new file mode 100644 index 0000000..c1e48e5 --- /dev/null +++ b/themes/landscape/layout/_partial/sidebar.ejs @@ -0,0 +1,5 @@ + \ No newline at end of file diff --git a/themes/landscape/layout/_widget/archive.ejs b/themes/landscape/layout/_widget/archive.ejs new file mode 100644 index 0000000..a20c58c --- /dev/null +++ b/themes/landscape/layout/_widget/archive.ejs @@ -0,0 +1,8 @@ +<% if (site.posts.length){ %> +
+

<%= __('archive_a') %>

+
+ <%- list_archives({show_count: theme.show_count, type: theme.archive_type}) %> +
+
+<% } %> diff --git a/themes/landscape/layout/_widget/category.ejs b/themes/landscape/layout/_widget/category.ejs new file mode 100644 index 0000000..8d9e5e9 --- /dev/null +++ b/themes/landscape/layout/_widget/category.ejs @@ -0,0 +1,8 @@ +<% if (site.categories.length){ %> +
+

<%= __('categories') %>

+
+ <%- list_categories({show_count: theme.show_count}) %> +
+
+<% } %> diff --git a/themes/landscape/layout/_widget/recent_posts.ejs b/themes/landscape/layout/_widget/recent_posts.ejs new file mode 100644 index 0000000..7a38547 --- /dev/null +++ b/themes/landscape/layout/_widget/recent_posts.ejs @@ -0,0 +1,14 @@ +<% if (site.posts.length){ %> +
+

<%= __('recent_posts') %>

+
+ +
+
+<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/_widget/tag.ejs b/themes/landscape/layout/_widget/tag.ejs new file mode 100644 index 0000000..ea5fb2c --- /dev/null +++ b/themes/landscape/layout/_widget/tag.ejs @@ -0,0 +1,8 @@ +<% if (site.tags.length){ %> +
+

<%= __('tags') %>

+
+ <%- list_tags({show_count: theme.show_count}) %> +
+
+<% } %> diff --git a/themes/landscape/layout/_widget/tagcloud.ejs b/themes/landscape/layout/_widget/tagcloud.ejs new file mode 100644 index 0000000..5feb435 --- /dev/null +++ b/themes/landscape/layout/_widget/tagcloud.ejs @@ -0,0 +1,8 @@ +<% if (site.tags.length){ %> +
+

<%= __('tagcloud') %>

+
+ <%- tagcloud() %> +
+
+<% } %> \ No newline at end of file diff --git a/themes/landscape/layout/archive.ejs b/themes/landscape/layout/archive.ejs new file mode 100644 index 0000000..52f9b21 --- /dev/null +++ b/themes/landscape/layout/archive.ejs @@ -0,0 +1 @@ +<%- partial('_partial/archive', {pagination: config.archive, index: true}) %> \ No newline at end of file diff --git a/themes/landscape/layout/category.ejs b/themes/landscape/layout/category.ejs new file mode 100644 index 0000000..3ffe252 --- /dev/null +++ b/themes/landscape/layout/category.ejs @@ -0,0 +1 @@ +<%- partial('_partial/archive', {pagination: config.category, index: true}) %> \ No newline at end of file diff --git a/themes/landscape/layout/index.ejs b/themes/landscape/layout/index.ejs new file mode 100644 index 0000000..60a2c68 --- /dev/null +++ b/themes/landscape/layout/index.ejs @@ -0,0 +1 @@ +<%- partial('_partial/archive', {pagination: 2, index: true}) %> \ No newline at end of file diff --git a/themes/landscape/layout/layout.ejs b/themes/landscape/layout/layout.ejs new file mode 100644 index 0000000..cf88daf --- /dev/null +++ b/themes/landscape/layout/layout.ejs @@ -0,0 +1,18 @@ +<%- partial('_partial/head') %> + +
+
+ <%- partial('_partial/header', null, {cache: !config.relative_link}) %> +
+
<%- body %>
+ <% if (theme.sidebar && theme.sidebar !== 'bottom'){ %> + <%- partial('_partial/sidebar', null, {cache: !config.relative_link}) %> + <% } %> +
+ <%- partial('_partial/footer', null, {cache: !config.relative_link}) %> +
+ <%- partial('_partial/mobile-nav', null, {cache: !config.relative_link}) %> + <%- partial('_partial/after-footer') %> +
+ + \ No newline at end of file diff --git a/themes/landscape/layout/page.ejs b/themes/landscape/layout/page.ejs new file mode 100644 index 0000000..bea6318 --- /dev/null +++ b/themes/landscape/layout/page.ejs @@ -0,0 +1 @@ +<%- partial('_partial/article', {post: page, index: false}) %> \ No newline at end of file diff --git a/themes/landscape/layout/post.ejs b/themes/landscape/layout/post.ejs new file mode 100644 index 0000000..bea6318 --- /dev/null +++ b/themes/landscape/layout/post.ejs @@ -0,0 +1 @@ +<%- partial('_partial/article', {post: page, index: false}) %> \ No newline at end of file diff --git a/themes/landscape/layout/tag.ejs b/themes/landscape/layout/tag.ejs new file mode 100644 index 0000000..048cdb0 --- /dev/null +++ b/themes/landscape/layout/tag.ejs @@ -0,0 +1 @@ +<%- partial('_partial/archive', {pagination: config.tag, index: true}) %> \ No newline at end of file diff --git a/themes/landscape/package.json b/themes/landscape/package.json new file mode 100644 index 0000000..ac0df3d --- /dev/null +++ b/themes/landscape/package.json @@ -0,0 +1,12 @@ +{ + "name": "hexo-theme-landscape", + "version": "0.0.2", + "private": true, + "devDependencies": { + "grunt": "~0.4.2", + "load-grunt-tasks": "~0.2.0", + "grunt-git": "~0.2.2", + "grunt-contrib-clean": "~0.5.0", + "grunt-contrib-copy": "~0.4.1" + } +} diff --git a/themes/landscape/scripts/fancybox.js b/themes/landscape/scripts/fancybox.js new file mode 100644 index 0000000..83f1fdc --- /dev/null +++ b/themes/landscape/scripts/fancybox.js @@ -0,0 +1,24 @@ +var rUrl = /((([A-Za-z]{3,9}:(?:\/\/)?)(?:[-;:&=\+\$,\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\+\$,\w]+@)[A-Za-z0-9.-]+)((?:\/[\+~%\/.\w-_]*)?\??(?:[-\+=&;%@.\w_]*)#?(?:[.\!\/\\w]*))?)/; + +/** +* Fancybox tag +* +* Syntax: +* {% fancybox /path/to/image [/path/to/thumbnail] [title] %} +*/ + +hexo.extend.tag.register('fancybox', function(args){ + var original = args.shift(), + thumbnail = ''; + + if (args.length && rUrl.test(args[0])){ + thumbnail = args.shift(); + } + + var title = args.join(' '); + + return '' + + '' + title + '' + '' + + (title ? '' + title + '' : ''); +}); \ No newline at end of file diff --git a/themes/landscape/source/css/_extend.styl b/themes/landscape/source/css/_extend.styl new file mode 100644 index 0000000..96a1817 --- /dev/null +++ b/themes/landscape/source/css/_extend.styl @@ -0,0 +1,63 @@ +$block-caption + text-decoration: none + text-transform: uppercase + letter-spacing: 2px + color: color-grey + margin-bottom: 1em + margin-left: 5px + line-height: 1em + text-shadow: 0 1px #fff + font-weight: bold + +$block + background: #fff + box-shadow: 1px 2px 3px #ddd + border: 1px solid color-border + border-radius: 3px + +$base-style + h1 + font-size: 2em + h2 + font-size: 1.5em + h3 + font-size: 1.3em + h4 + font-size: 1.2em + h5 + font-size: 1em + h6 + font-size: 1em + color: color-grey + hr + border: 1px dashed color-border + strong + font-weight: bold + em, cite + font-style: italic + sup, sub + font-size: 0.75em + line-height: 0 + position: relative + vertical-align: baseline + sup + top: -0.5em + sub + bottom: -0.2em + small + font-size: 0.85em + acronym, abbr + border-bottom: 1px dotted + ul, ol, dl + margin: 0 20px + line-height: line-height + ul, ol + ul, ol + margin-top: 0 + margin-bottom: 0 + ul + list-style: disc + ol + list-style: decimal + dt + font-weight: bold \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/archive.styl b/themes/landscape/source/css/_partial/archive.styl new file mode 100644 index 0000000..90ef053 --- /dev/null +++ b/themes/landscape/source/css/_partial/archive.styl @@ -0,0 +1,80 @@ +.archives-wrap + margin: block-margin 0 + +.archives + clearfix() + +.archive-year-wrap + margin-bottom: 1em + +.archive-year + @extend $block-caption + +.archives + column-gap: 10px + @media mq-tablet + column-count: 2 + @media mq-normal + column-count: 3 + +.archive-article + avoid-column-break() + +.archive-article-inner + @extend $block + padding: 10px + margin-bottom: 15px + +.archive-article-title + text-decoration: none + font-weight: bold + color: color-default + transition: color 0.2s + line-height: line-height + &:hover + color: color-link + +.archive-article-footer + margin-top: 1em + +.archive-article-date + color: color-grey + text-decoration: none + font-size: 0.85em + line-height: 1em + margin-bottom: 0.5em + display: block + +#page-nav + clearfix() + margin: block-margin auto + background: #fff + box-shadow: 1px 2px 3px #ddd + border: 1px solid color-border + border-radius: 3px + text-align: center + color: color-grey + overflow: hidden + a, span + padding: 10px 20px + line-height: 1 + height: 2ex + a + color: color-grey + text-decoration: none + &:hover + background: color-grey + color: #fff + .prev + float: left + .next + float: right + .page-number + display: inline-block + @media mq-mobile + display: none + .current + color: color-default + font-weight: bold + .space + color: color-border \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/article.styl b/themes/landscape/source/css/_partial/article.styl new file mode 100644 index 0000000..46094f9 --- /dev/null +++ b/themes/landscape/source/css/_partial/article.styl @@ -0,0 +1,357 @@ +.article + margin: block-margin 0 + +.article-inner + @extend $block + overflow: hidden + +.article-meta + clearfix() + +.article-date + @extend $block-caption + float: left + +.article-category + float: left + line-height: 1em + color: #ccc + text-shadow: 0 1px #fff + margin-left: 8px + &:before + content: "\2022" + +.article-category-link + @extend $block-caption + margin: 0 12px 1em + +.article-header + padding: article-padding article-padding 0 + +.article-title + text-decoration: none + font-size: 2em + font-weight: bold + color: color-default + line-height: line-height-title + transition: color 0.2s + a&:hover + color: color-link + +.article-entry + @extend $base-style + clearfix() + color: color-default + padding: 0 article-padding + p, table + line-height: line-height + margin: line-height 0 + h1, h2, h3, h4, h5, h6 + font-weight: bold + h1, h2, h3, h4, h5, h6 + line-height: line-height-title + margin: line-height-title 0 + a + color: color-link + text-decoration: none + &:hover + text-decoration: underline + ul, ol, dl + margin-top: line-height + margin-bottom: line-height + img, video + max-width: 100% + height: auto + display: block + margin: auto + iframe + border: none + table + width: 100% + border-collapse: collapse + border-spacing: 0 + th + font-weight: bold + border-bottom: 3px solid color-border + padding-bottom: 0.5em + td + border-bottom: 1px solid color-border + padding: 10px 0 + blockquote + font-family: font-serif + font-size: 1.4em + margin: line-height 20px + text-align: center + footer + font-size: font-size + margin: line-height 0 + font-family: font-sans + cite + &:before + content: "—" + padding: 0 0.5em + .pullquote + text-align: left + width: 45% + margin: 0 + &.left + margin-left: 0.5em + margin-right: 1em + &.right + margin-right: 0.5em + margin-left: 1em + .caption + color: color-grey + display: block + font-size: 0.9em + margin-top: 0.5em + position: relative + text-align: center + // http://webdesignerwall.com/tutorials/css-elastic-videos + .video-container + position: relative + padding-top: (9 / 16 * 100)% // 16:9 ratio + height: 0 + overflow: hidden + iframe, object, embed + position: absolute + top: 0 + left: 0 + width: 100% + height: 100% + margin-top: 0 + +.article-more-link a + display: inline-block + line-height: 1em + padding: 6px 15px + border-radius: 15px + background: color-background + color: color-grey + text-shadow: 0 1px #fff + text-decoration: none + &:hover + background: color-link + color: #fff + text-decoration: none + text-shadow: 0 1px darken(color-link, 20%) + +.article-footer + clearfix() + font-size: 0.85em + line-height: line-height + border-top: 1px solid color-border + padding-top: line-height + margin: 0 article-padding article-padding + a + color: color-grey + text-decoration: none + &:hover + color: color-default + +.article-tag-list-item + float: left + margin-right: 10px + +.article-tag-list-link + &:before + content: "#" + +.article-comment-link + float: right + &:before + content: "\f075" + font-family: font-icon + padding-right: 8px + +.article-share-link + cursor: pointer + float: right + margin-left: 20px + &:before + content: "\f064" + font-family: font-icon + padding-right: 6px + +#article-nav + clearfix() + position: relative + @media mq-normal + margin: block-margin 0 + &:before + absolute-center(8px) + content: "" + border-radius: 50% + background: color-border + box-shadow: 0 1px 2px #fff + +.article-nav-link-wrap + text-decoration: none + text-shadow: 0 1px #fff + color: color-grey + box-sizing: border-box + margin-top: block-margin + text-align: center + display: block + &:hover + color: color-default + @media mq-normal + width: 50% + margin-top: 0 + +#article-nav-newer + @media mq-normal + float: left + text-align: right + padding-right: 20px + +#article-nav-older + @media mq-normal + float: right + text-align: left + padding-left: 20px + +.article-nav-caption + text-transform: uppercase + letter-spacing: 2px + color: color-border + line-height: 1em + font-weight: bold + #article-nav-newer & + margin-right: -2px + +.article-nav-title + font-size: 0.85em + line-height: line-height + margin-top: 0.5em + +.article-share-box + position: absolute + display: none + background: #fff + box-shadow: 1px 2px 10px rgba(0, 0, 0, 0.2) + border-radius: 3px + margin-left: -145px + overflow: hidden + z-index: 1 + &.on + display: block + +.article-share-input + width: 100% + background: none + box-sizing: border-box + font: 14px font-sans + padding: 0 15px + color: color-default + outline: none + border: 1px solid color-border + border-radius: 3px 3px 0 0 + height: 36px + line-height: 36px + +.article-share-links + clearfix() + background: color-background + +$article-share-link + width: 50px + height: 36px + display: block + float: left + position: relative + color: #999 + text-shadow: 0 1px #fff + &:before + font-size: 20px + font-family: font-icon + absolute-center(@font-size) + text-align: center + &:hover + color: #fff + +.article-share-twitter + @extend $article-share-link + &:before + content: "\f099" + &:hover + background: color-twitter + text-shadow: 0 1px darken(color-twitter, 20%) + +.article-share-facebook + @extend $article-share-link + &:before + content: "\f09a" + &:hover + background: color-facebook + text-shadow: 0 1px darken(color-facebook, 20%) + +.article-share-pinterest + @extend $article-share-link + &:before + content: "\f0d2" + &:hover + background: color-pinterest + text-shadow: 0 1px darken(color-pinterest, 20%) + +.article-share-google + @extend $article-share-link + &:before + content: "\f0d5" + &:hover + background: color-google + text-shadow: 0 1px darken(color-google, 20%) + +.article-gallery + background: #000 + position: relative + +.article-gallery-photos + position: relative + overflow: hidden + +.article-gallery-img + display: none + max-width: 100% + &:first-child + display: block + &.loaded + position: absolute + display: block + img + display: block + max-width: 100% + margin: 0 auto +/* +$article-gallery-ctrl + position: absolute + top: 0 + height: 100% + width: 60px + color: #fff + text-shadow: 0 0 3px rgba(0, 0, 0, 0.3) + opacity: 0.3 + transition: opacity 0.2s + cursor: pointer + &:hover + opacity: 0.8 + &:before + font-size: 30px + font-family: font-icon + position: absolute + top: 50% + margin-top: @font-size * -0.5 + +.article-gallery-prev + @extend $article-gallery-ctrl + left: 0 + &:before + content: "\f053" + left: 15px + +.article-gallery-next + @extend $article-gallery-ctrl + right: 0 + &:before + content: "\f054" + right: 15px*/ \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/comment.styl b/themes/landscape/source/css/_partial/comment.styl new file mode 100644 index 0000000..296b7dd --- /dev/null +++ b/themes/landscape/source/css/_partial/comment.styl @@ -0,0 +1,9 @@ +#comments + background: #fff + box-shadow: 1px 2px 3px #ddd + padding: article-padding + border: 1px solid color-border + border-radius: 3px + margin: block-margin 0 + a + color: color-link \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/footer.styl b/themes/landscape/source/css/_partial/footer.styl new file mode 100644 index 0000000..fe2fd24 --- /dev/null +++ b/themes/landscape/source/css/_partial/footer.styl @@ -0,0 +1,14 @@ +#footer + background: color-footer-background + padding: 50px 0 + border-top: 1px solid color-border + color: color-grey + a + color: color-link + text-decoration: none + &:hover + text-decoration: underline + +#footer-info + line-height: line-height + font-size: 0.85em \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/header.styl b/themes/landscape/source/css/_partial/header.styl new file mode 100644 index 0000000..d18ebc8 --- /dev/null +++ b/themes/landscape/source/css/_partial/header.styl @@ -0,0 +1,165 @@ +#header + height: banner-height + position: relative + border-bottom: 1px solid color-border + &:before, &:after + content: "" + position: absolute + left: 0 + right: 0 + height: 40px + &:before + top: 0 + background: linear-gradient(rgba(0, 0, 0, 0.2), transparent) + &:after + bottom: 0 + background: linear-gradient(transparent, rgba(0, 0, 0, 0.2)) + +#header-outer + height: 100% + position: relative + +#header-inner + position: relative + overflow: hidden + +#banner + position: absolute + top: 0 + left: 0 + width: 100% + height: 100% + background: url(banner-url) center #000 + background-size: cover + z-index: -1 + +#header-title + text-align: center + height: logo-size + position: absolute + top: 50% + left: 0 + margin-top: logo-size * -0.5 + +$logo-text + text-decoration: none + color: #fff + font-weight: 300 + text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3) + +#logo + @extend $logo-text + font-size: logo-size + line-height: logo-size + letter-spacing: 2px + +#subtitle + @extend $logo-text + font-size: subtitle-size + line-height: subtitle-size + letter-spacing: 1px + +#subtitle-wrap + margin-top: subtitle-size + +#main-nav + float: left + margin-left: -15px + +$nav-link + float: left + color: #fff + opacity: 0.6 + text-decoration: none + text-shadow: 0 1px rgba(0, 0, 0, 0.2) + transition: opacity 0.2s + display: block + padding: 20px 15px + &:hover + opacity: 1 + +.nav-icon + @extend $nav-link + font-family: font-icon + text-align: center + font-size: font-size + width: font-size + height: font-size + padding: 20px 15px + position: relative + cursor: pointer + +.main-nav-link + @extend $nav-link + font-weight: 300 + letter-spacing: 1px + @media mq-mobile + display: none + +#main-nav-toggle + display: none + &:before + content: "\f0c9" + @media mq-mobile + display: block + +#sub-nav + float: right + margin-right: -15px + +#nav-rss-link + &:before + content: "\f09e" + +#nav-search-btn + &:before + content: "\f002" + +#search-form-wrap + position: absolute + top: 15px + width: 150px + height: 30px + right: -150px + opacity: 0 + transition: 0.2s ease-out + &.on + opacity: 1 + right: 0 + @media mq-mobile + width: 100% + right: -100% + +.search-form + position: absolute + top: 0 + left: 0 + right: 0 + background: #fff + padding: 5px 15px + border-radius: 15px + box-shadow: 0 0 10px rgba(0, 0, 0, 0.3) + +.search-form-input + border: none + background: none + color: color-default + width: 100% + font: 13px font-sans + outline: none + &::-webkit-search-results-decoration + &::-webkit-search-cancel-button + -webkit-appearance: none + +.search-form-submit + position: absolute + top: 50% + right: 10px + margin-top: -7px + font: 13px font-icon + border: none + background: none + color: #bbb + cursor: pointer + &:hover, &:focus + color: #777 \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/highlight.styl b/themes/landscape/source/css/_partial/highlight.styl new file mode 100644 index 0000000..c932ec3 --- /dev/null +++ b/themes/landscape/source/css/_partial/highlight.styl @@ -0,0 +1,158 @@ +// https://github.com/chriskempson/tomorrow-theme +highlight-background = #2d2d2d +highlight-current-line = #393939 +highlight-selection = #515151 +highlight-foreground = #cccccc +highlight-comment = #999999 +highlight-red = #f2777a +highlight-orange = #f99157 +highlight-yellow = #ffcc66 +highlight-green = #99cc99 +highlight-aqua = #66cccc +highlight-blue = #6699cc +highlight-purple = #cc99cc + +$code-block + background: highlight-background + margin: 0 article-padding * -1 + padding: 15px article-padding + border-style: solid + border-color: color-border + border-width: 1px 0 + overflow: auto + color: highlight-foreground + line-height: font-size * line-height + +$line-numbers + color: #666 + font-size: 0.85em + +.article-entry + pre, code + font-family: font-mono + code + background: color-background + text-shadow: 0 1px #fff + padding: 0 0.3em + pre + @extend $code-block + code + background: none + text-shadow: none + padding: 0 + .highlight + @extend $code-block + pre + border: none + margin: 0 + padding: 0 + table + margin: 0 + width: auto + td + border: none + padding: 0 + figcaption + clearfix() + font-size: 0.85em + color: highlight-comment + line-height: 1em + margin-bottom: 1em + a + float: right + .gutter pre + @extend $line-numbers + text-align: right + padding-right: 20px + .line + height: font-size * line-height + .line.marked + background: highlight-selection + .gist + margin: 0 article-padding * -1 + border-style: solid + border-color: color-border + border-width: 1px 0 + background: highlight-background + padding: 15px article-padding 15px 0 + .gist-file + border: none + font-family: font-mono + margin: 0 + .gist-data + background: none + border: none + .line-numbers + @extend $line-numbers + background: none + border: none + padding: 0 20px 0 0 + .line-data + padding: 0 !important + .highlight + margin: 0 + padding: 0 + border: none + .gist-meta + background: highlight-background + color: highlight-comment + font: 0.85em font-sans + text-shadow: 0 0 + padding: 0 + margin-top: 1em + margin-left: article-padding + a + color: color-link + font-weight: normal + &:hover + text-decoration: underline + +pre + .comment + .title + color: highlight-comment + .variable + .attribute + .tag + .regexp + .ruby .constant + .xml .tag .title + .xml .pi + .xml .doctype + .html .doctype + .css .id + .css .class + .css .pseudo + color: highlight-red + .number + .preprocessor + .built_in + .literal + .params + .constant + color: highlight-orange + .class + .ruby .class .title + .css .rules .attribute + color: highlight-green + .string + .value + .inheritance + .header + .ruby .symbol + .xml .cdata + color: highlight-green + .css .hexcolor + color: highlight-aqua + .function + .python .decorator + .python .title + .ruby .function .title + .ruby .title .keyword + .perl .sub + .javascript .title + .coffeescript .title + color: highlight-blue + .keyword + .javascript .function + color: highlight-purple diff --git a/themes/landscape/source/css/_partial/mobile.styl b/themes/landscape/source/css/_partial/mobile.styl new file mode 100644 index 0000000..eb68b3a --- /dev/null +++ b/themes/landscape/source/css/_partial/mobile.styl @@ -0,0 +1,19 @@ +@media mq-mobile + #mobile-nav + position: absolute + top: 0 + left: 0 + width: mobile-nav-width + height: 100% + background: color-mobile-nav-background + border-right: 1px solid #fff + +@media mq-mobile + .mobile-nav-link + display: block + color: color-grey + text-decoration: none + padding: 15px 20px + font-weight: bold + &:hover + color: #fff diff --git a/themes/landscape/source/css/_partial/sidebar-aside.styl b/themes/landscape/source/css/_partial/sidebar-aside.styl new file mode 100644 index 0000000..838b167 --- /dev/null +++ b/themes/landscape/source/css/_partial/sidebar-aside.styl @@ -0,0 +1,27 @@ +#sidebar + @media mq-normal + column(sidebar-column) + +.widget-wrap + margin: block-margin 0 + +.widget-title + @extend $block-caption + +.widget + color: color-sidebar-text + text-shadow: 0 1px #fff + background: color-widget-background + box-shadow: 0 -1px 4px color-widget-border inset + border: 1px solid color-widget-border + padding: 15px + border-radius: 3px + a + color: color-link + text-decoration: none + &:hover + text-decoration: underline + ul, ol, dl + ul, ol, dl + margin-left: 15px + list-style: disc \ No newline at end of file diff --git a/themes/landscape/source/css/_partial/sidebar-bottom.styl b/themes/landscape/source/css/_partial/sidebar-bottom.styl new file mode 100644 index 0000000..e2403fd --- /dev/null +++ b/themes/landscape/source/css/_partial/sidebar-bottom.styl @@ -0,0 +1,27 @@ +.widget-wrap + margin-bottom: block-margin !important + @media mq-normal + column(main-column) + +.widget-title + color: #ccc + text-transform: uppercase + letter-spacing: 2px + margin-bottom: .5em + line-height: 1em + font-weight: bold + +.widget + color: color-grey + ul, ol + li + display: inline-block + zoom:1 + *display:inline + padding-right: .75em +/* Having problems getting balanced white space between items + li:before + content: " | " + li:first-child:before + content: none + */ diff --git a/themes/landscape/source/css/_partial/sidebar.styl b/themes/landscape/source/css/_partial/sidebar.styl new file mode 100644 index 0000000..e43d66a --- /dev/null +++ b/themes/landscape/source/css/_partial/sidebar.styl @@ -0,0 +1,35 @@ +if sidebar is bottom + @import "sidebar-bottom" +else + @import "sidebar-aside" + +.widget + @extend $base-style + line-height: line-height + word-wrap: break-word + font-size: 0.9em + ul, ol + list-style: none + margin: 0 + ul, ol + margin: 0 20px + ul + list-style: disc + ol + list-style: decimal + +.category-list-count +.tag-list-count +.archive-list-count + padding-left: 5px + color: color-grey + font-size: 0.85em + &:before + content: "(" + &:after + content: ")" + +.tagcloud + a + margin-right: 5px + display: inline-block diff --git a/themes/landscape/source/css/_util/grid.styl b/themes/landscape/source/css/_util/grid.styl new file mode 100644 index 0000000..2a14dd2 --- /dev/null +++ b/themes/landscape/source/css/_util/grid.styl @@ -0,0 +1,38 @@ +///////////////// +// Semantic.gs // for Stylus: http://learnboost.github.com/stylus/ +///////////////// + +// Utility function — you should never need to modify this +// _gridsystem-width = (column-width + gutter-width) * columns +gridsystem-width(_columns = columns) + (column-width + gutter-width) * _columns + +// Set @total-width to 100% for a fluid layout +// total-width = gridsystem-width(columns) +total-width = 100% + +////////// +// GRID // +////////// + +body + clearfix() + width: 100% + +row(_columns = columns) + clearfix() + display: block + width: total-width * ((gutter-width + gridsystem-width(_columns)) / gridsystem-width(_columns)) + margin: 0 total-width * (((gutter-width * .5) / gridsystem-width(_columns)) * -1) + +column(x, _columns = columns) + display: inline + float: left + width: total-width * ((((gutter-width + column-width) * x) - gutter-width) / gridsystem-width(_columns)) + margin: 0 total-width * ((gutter-width * .5) / gridsystem-width(_columns)) + +push(offset = 1) + margin-left: total-width * (((gutter-width + column-width) * offset) / gridsystem-width(columns)) + +pull(offset = 1) + margin-right: total-width * (((gutter-width + column-width) * offset) / gridsystem-width(columns)) \ No newline at end of file diff --git a/themes/landscape/source/css/_util/mixin.styl b/themes/landscape/source/css/_util/mixin.styl new file mode 100644 index 0000000..b56f037 --- /dev/null +++ b/themes/landscape/source/css/_util/mixin.styl @@ -0,0 +1,31 @@ +// http://www.zeldman.com/2012/03/01/replacing-the-9999px-hack-new-image-replacement/ +hide-text() + text-indent: 100% + white-space: nowrap + overflow: hidden + +// http://codepen.io/shshaw/full/gEiDt +absolute-center(width, height = width) + // margin: auto + // position: absolute + // top: 50% + // top: 0 + // left: 0 + // bottom: 0 + // right: 0 + // width: width + // height: height + // overflow: auto + width: width + height: height + position: absolute + top: 50% + left: 50% + margin-top: width * -0.5 + margin-left: height * -0.5 + +avoid-column-break() + vendor("column-break-inside", avoid, only: webkit) + page-break-inside: avoid // for firefox + overflow: hidden // fix for firefox + break-inside: avoid-column diff --git a/themes/landscape/source/css/_variables.styl b/themes/landscape/source/css/_variables.styl new file mode 100644 index 0000000..4562911 --- /dev/null +++ b/themes/landscape/source/css/_variables.styl @@ -0,0 +1,63 @@ +// Config +support-for-ie = false +vendor-prefixes = webkit moz ms official + +// Colors +color-default = #555 +color-grey = #999 +color-border = #ddd +color-link = #258fb8 +color-background = #eee +color-sidebar-text = #777 +color-widget-background = #ddd +color-widget-border = #ccc +color-footer-background = #262a30 +color-mobile-nav-background = #191919 +color-twitter = #00aced +color-facebook = #3b5998 +color-pinterest = #cb2027 +color-google = #dd4b39 + +// Fonts +font-sans = -apple-system, BlinkMacSystemFont, + "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", + "Fira Sans", "Droid Sans", "Helvetica Neue", + sans-serif +font-serif = Georgia, "Times New Roman", serif +font-mono = "Source Code Pro", Consolas, Monaco, Menlo, Consolas, monospace +font-icon = FontAwesome +font-icon-path = "fonts/fontawesome-webfont" +font-icon-version = "4.0.3" +font-size = 14px +line-height = 1.6em +line-height-title = 1.1em + +// Header +logo-size = 40px +subtitle-size = 16px +banner-height = 300px +banner-url = "images/banner.jpg" + +sidebar = hexo-config("sidebar") + +// Layout +block-margin = 50px +article-padding = 20px +mobile-nav-width = 280px +main-column = 9 +sidebar-column = 3 + +if sidebar and sidebar isnt bottom + _sidebar-column = sidebar-column +else + _sidebar-column = 0 + +// Grids +column-width = 80px +gutter-width = 20px +columns = main-column + _sidebar-column + +// Media queries +mq-mobile = "screen and (max-width: 479px)" +mq-tablet = "screen and (min-width: 480px) and (max-width: 767px)" +mq-normal = "screen and (min-width: 768px)" \ No newline at end of file diff --git a/themes/landscape/source/css/fonts/FontAwesome.otf b/themes/landscape/source/css/fonts/FontAwesome.otf new file mode 100644 index 0000000..8b0f54e Binary files /dev/null and b/themes/landscape/source/css/fonts/FontAwesome.otf differ diff --git a/themes/landscape/source/css/fonts/fontawesome-webfont.eot b/themes/landscape/source/css/fonts/fontawesome-webfont.eot new file mode 100644 index 0000000..7c79c6a Binary files /dev/null and b/themes/landscape/source/css/fonts/fontawesome-webfont.eot differ diff --git a/themes/landscape/source/css/fonts/fontawesome-webfont.svg b/themes/landscape/source/css/fonts/fontawesome-webfont.svg new file mode 100644 index 0000000..45fdf33 --- /dev/null +++ b/themes/landscape/source/css/fonts/fontawesome-webfont.svg @@ -0,0 +1,414 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/themes/landscape/source/css/fonts/fontawesome-webfont.ttf b/themes/landscape/source/css/fonts/fontawesome-webfont.ttf new file mode 100644 index 0000000..e89738d Binary files /dev/null and b/themes/landscape/source/css/fonts/fontawesome-webfont.ttf differ diff --git a/themes/landscape/source/css/fonts/fontawesome-webfont.woff b/themes/landscape/source/css/fonts/fontawesome-webfont.woff new file mode 100644 index 0000000..8c1748a Binary files /dev/null and b/themes/landscape/source/css/fonts/fontawesome-webfont.woff differ diff --git a/themes/landscape/source/css/images/banner.jpg b/themes/landscape/source/css/images/banner.jpg new file mode 100644 index 0000000..b963e06 Binary files /dev/null and b/themes/landscape/source/css/images/banner.jpg differ diff --git a/themes/landscape/source/css/style.styl b/themes/landscape/source/css/style.styl new file mode 100644 index 0000000..c51f8e4 --- /dev/null +++ b/themes/landscape/source/css/style.styl @@ -0,0 +1,89 @@ +@import "nib" +@import "_variables" +@import "_util/mixin" +@import "_util/grid" + +global-reset() + +input, button + margin: 0 + padding: 0 + &::-moz-focus-inner + border: 0 + padding: 0 + +@font-face + font-family: FontAwesome + font-style: normal + font-weight: normal + src: url(font-icon-path + ".eot?v=#" + font-icon-version) + src: url(font-icon-path + ".eot?#iefix&v=#" + font-icon-version) format("embedded-opentype"), + url(font-icon-path + ".woff?v=#" + font-icon-version) format("woff"), + url(font-icon-path + ".ttf?v=#" + font-icon-version) format("truetype"), + url(font-icon-path + ".svg#fontawesomeregular?v=#" + font-icon-version) format("svg") + +html, body, #container + height: 100% + +body + background: color-background + font: font-size font-sans + -webkit-text-size-adjust: 100% + +.outer + clearfix() + max-width: (column-width + gutter-width) * columns + gutter-width + margin: 0 auto + padding: 0 gutter-width + +.inner + column(columns) + +.left, .alignleft + float: left + +.right, .alignright + float: right + +.clear + clear: both + +#container + position: relative + +.mobile-nav-on + overflow: hidden + +#wrap + height: 100% + width: 100% + position: absolute + top: 0 + left: 0 + transition: 0.2s ease-out + z-index: 1 + background: color-background + .mobile-nav-on & + left: mobile-nav-width + +if sidebar and sidebar isnt bottom + #main + @media mq-normal + column(main-column) + +if sidebar is left + @media mq-normal + #main + float: right + +@import "_extend" +@import "_partial/header" +@import "_partial/article" +@import "_partial/comment" +@import "_partial/archive" +@import "_partial/footer" +@import "_partial/highlight" +@import "_partial/mobile" + +if sidebar + @import "_partial/sidebar" \ No newline at end of file diff --git a/lib/fancybox/source/blank.gif b/themes/landscape/source/fancybox/blank.gif similarity index 100% rename from lib/fancybox/source/blank.gif rename to themes/landscape/source/fancybox/blank.gif diff --git a/lib/fancybox/source/fancybox_loading.gif b/themes/landscape/source/fancybox/fancybox_loading.gif similarity index 100% rename from lib/fancybox/source/fancybox_loading.gif rename to themes/landscape/source/fancybox/fancybox_loading.gif diff --git a/lib/fancybox/source/fancybox_loading@2x.gif b/themes/landscape/source/fancybox/fancybox_loading@2x.gif similarity index 100% rename from lib/fancybox/source/fancybox_loading@2x.gif rename to themes/landscape/source/fancybox/fancybox_loading@2x.gif diff --git a/lib/fancybox/source/fancybox_overlay.png b/themes/landscape/source/fancybox/fancybox_overlay.png similarity index 100% rename from lib/fancybox/source/fancybox_overlay.png rename to themes/landscape/source/fancybox/fancybox_overlay.png diff --git a/lib/fancybox/source/fancybox_sprite.png b/themes/landscape/source/fancybox/fancybox_sprite.png similarity index 100% rename from lib/fancybox/source/fancybox_sprite.png rename to themes/landscape/source/fancybox/fancybox_sprite.png diff --git a/lib/fancybox/source/fancybox_sprite@2x.png b/themes/landscape/source/fancybox/fancybox_sprite@2x.png similarity index 100% rename from lib/fancybox/source/fancybox_sprite@2x.png rename to themes/landscape/source/fancybox/fancybox_sprite@2x.png diff --git a/lib/fancybox/source/helpers/fancybox_buttons.png b/themes/landscape/source/fancybox/helpers/fancybox_buttons.png similarity index 100% rename from lib/fancybox/source/helpers/fancybox_buttons.png rename to themes/landscape/source/fancybox/helpers/fancybox_buttons.png diff --git a/lib/fancybox/source/helpers/jquery.fancybox-buttons.css b/themes/landscape/source/fancybox/helpers/jquery.fancybox-buttons.css similarity index 100% rename from lib/fancybox/source/helpers/jquery.fancybox-buttons.css rename to themes/landscape/source/fancybox/helpers/jquery.fancybox-buttons.css diff --git a/themes/landscape/source/fancybox/helpers/jquery.fancybox-buttons.js b/themes/landscape/source/fancybox/helpers/jquery.fancybox-buttons.js new file mode 100644 index 0000000..352bb5f --- /dev/null +++ b/themes/landscape/source/fancybox/helpers/jquery.fancybox-buttons.js @@ -0,0 +1,122 @@ + /*! + * Buttons helper for fancyBox + * version: 1.0.5 (Mon, 15 Oct 2012) + * @requires fancyBox v2.0 or later + * + * Usage: + * $(".fancybox").fancybox({ + * helpers : { + * buttons: { + * position : 'top' + * } + * } + * }); + * + */ +;(function ($) { + //Shortcut for fancyBox object + var F = $.fancybox; + + //Add helper object + F.helpers.buttons = { + defaults : { + skipSingle : false, // disables if gallery contains single image + position : 'top', // 'top' or 'bottom' + tpl : '
' + }, + + list : null, + buttons: null, + + beforeLoad: function (opts, obj) { + //Remove self if gallery do not have at least two items + + if (opts.skipSingle && obj.group.length < 2) { + obj.helpers.buttons = false; + obj.closeBtn = true; + + return; + } + + //Increase top margin to give space for buttons + obj.margin[ opts.position === 'bottom' ? 2 : 0 ] += 30; + }, + + onPlayStart: function () { + if (this.buttons) { + this.buttons.play.attr('title', 'Pause slideshow').addClass('btnPlayOn'); + } + }, + + onPlayEnd: function () { + if (this.buttons) { + this.buttons.play.attr('title', 'Start slideshow').removeClass('btnPlayOn'); + } + }, + + afterShow: function (opts, obj) { + var buttons = this.buttons; + + if (!buttons) { + this.list = $(opts.tpl).addClass(opts.position).appendTo('body'); + + buttons = { + prev : this.list.find('.btnPrev').click( F.prev ), + next : this.list.find('.btnNext').click( F.next ), + play : this.list.find('.btnPlay').click( F.play ), + toggle : this.list.find('.btnToggle').click( F.toggle ), + close : this.list.find('.btnClose').click( F.close ) + } + } + + //Prev + if (obj.index > 0 || obj.loop) { + buttons.prev.removeClass('btnDisabled'); + } else { + buttons.prev.addClass('btnDisabled'); + } + + //Next / Play + if (obj.loop || obj.index < obj.group.length - 1) { + buttons.next.removeClass('btnDisabled'); + buttons.play.removeClass('btnDisabled'); + + } else { + buttons.next.addClass('btnDisabled'); + buttons.play.addClass('btnDisabled'); + } + + this.buttons = buttons; + + this.onUpdate(opts, obj); + }, + + onUpdate: function (opts, obj) { + var toggle; + + if (!this.buttons) { + return; + } + + toggle = this.buttons.toggle.removeClass('btnDisabled btnToggleOn'); + + //Size toggle button + if (obj.canShrink) { + toggle.addClass('btnToggleOn'); + + } else if (!obj.canExpand) { + toggle.addClass('btnDisabled'); + } + }, + + beforeClose: function () { + if (this.list) { + this.list.remove(); + } + + this.list = null; + this.buttons = null; + } + }; + +}(jQuery)); diff --git a/themes/landscape/source/fancybox/helpers/jquery.fancybox-media.js b/themes/landscape/source/fancybox/helpers/jquery.fancybox-media.js new file mode 100644 index 0000000..62737a5 --- /dev/null +++ b/themes/landscape/source/fancybox/helpers/jquery.fancybox-media.js @@ -0,0 +1,199 @@ +/*! + * Media helper for fancyBox + * version: 1.0.6 (Fri, 14 Jun 2013) + * @requires fancyBox v2.0 or later + * + * Usage: + * $(".fancybox").fancybox({ + * helpers : { + * media: true + * } + * }); + * + * Set custom URL parameters: + * $(".fancybox").fancybox({ + * helpers : { + * media: { + * youtube : { + * params : { + * autoplay : 0 + * } + * } + * } + * } + * }); + * + * Or: + * $(".fancybox").fancybox({, + * helpers : { + * media: true + * }, + * youtube : { + * autoplay: 0 + * } + * }); + * + * Supports: + * + * Youtube + * http://www.youtube.com/watch?v=opj24KnzrWo + * http://www.youtube.com/embed/opj24KnzrWo + * http://youtu.be/opj24KnzrWo + * http://www.youtube-nocookie.com/embed/opj24KnzrWo + * Vimeo + * http://vimeo.com/40648169 + * http://vimeo.com/channels/staffpicks/38843628 + * http://vimeo.com/groups/surrealism/videos/36516384 + * http://player.vimeo.com/video/45074303 + * Metacafe + * http://www.metacafe.com/watch/7635964/dr_seuss_the_lorax_movie_trailer/ + * http://www.metacafe.com/watch/7635964/ + * Dailymotion + * http://www.dailymotion.com/video/xoytqh_dr-seuss-the-lorax-premiere_people + * Twitvid + * http://twitvid.com/QY7MD + * Twitpic + * http://twitpic.com/7p93st + * Instagram + * http://instagr.am/p/IejkuUGxQn/ + * http://instagram.com/p/IejkuUGxQn/ + * Google maps + * http://maps.google.com/maps?q=Eiffel+Tower,+Avenue+Gustave+Eiffel,+Paris,+France&t=h&z=17 + * http://maps.google.com/?ll=48.857995,2.294297&spn=0.007666,0.021136&t=m&z=16 + * http://maps.google.com/?ll=48.859463,2.292626&spn=0.000965,0.002642&t=m&z=19&layer=c&cbll=48.859524,2.292532&panoid=YJ0lq28OOy3VT2IqIuVY0g&cbp=12,151.58,,0,-15.56 + */ +;(function ($) { + "use strict"; + + //Shortcut for fancyBox object + var F = $.fancybox, + format = function( url, rez, params ) { + params = params || ''; + + if ( $.type( params ) === "object" ) { + params = $.param(params, true); + } + + $.each(rez, function(key, value) { + url = url.replace( '$' + key, value || '' ); + }); + + if (params.length) { + url += ( url.indexOf('?') > 0 ? '&' : '?' ) + params; + } + + return url; + }; + + //Add helper object + F.helpers.media = { + defaults : { + youtube : { + matcher : /(youtube\.com|youtu\.be|youtube-nocookie\.com)\/(watch\?v=|v\/|u\/|embed\/?)?(videoseries\?list=(.*)|[\w-]{11}|\?listType=(.*)&list=(.*)).*/i, + params : { + autoplay : 1, + autohide : 1, + fs : 1, + rel : 0, + hd : 1, + wmode : 'opaque', + enablejsapi : 1 + }, + type : 'iframe', + url : '//www.youtube.com/embed/$3' + }, + vimeo : { + matcher : /(?:vimeo(?:pro)?.com)\/(?:[^\d]+)?(\d+)(?:.*)/, + params : { + autoplay : 1, + hd : 1, + show_title : 1, + show_byline : 1, + show_portrait : 0, + fullscreen : 1 + }, + type : 'iframe', + url : '//player.vimeo.com/video/$1' + }, + metacafe : { + matcher : /metacafe.com\/(?:watch|fplayer)\/([\w\-]{1,10})/, + params : { + autoPlay : 'yes' + }, + type : 'swf', + url : function( rez, params, obj ) { + obj.swf.flashVars = 'playerVars=' + $.param( params, true ); + + return '//www.metacafe.com/fplayer/' + rez[1] + '/.swf'; + } + }, + dailymotion : { + matcher : /dailymotion.com\/video\/(.*)\/?(.*)/, + params : { + additionalInfos : 0, + autoStart : 1 + }, + type : 'swf', + url : '//www.dailymotion.com/swf/video/$1' + }, + twitvid : { + matcher : /twitvid\.com\/([a-zA-Z0-9_\-\?\=]+)/i, + params : { + autoplay : 0 + }, + type : 'iframe', + url : '//www.twitvid.com/embed.php?guid=$1' + }, + twitpic : { + matcher : /twitpic\.com\/(?!(?:place|photos|events)\/)([a-zA-Z0-9\?\=\-]+)/i, + type : 'image', + url : '//twitpic.com/show/full/$1/' + }, + instagram : { + matcher : /(instagr\.am|instagram\.com)\/p\/([a-zA-Z0-9_\-]+)\/?/i, + type : 'image', + url : '//$1/p/$2/media/?size=l' + }, + google_maps : { + matcher : /maps\.google\.([a-z]{2,3}(\.[a-z]{2})?)\/(\?ll=|maps\?)(.*)/i, + type : 'iframe', + url : function( rez ) { + return '//maps.google.' + rez[1] + '/' + rez[3] + '' + rez[4] + '&output=' + (rez[4].indexOf('layer=c') > 0 ? 'svembed' : 'embed'); + } + } + }, + + beforeLoad : function(opts, obj) { + var url = obj.href || '', + type = false, + what, + item, + rez, + params; + + for (what in opts) { + if (opts.hasOwnProperty(what)) { + item = opts[ what ]; + rez = url.match( item.matcher ); + + if (rez) { + type = item.type; + params = $.extend(true, {}, item.params, obj[ what ] || ($.isPlainObject(opts[ what ]) ? opts[ what ].params : null)); + + url = $.type( item.url ) === "function" ? item.url.call( this, rez, params, obj ) : format( item.url, rez, params ); + + break; + } + } + } + + if (type) { + obj.href = url; + obj.type = type; + + obj.autoHeight = false; + } + } + }; + +}(jQuery)); \ No newline at end of file diff --git a/lib/fancybox/source/helpers/jquery.fancybox-thumbs.css b/themes/landscape/source/fancybox/helpers/jquery.fancybox-thumbs.css similarity index 100% rename from lib/fancybox/source/helpers/jquery.fancybox-thumbs.css rename to themes/landscape/source/fancybox/helpers/jquery.fancybox-thumbs.css diff --git a/themes/landscape/source/fancybox/helpers/jquery.fancybox-thumbs.js b/themes/landscape/source/fancybox/helpers/jquery.fancybox-thumbs.js new file mode 100644 index 0000000..58c9719 --- /dev/null +++ b/themes/landscape/source/fancybox/helpers/jquery.fancybox-thumbs.js @@ -0,0 +1,165 @@ + /*! + * Thumbnail helper for fancyBox + * version: 1.0.7 (Mon, 01 Oct 2012) + * @requires fancyBox v2.0 or later + * + * Usage: + * $(".fancybox").fancybox({ + * helpers : { + * thumbs: { + * width : 50, + * height : 50 + * } + * } + * }); + * + */ +;(function ($) { + //Shortcut for fancyBox object + var F = $.fancybox; + + //Add helper object + F.helpers.thumbs = { + defaults : { + width : 50, // thumbnail width + height : 50, // thumbnail height + position : 'bottom', // 'top' or 'bottom' + source : function ( item ) { // function to obtain the URL of the thumbnail image + var href; + + if (item.element) { + href = $(item.element).find('img').attr('src'); + } + + if (!href && item.type === 'image' && item.href) { + href = item.href; + } + + return href; + } + }, + + wrap : null, + list : null, + width : 0, + + init: function (opts, obj) { + var that = this, + list, + thumbWidth = opts.width, + thumbHeight = opts.height, + thumbSource = opts.source; + + //Build list structure + list = ''; + + for (var n = 0; n < obj.group.length; n++) { + list += '
  • '; + } + + this.wrap = $('
    ').addClass(opts.position).appendTo('body'); + this.list = $('').appendTo(this.wrap); + + //Load each thumbnail + $.each(obj.group, function (i) { + var el = obj.group[ i ], + href = thumbSource( el ); + + if (!href) { + return; + } + + $("").load(function () { + var width = this.width, + height = this.height, + widthRatio, heightRatio, parent; + + if (!that.list || !width || !height) { + return; + } + + //Calculate thumbnail width/height and center it + widthRatio = width / thumbWidth; + heightRatio = height / thumbHeight; + + parent = that.list.children().eq(i).find('a'); + + if (widthRatio >= 1 && heightRatio >= 1) { + if (widthRatio > heightRatio) { + width = Math.floor(width / heightRatio); + height = thumbHeight; + + } else { + width = thumbWidth; + height = Math.floor(height / widthRatio); + } + } + + $(this).css({ + width : width, + height : height, + top : Math.floor(thumbHeight / 2 - height / 2), + left : Math.floor(thumbWidth / 2 - width / 2) + }); + + parent.width(thumbWidth).height(thumbHeight); + + $(this).hide().appendTo(parent).fadeIn(300); + + }) + .attr('src', href) + .attr('title', el.title); + }); + + //Set initial width + this.width = this.list.children().eq(0).outerWidth(true); + + this.list.width(this.width * (obj.group.length + 1)).css('left', Math.floor($(window).width() * 0.5 - (obj.index * this.width + this.width * 0.5))); + }, + + beforeLoad: function (opts, obj) { + //Remove self if gallery do not have at least two items + if (obj.group.length < 2) { + obj.helpers.thumbs = false; + + return; + } + + //Increase bottom margin to give space for thumbs + obj.margin[ opts.position === 'top' ? 0 : 2 ] += ((opts.height) + 15); + }, + + afterShow: function (opts, obj) { + //Check if exists and create or update list + if (this.list) { + this.onUpdate(opts, obj); + + } else { + this.init(opts, obj); + } + + //Set active element + this.list.children().removeClass('active').eq(obj.index).addClass('active'); + }, + + //Center list + onUpdate: function (opts, obj) { + if (this.list) { + this.list.stop(true).animate({ + 'left': Math.floor($(window).width() * 0.5 - (obj.index * this.width + this.width * 0.5)) + }, 150); + } + }, + + beforeClose: function () { + if (this.wrap) { + this.wrap.remove(); + } + + this.wrap = null; + this.list = null; + this.width = 0; + } + } + +}(jQuery)); \ No newline at end of file diff --git a/themes/landscape/source/fancybox/jquery.fancybox.css b/themes/landscape/source/fancybox/jquery.fancybox.css new file mode 100644 index 0000000..c75d051 --- /dev/null +++ b/themes/landscape/source/fancybox/jquery.fancybox.css @@ -0,0 +1,273 @@ +/*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */ +.fancybox-wrap, +.fancybox-skin, +.fancybox-outer, +.fancybox-inner, +.fancybox-image, +.fancybox-wrap iframe, +.fancybox-wrap object, +.fancybox-nav, +.fancybox-nav span, +.fancybox-tmp +{ + padding: 0; + margin: 0; + border: 0; + outline: none; + vertical-align: top; +} + +.fancybox-wrap { + position: absolute; + top: 0; + left: 0; + z-index: 8020; +} + +.fancybox-skin { + position: relative; + background: #f9f9f9; + color: #444; + text-shadow: none; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.fancybox-opened { + z-index: 8030; +} + +.fancybox-opened .fancybox-skin { + -webkit-box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); + -moz-box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); + box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); +} + +.fancybox-outer, .fancybox-inner { + position: relative; +} + +.fancybox-inner { + overflow: hidden; +} + +.fancybox-type-iframe .fancybox-inner { + -webkit-overflow-scrolling: touch; +} + +.fancybox-error { + color: #444; + font: 14px/20px "Helvetica Neue",Helvetica,Arial,sans-serif; + margin: 0; + padding: 15px; + white-space: nowrap; +} + +.fancybox-image, .fancybox-iframe { + display: block; + width: 100%; + height: 100%; +} + +.fancybox-image { + max-width: 100%; + max-height: 100%; +} + +#fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span { + background-image: url(fancybox_sprite.png); +} + +#fancybox-loading { + position: fixed; + top: 50%; + left: 50%; + margin-top: -22px; + margin-left: -22px; + background-position: 0 -108px; + opacity: 0.8; + cursor: pointer; + z-index: 8060; +} + +#fancybox-loading div { + width: 44px; + height: 44px; + background: url(fancybox_loading.gif) center center no-repeat; +} + +.fancybox-close { + position: absolute; + top: -18px; + right: -18px; + width: 36px; + height: 36px; + cursor: pointer; + z-index: 8040; +} + +.fancybox-nav { + position: absolute; + top: 0; + width: 40%; + height: 100%; + cursor: pointer; + text-decoration: none; + background: transparent url(blank.gif); /* helps IE */ + -webkit-tap-highlight-color: rgba(0,0,0,0); + z-index: 8040; +} + +.fancybox-prev { + left: 0; +} + +.fancybox-next { + right: 0; +} + +.fancybox-nav span { + position: absolute; + top: 50%; + width: 36px; + height: 34px; + margin-top: -18px; + cursor: pointer; + z-index: 8040; + visibility: hidden; +} + +.fancybox-prev span { + left: 10px; + background-position: 0 -36px; +} + +.fancybox-next span { + right: 10px; + background-position: 0 -72px; +} + +.fancybox-nav:hover span { + visibility: visible; +} + +.fancybox-tmp { + position: absolute; + top: -99999px; + left: -99999px; + max-width: 99999px; + max-height: 99999px; + overflow: visible !important; +} + +/* Overlay helper */ + +.fancybox-lock { + overflow: visible !important; + width: auto; +} + +.fancybox-lock body { + overflow: hidden !important; +} + +.fancybox-lock-test { + overflow-y: hidden !important; +} + +.fancybox-overlay { + position: absolute; + top: 0; + left: 0; + overflow: hidden; + display: none; + z-index: 8010; + background: url(fancybox_overlay.png); +} + +.fancybox-overlay-fixed { + position: fixed; + bottom: 0; + right: 0; +} + +.fancybox-lock .fancybox-overlay { + overflow: auto; + overflow-y: scroll; +} + +/* Title helper */ + +.fancybox-title { + visibility: hidden; + font: normal 13px/20px "Helvetica Neue",Helvetica,Arial,sans-serif; + position: relative; + text-shadow: none; + z-index: 8050; +} + +.fancybox-opened .fancybox-title { + visibility: visible; +} + +.fancybox-title-float-wrap { + position: absolute; + bottom: 0; + right: 50%; + margin-bottom: -35px; + z-index: 8050; + text-align: center; +} + +.fancybox-title-float-wrap .child { + display: inline-block; + margin-right: -100%; + padding: 2px 20px; + background: transparent; /* Fallback for web browsers that doesn't support RGBa */ + background: rgba(0, 0, 0, 0.8); + -webkit-border-radius: 15px; + -moz-border-radius: 15px; + border-radius: 15px; + text-shadow: 0 1px 2px #222; + color: #FFF; + font-weight: bold; + line-height: 24px; + white-space: nowrap; +} + +.fancybox-title-outside-wrap { + position: relative; + margin-top: 10px; + color: #fff; +} + +.fancybox-title-inside-wrap { + padding-top: 10px; +} + +.fancybox-title-over-wrap { + position: absolute; + bottom: 0; + left: 0; + color: #fff; + padding: 10px; + background: #000; + background: rgba(0, 0, 0, .8); +} + +/*Retina graphics!*/ +@media only screen and (-webkit-min-device-pixel-ratio: 1.5), + only screen and (min--moz-device-pixel-ratio: 1.5), + only screen and (min-device-pixel-ratio: 1.5){ + + #fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span { + background-image: url(fancybox_sprite@2x.png); + background-size: 44px 152px; /*The size of the normal image, half the size of the hi-res image*/ + } + + #fancybox-loading div { + background-image: url(fancybox_loading@2x.gif); + background-size: 24px 24px; /*The size of the normal image, half the size of the hi-res image*/ + } +} \ No newline at end of file diff --git a/themes/landscape/source/fancybox/jquery.fancybox.js b/themes/landscape/source/fancybox/jquery.fancybox.js new file mode 100644 index 0000000..7a0f8ac --- /dev/null +++ b/themes/landscape/source/fancybox/jquery.fancybox.js @@ -0,0 +1,2017 @@ +/*! + * fancyBox - jQuery Plugin + * version: 2.1.5 (Fri, 14 Jun 2013) + * requires jQuery v1.6 or later + * + * Examples at http://fancyapps.com/fancybox/ + * License: www.fancyapps.com/fancybox/#license + * + * Copyright 2012 Janis Skarnelis - janis@fancyapps.com + * + */ + +;(function (window, document, $, undefined) { + "use strict"; + + var H = $("html"), + W = $(window), + D = $(document), + F = $.fancybox = function () { + F.open.apply( this, arguments ); + }, + IE = navigator.userAgent.match(/msie/i), + didUpdate = null, + isTouch = document.createTouch !== undefined, + + isQuery = function(obj) { + return obj && obj.hasOwnProperty && obj instanceof $; + }, + isString = function(str) { + return str && $.type(str) === "string"; + }, + isPercentage = function(str) { + return isString(str) && str.indexOf('%') > 0; + }, + isScrollable = function(el) { + return (el && !(el.style.overflow && el.style.overflow === 'hidden') && ((el.clientWidth && el.scrollWidth > el.clientWidth) || (el.clientHeight && el.scrollHeight > el.clientHeight))); + }, + getScalar = function(orig, dim) { + var value = parseInt(orig, 10) || 0; + + if (dim && isPercentage(orig)) { + value = F.getViewport()[ dim ] / 100 * value; + } + + return Math.ceil(value); + }, + getValue = function(value, dim) { + return getScalar(value, dim) + 'px'; + }; + + $.extend(F, { + // The current version of fancyBox + version: '2.1.5', + + defaults: { + padding : 15, + margin : 20, + + width : 800, + height : 600, + minWidth : 100, + minHeight : 100, + maxWidth : 9999, + maxHeight : 9999, + pixelRatio: 1, // Set to 2 for retina display support + + autoSize : true, + autoHeight : false, + autoWidth : false, + + autoResize : true, + autoCenter : !isTouch, + fitToView : true, + aspectRatio : false, + topRatio : 0.5, + leftRatio : 0.5, + + scrolling : 'auto', // 'auto', 'yes' or 'no' + wrapCSS : '', + + arrows : true, + closeBtn : true, + closeClick : false, + nextClick : false, + mouseWheel : true, + autoPlay : false, + playSpeed : 3000, + preload : 3, + modal : false, + loop : true, + + ajax : { + dataType : 'html', + headers : { 'X-fancyBox': true } + }, + iframe : { + scrolling : 'auto', + preload : true + }, + swf : { + wmode: 'transparent', + allowfullscreen : 'true', + allowscriptaccess : 'always' + }, + + keys : { + next : { + 13 : 'left', // enter + 34 : 'up', // page down + 39 : 'left', // right arrow + 40 : 'up' // down arrow + }, + prev : { + 8 : 'right', // backspace + 33 : 'down', // page up + 37 : 'right', // left arrow + 38 : 'down' // up arrow + }, + close : [27], // escape key + play : [32], // space - start/stop slideshow + toggle : [70] // letter "f" - toggle fullscreen + }, + + direction : { + next : 'left', + prev : 'right' + }, + + scrollOutside : true, + + // Override some properties + index : 0, + type : null, + href : null, + content : null, + title : null, + + // HTML templates + tpl: { + wrap : '
    ', + image : '', + iframe : '', + error : '

    The requested content cannot be loaded.
    Please try again later.

    ', + closeBtn : '', + next : '', + prev : '' + }, + + // Properties for each animation type + // Opening fancyBox + openEffect : 'fade', // 'elastic', 'fade' or 'none' + openSpeed : 250, + openEasing : 'swing', + openOpacity : true, + openMethod : 'zoomIn', + + // Closing fancyBox + closeEffect : 'fade', // 'elastic', 'fade' or 'none' + closeSpeed : 250, + closeEasing : 'swing', + closeOpacity : true, + closeMethod : 'zoomOut', + + // Changing next gallery item + nextEffect : 'elastic', // 'elastic', 'fade' or 'none' + nextSpeed : 250, + nextEasing : 'swing', + nextMethod : 'changeIn', + + // Changing previous gallery item + prevEffect : 'elastic', // 'elastic', 'fade' or 'none' + prevSpeed : 250, + prevEasing : 'swing', + prevMethod : 'changeOut', + + // Enable default helpers + helpers : { + overlay : true, + title : true + }, + + // Callbacks + onCancel : $.noop, // If canceling + beforeLoad : $.noop, // Before loading + afterLoad : $.noop, // After loading + beforeShow : $.noop, // Before changing in current item + afterShow : $.noop, // After opening + beforeChange : $.noop, // Before changing gallery item + beforeClose : $.noop, // Before closing + afterClose : $.noop // After closing + }, + + //Current state + group : {}, // Selected group + opts : {}, // Group options + previous : null, // Previous element + coming : null, // Element being loaded + current : null, // Currently loaded element + isActive : false, // Is activated + isOpen : false, // Is currently open + isOpened : false, // Have been fully opened at least once + + wrap : null, + skin : null, + outer : null, + inner : null, + + player : { + timer : null, + isActive : false + }, + + // Loaders + ajaxLoad : null, + imgPreload : null, + + // Some collections + transitions : {}, + helpers : {}, + + /* + * Static methods + */ + + open: function (group, opts) { + if (!group) { + return; + } + + if (!$.isPlainObject(opts)) { + opts = {}; + } + + // Close if already active + if (false === F.close(true)) { + return; + } + + // Normalize group + if (!$.isArray(group)) { + group = isQuery(group) ? $(group).get() : [group]; + } + + // Recheck if the type of each element is `object` and set content type (image, ajax, etc) + $.each(group, function(i, element) { + var obj = {}, + href, + title, + content, + type, + rez, + hrefParts, + selector; + + if ($.type(element) === "object") { + // Check if is DOM element + if (element.nodeType) { + element = $(element); + } + + if (isQuery(element)) { + obj = { + href : element.data('fancybox-href') || element.attr('href'), + title : $('
    ').text( element.data('fancybox-title') || element.attr('title') ).html(), + isDom : true, + element : element + }; + + if ($.metadata) { + $.extend(true, obj, element.metadata()); + } + + } else { + obj = element; + } + } + + href = opts.href || obj.href || (isString(element) ? element : null); + title = opts.title !== undefined ? opts.title : obj.title || ''; + + content = opts.content || obj.content; + type = content ? 'html' : (opts.type || obj.type); + + if (!type && obj.isDom) { + type = element.data('fancybox-type'); + + if (!type) { + rez = element.prop('class').match(/fancybox\.(\w+)/); + type = rez ? rez[1] : null; + } + } + + if (isString(href)) { + // Try to guess the content type + if (!type) { + if (F.isImage(href)) { + type = 'image'; + + } else if (F.isSWF(href)) { + type = 'swf'; + + } else if (href.charAt(0) === '#') { + type = 'inline'; + + } else if (isString(element)) { + type = 'html'; + content = element; + } + } + + // Split url into two pieces with source url and content selector, e.g, + // "/mypage.html #my_id" will load "/mypage.html" and display element having id "my_id" + if (type === 'ajax') { + hrefParts = href.split(/\s+/, 2); + href = hrefParts.shift(); + selector = hrefParts.shift(); + } + } + + if (!content) { + if (type === 'inline') { + if (href) { + content = $( isString(href) ? href.replace(/.*(?=#[^\s]+$)/, '') : href ); //strip for ie7 + + } else if (obj.isDom) { + content = element; + } + + } else if (type === 'html') { + content = href; + + } else if (!type && !href && obj.isDom) { + type = 'inline'; + content = element; + } + } + + $.extend(obj, { + href : href, + type : type, + content : content, + title : title, + selector : selector + }); + + group[ i ] = obj; + }); + + // Extend the defaults + F.opts = $.extend(true, {}, F.defaults, opts); + + // All options are merged recursive except keys + if (opts.keys !== undefined) { + F.opts.keys = opts.keys ? $.extend({}, F.defaults.keys, opts.keys) : false; + } + + F.group = group; + + return F._start(F.opts.index); + }, + + // Cancel image loading or abort ajax request + cancel: function () { + var coming = F.coming; + + if (coming && false === F.trigger('onCancel')) { + return; + } + + F.hideLoading(); + + if (!coming) { + return; + } + + if (F.ajaxLoad) { + F.ajaxLoad.abort(); + } + + F.ajaxLoad = null; + + if (F.imgPreload) { + F.imgPreload.onload = F.imgPreload.onerror = null; + } + + if (coming.wrap) { + coming.wrap.stop(true, true).trigger('onReset').remove(); + } + + F.coming = null; + + // If the first item has been canceled, then clear everything + if (!F.current) { + F._afterZoomOut( coming ); + } + }, + + // Start closing animation if is open; remove immediately if opening/closing + close: function (event) { + F.cancel(); + + if (false === F.trigger('beforeClose')) { + return; + } + + F.unbindEvents(); + + if (!F.isActive) { + return; + } + + if (!F.isOpen || event === true) { + $('.fancybox-wrap').stop(true).trigger('onReset').remove(); + + F._afterZoomOut(); + + } else { + F.isOpen = F.isOpened = false; + F.isClosing = true; + + $('.fancybox-item, .fancybox-nav').remove(); + + F.wrap.stop(true, true).removeClass('fancybox-opened'); + + F.transitions[ F.current.closeMethod ](); + } + }, + + // Manage slideshow: + // $.fancybox.play(); - toggle slideshow + // $.fancybox.play( true ); - start + // $.fancybox.play( false ); - stop + play: function ( action ) { + var clear = function () { + clearTimeout(F.player.timer); + }, + set = function () { + clear(); + + if (F.current && F.player.isActive) { + F.player.timer = setTimeout(F.next, F.current.playSpeed); + } + }, + stop = function () { + clear(); + + D.unbind('.player'); + + F.player.isActive = false; + + F.trigger('onPlayEnd'); + }, + start = function () { + if (F.current && (F.current.loop || F.current.index < F.group.length - 1)) { + F.player.isActive = true; + + D.bind({ + 'onCancel.player beforeClose.player' : stop, + 'onUpdate.player' : set, + 'beforeLoad.player' : clear + }); + + set(); + + F.trigger('onPlayStart'); + } + }; + + if (action === true || (!F.player.isActive && action !== false)) { + start(); + } else { + stop(); + } + }, + + // Navigate to next gallery item + next: function ( direction ) { + var current = F.current; + + if (current) { + if (!isString(direction)) { + direction = current.direction.next; + } + + F.jumpto(current.index + 1, direction, 'next'); + } + }, + + // Navigate to previous gallery item + prev: function ( direction ) { + var current = F.current; + + if (current) { + if (!isString(direction)) { + direction = current.direction.prev; + } + + F.jumpto(current.index - 1, direction, 'prev'); + } + }, + + // Navigate to gallery item by index + jumpto: function ( index, direction, router ) { + var current = F.current; + + if (!current) { + return; + } + + index = getScalar(index); + + F.direction = direction || current.direction[ (index >= current.index ? 'next' : 'prev') ]; + F.router = router || 'jumpto'; + + if (current.loop) { + if (index < 0) { + index = current.group.length + (index % current.group.length); + } + + index = index % current.group.length; + } + + if (current.group[ index ] !== undefined) { + F.cancel(); + + F._start(index); + } + }, + + // Center inside viewport and toggle position type to fixed or absolute if needed + reposition: function (e, onlyAbsolute) { + var current = F.current, + wrap = current ? current.wrap : null, + pos; + + if (wrap) { + pos = F._getPosition(onlyAbsolute); + + if (e && e.type === 'scroll') { + delete pos.position; + + wrap.stop(true, true).animate(pos, 200); + + } else { + wrap.css(pos); + + current.pos = $.extend({}, current.dim, pos); + } + } + }, + + update: function (e) { + var type = (e && e.originalEvent && e.originalEvent.type), + anyway = !type || type === 'orientationchange'; + + if (anyway) { + clearTimeout(didUpdate); + + didUpdate = null; + } + + if (!F.isOpen || didUpdate) { + return; + } + + didUpdate = setTimeout(function() { + var current = F.current; + + if (!current || F.isClosing) { + return; + } + + F.wrap.removeClass('fancybox-tmp'); + + if (anyway || type === 'load' || (type === 'resize' && current.autoResize)) { + F._setDimension(); + } + + if (!(type === 'scroll' && current.canShrink)) { + F.reposition(e); + } + + F.trigger('onUpdate'); + + didUpdate = null; + + }, (anyway && !isTouch ? 0 : 300)); + }, + + // Shrink content to fit inside viewport or restore if resized + toggle: function ( action ) { + if (F.isOpen) { + F.current.fitToView = $.type(action) === "boolean" ? action : !F.current.fitToView; + + // Help browser to restore document dimensions + if (isTouch) { + F.wrap.removeAttr('style').addClass('fancybox-tmp'); + + F.trigger('onUpdate'); + } + + F.update(); + } + }, + + hideLoading: function () { + D.unbind('.loading'); + + $('#fancybox-loading').remove(); + }, + + showLoading: function () { + var el, viewport; + + F.hideLoading(); + + el = $('
    ').click(F.cancel).appendTo('body'); + + // If user will press the escape-button, the request will be canceled + D.bind('keydown.loading', function(e) { + if ((e.which || e.keyCode) === 27) { + e.preventDefault(); + + F.cancel(); + } + }); + + if (!F.defaults.fixed) { + viewport = F.getViewport(); + + el.css({ + position : 'absolute', + top : (viewport.h * 0.5) + viewport.y, + left : (viewport.w * 0.5) + viewport.x + }); + } + + F.trigger('onLoading'); + }, + + getViewport: function () { + var locked = (F.current && F.current.locked) || false, + rez = { + x: W.scrollLeft(), + y: W.scrollTop() + }; + + if (locked && locked.length) { + rez.w = locked[0].clientWidth; + rez.h = locked[0].clientHeight; + + } else { + // See http://bugs.jquery.com/ticket/6724 + rez.w = isTouch && window.innerWidth ? window.innerWidth : W.width(); + rez.h = isTouch && window.innerHeight ? window.innerHeight : W.height(); + } + + return rez; + }, + + // Unbind the keyboard / clicking actions + unbindEvents: function () { + if (F.wrap && isQuery(F.wrap)) { + F.wrap.unbind('.fb'); + } + + D.unbind('.fb'); + W.unbind('.fb'); + }, + + bindEvents: function () { + var current = F.current, + keys; + + if (!current) { + return; + } + + // Changing document height on iOS devices triggers a 'resize' event, + // that can change document height... repeating infinitely + W.bind('orientationchange.fb' + (isTouch ? '' : ' resize.fb') + (current.autoCenter && !current.locked ? ' scroll.fb' : ''), F.update); + + keys = current.keys; + + if (keys) { + D.bind('keydown.fb', function (e) { + var code = e.which || e.keyCode, + target = e.target || e.srcElement; + + // Skip esc key if loading, because showLoading will cancel preloading + if (code === 27 && F.coming) { + return false; + } + + // Ignore key combinations and key events within form elements + if (!e.ctrlKey && !e.altKey && !e.shiftKey && !e.metaKey && !(target && (target.type || $(target).is('[contenteditable]')))) { + $.each(keys, function(i, val) { + if (current.group.length > 1 && val[ code ] !== undefined) { + F[ i ]( val[ code ] ); + + e.preventDefault(); + return false; + } + + if ($.inArray(code, val) > -1) { + F[ i ] (); + + e.preventDefault(); + return false; + } + }); + } + }); + } + + if ($.fn.mousewheel && current.mouseWheel) { + F.wrap.bind('mousewheel.fb', function (e, delta, deltaX, deltaY) { + var target = e.target || null, + parent = $(target), + canScroll = false; + + while (parent.length) { + if (canScroll || parent.is('.fancybox-skin') || parent.is('.fancybox-wrap')) { + break; + } + + canScroll = isScrollable( parent[0] ); + parent = $(parent).parent(); + } + + if (delta !== 0 && !canScroll) { + if (F.group.length > 1 && !current.canShrink) { + if (deltaY > 0 || deltaX > 0) { + F.prev( deltaY > 0 ? 'down' : 'left' ); + + } else if (deltaY < 0 || deltaX < 0) { + F.next( deltaY < 0 ? 'up' : 'right' ); + } + + e.preventDefault(); + } + } + }); + } + }, + + trigger: function (event, o) { + var ret, obj = o || F.coming || F.current; + + if (obj) { + if ($.isFunction( obj[event] )) { + ret = obj[event].apply(obj, Array.prototype.slice.call(arguments, 1)); + } + + if (ret === false) { + return false; + } + + if (obj.helpers) { + $.each(obj.helpers, function (helper, opts) { + if (opts && F.helpers[helper] && $.isFunction(F.helpers[helper][event])) { + F.helpers[helper][event]($.extend(true, {}, F.helpers[helper].defaults, opts), obj); + } + }); + } + } + + D.trigger(event); + }, + + isImage: function (str) { + return isString(str) && str.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i); + }, + + isSWF: function (str) { + return isString(str) && str.match(/\.(swf)((\?|#).*)?$/i); + }, + + _start: function (index) { + var coming = {}, + obj, + href, + type, + margin, + padding; + + index = getScalar( index ); + obj = F.group[ index ] || null; + + if (!obj) { + return false; + } + + coming = $.extend(true, {}, F.opts, obj); + + // Convert margin and padding properties to array - top, right, bottom, left + margin = coming.margin; + padding = coming.padding; + + if ($.type(margin) === 'number') { + coming.margin = [margin, margin, margin, margin]; + } + + if ($.type(padding) === 'number') { + coming.padding = [padding, padding, padding, padding]; + } + + // 'modal' propery is just a shortcut + if (coming.modal) { + $.extend(true, coming, { + closeBtn : false, + closeClick : false, + nextClick : false, + arrows : false, + mouseWheel : false, + keys : null, + helpers: { + overlay : { + closeClick : false + } + } + }); + } + + // 'autoSize' property is a shortcut, too + if (coming.autoSize) { + coming.autoWidth = coming.autoHeight = true; + } + + if (coming.width === 'auto') { + coming.autoWidth = true; + } + + if (coming.height === 'auto') { + coming.autoHeight = true; + } + + /* + * Add reference to the group, so it`s possible to access from callbacks, example: + * afterLoad : function() { + * this.title = 'Image ' + (this.index + 1) + ' of ' + this.group.length + (this.title ? ' - ' + this.title : ''); + * } + */ + + coming.group = F.group; + coming.index = index; + + // Give a chance for callback or helpers to update coming item (type, title, etc) + F.coming = coming; + + if (false === F.trigger('beforeLoad')) { + F.coming = null; + + return; + } + + type = coming.type; + href = coming.href; + + if (!type) { + F.coming = null; + + //If we can not determine content type then drop silently or display next/prev item if looping through gallery + if (F.current && F.router && F.router !== 'jumpto') { + F.current.index = index; + + return F[ F.router ]( F.direction ); + } + + return false; + } + + F.isActive = true; + + if (type === 'image' || type === 'swf') { + coming.autoHeight = coming.autoWidth = false; + coming.scrolling = 'visible'; + } + + if (type === 'image') { + coming.aspectRatio = true; + } + + if (type === 'iframe' && isTouch) { + coming.scrolling = 'scroll'; + } + + // Build the neccessary markup + coming.wrap = $(coming.tpl.wrap).addClass('fancybox-' + (isTouch ? 'mobile' : 'desktop') + ' fancybox-type-' + type + ' fancybox-tmp ' + coming.wrapCSS).appendTo( coming.parent || 'body' ); + + $.extend(coming, { + skin : $('.fancybox-skin', coming.wrap), + outer : $('.fancybox-outer', coming.wrap), + inner : $('.fancybox-inner', coming.wrap) + }); + + $.each(["Top", "Right", "Bottom", "Left"], function(i, v) { + coming.skin.css('padding' + v, getValue(coming.padding[ i ])); + }); + + F.trigger('onReady'); + + // Check before try to load; 'inline' and 'html' types need content, others - href + if (type === 'inline' || type === 'html') { + if (!coming.content || !coming.content.length) { + return F._error( 'content' ); + } + + } else if (!href) { + return F._error( 'href' ); + } + + if (type === 'image') { + F._loadImage(); + + } else if (type === 'ajax') { + F._loadAjax(); + + } else if (type === 'iframe') { + F._loadIframe(); + + } else { + F._afterLoad(); + } + }, + + _error: function ( type ) { + $.extend(F.coming, { + type : 'html', + autoWidth : true, + autoHeight : true, + minWidth : 0, + minHeight : 0, + scrolling : 'no', + hasError : type, + content : F.coming.tpl.error + }); + + F._afterLoad(); + }, + + _loadImage: function () { + // Reset preload image so it is later possible to check "complete" property + var img = F.imgPreload = new Image(); + + img.onload = function () { + this.onload = this.onerror = null; + + F.coming.width = this.width / F.opts.pixelRatio; + F.coming.height = this.height / F.opts.pixelRatio; + + F._afterLoad(); + }; + + img.onerror = function () { + this.onload = this.onerror = null; + + F._error( 'image' ); + }; + + img.src = F.coming.href; + + if (img.complete !== true) { + F.showLoading(); + } + }, + + _loadAjax: function () { + var coming = F.coming; + + F.showLoading(); + + F.ajaxLoad = $.ajax($.extend({}, coming.ajax, { + url: coming.href, + error: function (jqXHR, textStatus) { + if (F.coming && textStatus !== 'abort') { + F._error( 'ajax', jqXHR ); + + } else { + F.hideLoading(); + } + }, + success: function (data, textStatus) { + if (textStatus === 'success') { + coming.content = data; + + F._afterLoad(); + } + } + })); + }, + + _loadIframe: function() { + var coming = F.coming, + iframe = $(coming.tpl.iframe.replace(/\{rnd\}/g, new Date().getTime())) + .attr('scrolling', isTouch ? 'auto' : coming.iframe.scrolling) + .attr('src', coming.href); + + // This helps IE + $(coming.wrap).bind('onReset', function () { + try { + $(this).find('iframe').hide().attr('src', '//about:blank').end().empty(); + } catch (e) {} + }); + + if (coming.iframe.preload) { + F.showLoading(); + + iframe.one('load', function() { + $(this).data('ready', 1); + + // iOS will lose scrolling if we resize + if (!isTouch) { + $(this).bind('load.fb', F.update); + } + + // Without this trick: + // - iframe won't scroll on iOS devices + // - IE7 sometimes displays empty iframe + $(this).parents('.fancybox-wrap').width('100%').removeClass('fancybox-tmp').show(); + + F._afterLoad(); + }); + } + + coming.content = iframe.appendTo( coming.inner ); + + if (!coming.iframe.preload) { + F._afterLoad(); + } + }, + + _preloadImages: function() { + var group = F.group, + current = F.current, + len = group.length, + cnt = current.preload ? Math.min(current.preload, len - 1) : 0, + item, + i; + + for (i = 1; i <= cnt; i += 1) { + item = group[ (current.index + i ) % len ]; + + if (item.type === 'image' && item.href) { + new Image().src = item.href; + } + } + }, + + _afterLoad: function () { + var coming = F.coming, + previous = F.current, + placeholder = 'fancybox-placeholder', + current, + content, + type, + scrolling, + href, + embed; + + F.hideLoading(); + + if (!coming || F.isActive === false) { + return; + } + + if (false === F.trigger('afterLoad', coming, previous)) { + coming.wrap.stop(true).trigger('onReset').remove(); + + F.coming = null; + + return; + } + + if (previous) { + F.trigger('beforeChange', previous); + + previous.wrap.stop(true).removeClass('fancybox-opened') + .find('.fancybox-item, .fancybox-nav') + .remove(); + } + + F.unbindEvents(); + + current = coming; + content = coming.content; + type = coming.type; + scrolling = coming.scrolling; + + $.extend(F, { + wrap : current.wrap, + skin : current.skin, + outer : current.outer, + inner : current.inner, + current : current, + previous : previous + }); + + href = current.href; + + switch (type) { + case 'inline': + case 'ajax': + case 'html': + if (current.selector) { + content = $('
    ').html(content).find(current.selector); + + } else if (isQuery(content)) { + if (!content.data(placeholder)) { + content.data(placeholder, $('
    ').insertAfter( content ).hide() ); + } + + content = content.show().detach(); + + current.wrap.bind('onReset', function () { + if ($(this).find(content).length) { + content.hide().replaceAll( content.data(placeholder) ).data(placeholder, false); + } + }); + } + break; + + case 'image': + content = current.tpl.image.replace(/\{href\}/g, href); + break; + + case 'swf': + content = ''; + embed = ''; + + $.each(current.swf, function(name, val) { + content += ''; + embed += ' ' + name + '="' + val + '"'; + }); + + content += ''; + break; + } + + if (!(isQuery(content) && content.parent().is(current.inner))) { + current.inner.append( content ); + } + + // Give a chance for helpers or callbacks to update elements + F.trigger('beforeShow'); + + // Set scrolling before calculating dimensions + current.inner.css('overflow', scrolling === 'yes' ? 'scroll' : (scrolling === 'no' ? 'hidden' : scrolling)); + + // Set initial dimensions and start position + F._setDimension(); + + F.reposition(); + + F.isOpen = false; + F.coming = null; + + F.bindEvents(); + + if (!F.isOpened) { + $('.fancybox-wrap').not( current.wrap ).stop(true).trigger('onReset').remove(); + + } else if (previous.prevMethod) { + F.transitions[ previous.prevMethod ](); + } + + F.transitions[ F.isOpened ? current.nextMethod : current.openMethod ](); + + F._preloadImages(); + }, + + _setDimension: function () { + var viewport = F.getViewport(), + steps = 0, + canShrink = false, + canExpand = false, + wrap = F.wrap, + skin = F.skin, + inner = F.inner, + current = F.current, + width = current.width, + height = current.height, + minWidth = current.minWidth, + minHeight = current.minHeight, + maxWidth = current.maxWidth, + maxHeight = current.maxHeight, + scrolling = current.scrolling, + scrollOut = current.scrollOutside ? current.scrollbarWidth : 0, + margin = current.margin, + wMargin = getScalar(margin[1] + margin[3]), + hMargin = getScalar(margin[0] + margin[2]), + wPadding, + hPadding, + wSpace, + hSpace, + origWidth, + origHeight, + origMaxWidth, + origMaxHeight, + ratio, + width_, + height_, + maxWidth_, + maxHeight_, + iframe, + body; + + // Reset dimensions so we could re-check actual size + wrap.add(skin).add(inner).width('auto').height('auto').removeClass('fancybox-tmp'); + + wPadding = getScalar(skin.outerWidth(true) - skin.width()); + hPadding = getScalar(skin.outerHeight(true) - skin.height()); + + // Any space between content and viewport (margin, padding, border, title) + wSpace = wMargin + wPadding; + hSpace = hMargin + hPadding; + + origWidth = isPercentage(width) ? (viewport.w - wSpace) * getScalar(width) / 100 : width; + origHeight = isPercentage(height) ? (viewport.h - hSpace) * getScalar(height) / 100 : height; + + if (current.type === 'iframe') { + iframe = current.content; + + if (current.autoHeight && iframe.data('ready') === 1) { + try { + if (iframe[0].contentWindow.document.location) { + inner.width( origWidth ).height(9999); + + body = iframe.contents().find('body'); + + if (scrollOut) { + body.css('overflow-x', 'hidden'); + } + + origHeight = body.outerHeight(true); + } + + } catch (e) {} + } + + } else if (current.autoWidth || current.autoHeight) { + inner.addClass( 'fancybox-tmp' ); + + // Set width or height in case we need to calculate only one dimension + if (!current.autoWidth) { + inner.width( origWidth ); + } + + if (!current.autoHeight) { + inner.height( origHeight ); + } + + if (current.autoWidth) { + origWidth = inner.width(); + } + + if (current.autoHeight) { + origHeight = inner.height(); + } + + inner.removeClass( 'fancybox-tmp' ); + } + + width = getScalar( origWidth ); + height = getScalar( origHeight ); + + ratio = origWidth / origHeight; + + // Calculations for the content + minWidth = getScalar(isPercentage(minWidth) ? getScalar(minWidth, 'w') - wSpace : minWidth); + maxWidth = getScalar(isPercentage(maxWidth) ? getScalar(maxWidth, 'w') - wSpace : maxWidth); + + minHeight = getScalar(isPercentage(minHeight) ? getScalar(minHeight, 'h') - hSpace : minHeight); + maxHeight = getScalar(isPercentage(maxHeight) ? getScalar(maxHeight, 'h') - hSpace : maxHeight); + + // These will be used to determine if wrap can fit in the viewport + origMaxWidth = maxWidth; + origMaxHeight = maxHeight; + + if (current.fitToView) { + maxWidth = Math.min(viewport.w - wSpace, maxWidth); + maxHeight = Math.min(viewport.h - hSpace, maxHeight); + } + + maxWidth_ = viewport.w - wMargin; + maxHeight_ = viewport.h - hMargin; + + if (current.aspectRatio) { + if (width > maxWidth) { + width = maxWidth; + height = getScalar(width / ratio); + } + + if (height > maxHeight) { + height = maxHeight; + width = getScalar(height * ratio); + } + + if (width < minWidth) { + width = minWidth; + height = getScalar(width / ratio); + } + + if (height < minHeight) { + height = minHeight; + width = getScalar(height * ratio); + } + + } else { + width = Math.max(minWidth, Math.min(width, maxWidth)); + + if (current.autoHeight && current.type !== 'iframe') { + inner.width( width ); + + height = inner.height(); + } + + height = Math.max(minHeight, Math.min(height, maxHeight)); + } + + // Try to fit inside viewport (including the title) + if (current.fitToView) { + inner.width( width ).height( height ); + + wrap.width( width + wPadding ); + + // Real wrap dimensions + width_ = wrap.width(); + height_ = wrap.height(); + + if (current.aspectRatio) { + while ((width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight) { + if (steps++ > 19) { + break; + } + + height = Math.max(minHeight, Math.min(maxHeight, height - 10)); + width = getScalar(height * ratio); + + if (width < minWidth) { + width = minWidth; + height = getScalar(width / ratio); + } + + if (width > maxWidth) { + width = maxWidth; + height = getScalar(width / ratio); + } + + inner.width( width ).height( height ); + + wrap.width( width + wPadding ); + + width_ = wrap.width(); + height_ = wrap.height(); + } + + } else { + width = Math.max(minWidth, Math.min(width, width - (width_ - maxWidth_))); + height = Math.max(minHeight, Math.min(height, height - (height_ - maxHeight_))); + } + } + + if (scrollOut && scrolling === 'auto' && height < origHeight && (width + wPadding + scrollOut) < maxWidth_) { + width += scrollOut; + } + + inner.width( width ).height( height ); + + wrap.width( width + wPadding ); + + width_ = wrap.width(); + height_ = wrap.height(); + + canShrink = (width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight; + canExpand = current.aspectRatio ? (width < origMaxWidth && height < origMaxHeight && width < origWidth && height < origHeight) : ((width < origMaxWidth || height < origMaxHeight) && (width < origWidth || height < origHeight)); + + $.extend(current, { + dim : { + width : getValue( width_ ), + height : getValue( height_ ) + }, + origWidth : origWidth, + origHeight : origHeight, + canShrink : canShrink, + canExpand : canExpand, + wPadding : wPadding, + hPadding : hPadding, + wrapSpace : height_ - skin.outerHeight(true), + skinSpace : skin.height() - height + }); + + if (!iframe && current.autoHeight && height > minHeight && height < maxHeight && !canExpand) { + inner.height('auto'); + } + }, + + _getPosition: function (onlyAbsolute) { + var current = F.current, + viewport = F.getViewport(), + margin = current.margin, + width = F.wrap.width() + margin[1] + margin[3], + height = F.wrap.height() + margin[0] + margin[2], + rez = { + position: 'absolute', + top : margin[0], + left : margin[3] + }; + + if (current.autoCenter && current.fixed && !onlyAbsolute && height <= viewport.h && width <= viewport.w) { + rez.position = 'fixed'; + + } else if (!current.locked) { + rez.top += viewport.y; + rez.left += viewport.x; + } + + rez.top = getValue(Math.max(rez.top, rez.top + ((viewport.h - height) * current.topRatio))); + rez.left = getValue(Math.max(rez.left, rez.left + ((viewport.w - width) * current.leftRatio))); + + return rez; + }, + + _afterZoomIn: function () { + var current = F.current; + + if (!current) { + return; + } + + F.isOpen = F.isOpened = true; + + F.wrap.css('overflow', 'visible').addClass('fancybox-opened').hide().show(0); + + F.update(); + + // Assign a click event + if ( current.closeClick || (current.nextClick && F.group.length > 1) ) { + F.inner.css('cursor', 'pointer').bind('click.fb', function(e) { + if (!$(e.target).is('a') && !$(e.target).parent().is('a')) { + e.preventDefault(); + + F[ current.closeClick ? 'close' : 'next' ](); + } + }); + } + + // Create a close button + if (current.closeBtn) { + $(current.tpl.closeBtn).appendTo(F.skin).bind('click.fb', function(e) { + e.preventDefault(); + + F.close(); + }); + } + + // Create navigation arrows + if (current.arrows && F.group.length > 1) { + if (current.loop || current.index > 0) { + $(current.tpl.prev).appendTo(F.outer).bind('click.fb', F.prev); + } + + if (current.loop || current.index < F.group.length - 1) { + $(current.tpl.next).appendTo(F.outer).bind('click.fb', F.next); + } + } + + F.trigger('afterShow'); + + // Stop the slideshow if this is the last item + if (!current.loop && current.index === current.group.length - 1) { + + F.play( false ); + + } else if (F.opts.autoPlay && !F.player.isActive) { + F.opts.autoPlay = false; + + F.play(true); + } + }, + + _afterZoomOut: function ( obj ) { + obj = obj || F.current; + + $('.fancybox-wrap').trigger('onReset').remove(); + + $.extend(F, { + group : {}, + opts : {}, + router : false, + current : null, + isActive : false, + isOpened : false, + isOpen : false, + isClosing : false, + wrap : null, + skin : null, + outer : null, + inner : null + }); + + F.trigger('afterClose', obj); + } + }); + + /* + * Default transitions + */ + + F.transitions = { + getOrigPosition: function () { + var current = F.current, + element = current.element, + orig = current.orig, + pos = {}, + width = 50, + height = 50, + hPadding = current.hPadding, + wPadding = current.wPadding, + viewport = F.getViewport(); + + if (!orig && current.isDom && element.is(':visible')) { + orig = element.find('img:first'); + + if (!orig.length) { + orig = element; + } + } + + if (isQuery(orig)) { + pos = orig.offset(); + + if (orig.is('img')) { + width = orig.outerWidth(); + height = orig.outerHeight(); + } + + } else { + pos.top = viewport.y + (viewport.h - height) * current.topRatio; + pos.left = viewport.x + (viewport.w - width) * current.leftRatio; + } + + if (F.wrap.css('position') === 'fixed' || current.locked) { + pos.top -= viewport.y; + pos.left -= viewport.x; + } + + pos = { + top : getValue(pos.top - hPadding * current.topRatio), + left : getValue(pos.left - wPadding * current.leftRatio), + width : getValue(width + wPadding), + height : getValue(height + hPadding) + }; + + return pos; + }, + + step: function (now, fx) { + var ratio, + padding, + value, + prop = fx.prop, + current = F.current, + wrapSpace = current.wrapSpace, + skinSpace = current.skinSpace; + + if (prop === 'width' || prop === 'height') { + ratio = fx.end === fx.start ? 1 : (now - fx.start) / (fx.end - fx.start); + + if (F.isClosing) { + ratio = 1 - ratio; + } + + padding = prop === 'width' ? current.wPadding : current.hPadding; + value = now - padding; + + F.skin[ prop ]( getScalar( prop === 'width' ? value : value - (wrapSpace * ratio) ) ); + F.inner[ prop ]( getScalar( prop === 'width' ? value : value - (wrapSpace * ratio) - (skinSpace * ratio) ) ); + } + }, + + zoomIn: function () { + var current = F.current, + startPos = current.pos, + effect = current.openEffect, + elastic = effect === 'elastic', + endPos = $.extend({opacity : 1}, startPos); + + // Remove "position" property that breaks older IE + delete endPos.position; + + if (elastic) { + startPos = this.getOrigPosition(); + + if (current.openOpacity) { + startPos.opacity = 0.1; + } + + } else if (effect === 'fade') { + startPos.opacity = 0.1; + } + + F.wrap.css(startPos).animate(endPos, { + duration : effect === 'none' ? 0 : current.openSpeed, + easing : current.openEasing, + step : elastic ? this.step : null, + complete : F._afterZoomIn + }); + }, + + zoomOut: function () { + var current = F.current, + effect = current.closeEffect, + elastic = effect === 'elastic', + endPos = {opacity : 0.1}; + + if (elastic) { + endPos = this.getOrigPosition(); + + if (current.closeOpacity) { + endPos.opacity = 0.1; + } + } + + F.wrap.animate(endPos, { + duration : effect === 'none' ? 0 : current.closeSpeed, + easing : current.closeEasing, + step : elastic ? this.step : null, + complete : F._afterZoomOut + }); + }, + + changeIn: function () { + var current = F.current, + effect = current.nextEffect, + startPos = current.pos, + endPos = { opacity : 1 }, + direction = F.direction, + distance = 200, + field; + + startPos.opacity = 0.1; + + if (effect === 'elastic') { + field = direction === 'down' || direction === 'up' ? 'top' : 'left'; + + if (direction === 'down' || direction === 'right') { + startPos[ field ] = getValue(getScalar(startPos[ field ]) - distance); + endPos[ field ] = '+=' + distance + 'px'; + + } else { + startPos[ field ] = getValue(getScalar(startPos[ field ]) + distance); + endPos[ field ] = '-=' + distance + 'px'; + } + } + + // Workaround for http://bugs.jquery.com/ticket/12273 + if (effect === 'none') { + F._afterZoomIn(); + + } else { + F.wrap.css(startPos).animate(endPos, { + duration : current.nextSpeed, + easing : current.nextEasing, + complete : F._afterZoomIn + }); + } + }, + + changeOut: function () { + var previous = F.previous, + effect = previous.prevEffect, + endPos = { opacity : 0.1 }, + direction = F.direction, + distance = 200; + + if (effect === 'elastic') { + endPos[ direction === 'down' || direction === 'up' ? 'top' : 'left' ] = ( direction === 'up' || direction === 'left' ? '-' : '+' ) + '=' + distance + 'px'; + } + + previous.wrap.animate(endPos, { + duration : effect === 'none' ? 0 : previous.prevSpeed, + easing : previous.prevEasing, + complete : function () { + $(this).trigger('onReset').remove(); + } + }); + } + }; + + /* + * Overlay helper + */ + + F.helpers.overlay = { + defaults : { + closeClick : true, // if true, fancyBox will be closed when user clicks on the overlay + speedOut : 200, // duration of fadeOut animation + showEarly : true, // indicates if should be opened immediately or wait until the content is ready + css : {}, // custom CSS properties + locked : !isTouch, // if true, the content will be locked into overlay + fixed : true // if false, the overlay CSS position property will not be set to "fixed" + }, + + overlay : null, // current handle + fixed : false, // indicates if the overlay has position "fixed" + el : $('html'), // element that contains "the lock" + + // Public methods + create : function(opts) { + var parent; + + opts = $.extend({}, this.defaults, opts); + + if (this.overlay) { + this.close(); + } + + parent = F.coming ? F.coming.parent : opts.parent; + + this.overlay = $('
    ').appendTo( parent && parent.lenth ? parent : 'body' ); + this.fixed = false; + + if (opts.fixed && F.defaults.fixed) { + this.overlay.addClass('fancybox-overlay-fixed'); + + this.fixed = true; + } + }, + + open : function(opts) { + var that = this; + + opts = $.extend({}, this.defaults, opts); + + if (this.overlay) { + this.overlay.unbind('.overlay').width('auto').height('auto'); + + } else { + this.create(opts); + } + + if (!this.fixed) { + W.bind('resize.overlay', $.proxy( this.update, this) ); + + this.update(); + } + + if (opts.closeClick) { + this.overlay.bind('click.overlay', function(e) { + if ($(e.target).hasClass('fancybox-overlay')) { + if (F.isActive) { + F.close(); + } else { + that.close(); + } + + return false; + } + }); + } + + this.overlay.css( opts.css ).show(); + }, + + close : function() { + W.unbind('resize.overlay'); + + if (this.el.hasClass('fancybox-lock')) { + $('.fancybox-margin').removeClass('fancybox-margin'); + + this.el.removeClass('fancybox-lock'); + + W.scrollTop( this.scrollV ).scrollLeft( this.scrollH ); + } + + $('.fancybox-overlay').remove().hide(); + + $.extend(this, { + overlay : null, + fixed : false + }); + }, + + // Private, callbacks + + update : function () { + var width = '100%', offsetWidth; + + // Reset width/height so it will not mess + this.overlay.width(width).height('100%'); + + // jQuery does not return reliable result for IE + if (IE) { + offsetWidth = Math.max(document.documentElement.offsetWidth, document.body.offsetWidth); + + if (D.width() > offsetWidth) { + width = D.width(); + } + + } else if (D.width() > W.width()) { + width = D.width(); + } + + this.overlay.width(width).height(D.height()); + }, + + // This is where we can manipulate DOM, because later it would cause iframes to reload + onReady : function (opts, obj) { + var overlay = this.overlay; + + $('.fancybox-overlay').stop(true, true); + + if (!overlay) { + this.create(opts); + } + + if (opts.locked && this.fixed && obj.fixed) { + obj.locked = this.overlay.append( obj.wrap ); + obj.fixed = false; + } + + if (opts.showEarly === true) { + this.beforeShow.apply(this, arguments); + } + }, + + beforeShow : function(opts, obj) { + if (obj.locked && !this.el.hasClass('fancybox-lock')) { + if (this.fixPosition !== false) { + $('*').filter(function(){ + return ($(this).css('position') === 'fixed' && !$(this).hasClass("fancybox-overlay") && !$(this).hasClass("fancybox-wrap") ); + }).addClass('fancybox-margin'); + } + + this.el.addClass('fancybox-margin'); + + this.scrollV = W.scrollTop(); + this.scrollH = W.scrollLeft(); + + this.el.addClass('fancybox-lock'); + + W.scrollTop( this.scrollV ).scrollLeft( this.scrollH ); + } + + this.open(opts); + }, + + onUpdate : function() { + if (!this.fixed) { + this.update(); + } + }, + + afterClose: function (opts) { + // Remove overlay if exists and fancyBox is not opening + // (e.g., it is not being open using afterClose callback) + if (this.overlay && !F.coming) { + this.overlay.fadeOut(opts.speedOut, $.proxy( this.close, this )); + } + } + }; + + /* + * Title helper + */ + + F.helpers.title = { + defaults : { + type : 'float', // 'float', 'inside', 'outside' or 'over', + position : 'bottom' // 'top' or 'bottom' + }, + + beforeShow: function (opts) { + var current = F.current, + text = current.title, + type = opts.type, + title, + target; + + if ($.isFunction(text)) { + text = text.call(current.element, current); + } + + if (!isString(text) || $.trim(text) === '') { + return; + } + + title = $('
    ' + text + '
    '); + + switch (type) { + case 'inside': + target = F.skin; + break; + + case 'outside': + target = F.wrap; + break; + + case 'over': + target = F.inner; + break; + + default: // 'float' + target = F.skin; + + title.appendTo('body'); + + if (IE) { + title.width( title.width() ); + } + + title.wrapInner(''); + + //Increase bottom margin so this title will also fit into viewport + F.current.margin[2] += Math.abs( getScalar(title.css('margin-bottom')) ); + break; + } + + title[ (opts.position === 'top' ? 'prependTo' : 'appendTo') ](target); + } + }; + + // jQuery plugin initialization + $.fn.fancybox = function (options) { + var index, + that = $(this), + selector = this.selector || '', + run = function(e) { + var what = $(this).blur(), idx = index, relType, relVal; + + if (!(e.ctrlKey || e.altKey || e.shiftKey || e.metaKey) && !what.is('.fancybox-wrap')) { + relType = options.groupAttr || 'data-fancybox-group'; + relVal = what.attr(relType); + + if (!relVal) { + relType = 'rel'; + relVal = what.get(0)[ relType ]; + } + + if (relVal && relVal !== '' && relVal !== 'nofollow') { + what = selector.length ? $(selector) : that; + what = what.filter('[' + relType + '="' + relVal + '"]'); + idx = what.index(this); + } + + options.index = idx; + + // Stop an event from bubbling if everything is fine + if (F.open(what, options) !== false) { + e.preventDefault(); + } + } + }; + + options = options || {}; + index = options.index || 0; + + if (!selector || options.live === false) { + that.unbind('click.fb-start').bind('click.fb-start', run); + + } else { + D.undelegate(selector, 'click.fb-start').delegate(selector + ":not('.fancybox-item, .fancybox-nav')", 'click.fb-start', run); + } + + this.filter('[data-fancybox-start=1]').trigger('click'); + + return this; + }; + + // Tests that need a body at doc ready + D.ready(function() { + var w1, w2; + + if ( $.scrollbarWidth === undefined ) { + // http://benalman.com/projects/jquery-misc-plugins/#scrollbarwidth + $.scrollbarWidth = function() { + var parent = $('
    ').appendTo('body'), + child = parent.children(), + width = child.innerWidth() - child.height( 99 ).innerWidth(); + + parent.remove(); + + return width; + }; + } + + if ( $.support.fixedPosition === undefined ) { + $.support.fixedPosition = (function() { + var elem = $('
    ').appendTo('body'), + fixed = ( elem[0].offsetTop === 20 || elem[0].offsetTop === 15 ); + + elem.remove(); + + return fixed; + }()); + } + + $.extend(F.defaults, { + scrollbarWidth : $.scrollbarWidth(), + fixed : $.support.fixedPosition, + parent : $('body') + }); + + //Get real width of page scroll-bar + w1 = $(window).width(); + + H.addClass('fancybox-lock-test'); + + w2 = $(window).width(); + + H.removeClass('fancybox-lock-test'); + + $("").appendTo("head"); + }); + +}(window, document, jQuery)); \ No newline at end of file diff --git a/themes/landscape/source/fancybox/jquery.fancybox.pack.js b/themes/landscape/source/fancybox/jquery.fancybox.pack.js new file mode 100644 index 0000000..2db1280 --- /dev/null +++ b/themes/landscape/source/fancybox/jquery.fancybox.pack.js @@ -0,0 +1,46 @@ +/*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */ +(function(s,H,f,w){var K=f("html"),q=f(s),p=f(H),b=f.fancybox=function(){b.open.apply(this,arguments)},J=navigator.userAgent.match(/msie/i),C=null,t=H.createTouch!==w,u=function(a){return a&&a.hasOwnProperty&&a instanceof f},r=function(a){return a&&"string"===f.type(a)},F=function(a){return r(a)&&0
    ',image:'',iframe:'",error:'

    The requested content cannot be loaded.
    Please try again later.

    ',closeBtn:'',next:'',prev:''},openEffect:"fade",openSpeed:250,openEasing:"swing",openOpacity:!0, +openMethod:"zoomIn",closeEffect:"fade",closeSpeed:250,closeEasing:"swing",closeOpacity:!0,closeMethod:"zoomOut",nextEffect:"elastic",nextSpeed:250,nextEasing:"swing",nextMethod:"changeIn",prevEffect:"elastic",prevSpeed:250,prevEasing:"swing",prevMethod:"changeOut",helpers:{overlay:!0,title:!0},onCancel:f.noop,beforeLoad:f.noop,afterLoad:f.noop,beforeShow:f.noop,afterShow:f.noop,beforeChange:f.noop,beforeClose:f.noop,afterClose:f.noop},group:{},opts:{},previous:null,coming:null,current:null,isActive:!1, +isOpen:!1,isOpened:!1,wrap:null,skin:null,outer:null,inner:null,player:{timer:null,isActive:!1},ajaxLoad:null,imgPreload:null,transitions:{},helpers:{},open:function(a,d){if(a&&(f.isPlainObject(d)||(d={}),!1!==b.close(!0)))return f.isArray(a)||(a=u(a)?f(a).get():[a]),f.each(a,function(e,c){var l={},g,h,k,n,m;"object"===f.type(c)&&(c.nodeType&&(c=f(c)),u(c)?(l={href:c.data("fancybox-href")||c.attr("href"),title:f("
    ").text(c.data("fancybox-title")||c.attr("title")).html(),isDom:!0,element:c}, +f.metadata&&f.extend(!0,l,c.metadata())):l=c);g=d.href||l.href||(r(c)?c:null);h=d.title!==w?d.title:l.title||"";n=(k=d.content||l.content)?"html":d.type||l.type;!n&&l.isDom&&(n=c.data("fancybox-type"),n||(n=(n=c.prop("class").match(/fancybox\.(\w+)/))?n[1]:null));r(g)&&(n||(b.isImage(g)?n="image":b.isSWF(g)?n="swf":"#"===g.charAt(0)?n="inline":r(c)&&(n="html",k=c)),"ajax"===n&&(m=g.split(/\s+/,2),g=m.shift(),m=m.shift()));k||("inline"===n?g?k=f(r(g)?g.replace(/.*(?=#[^\s]+$)/,""):g):l.isDom&&(k=c): +"html"===n?k=g:n||g||!l.isDom||(n="inline",k=c));f.extend(l,{href:g,type:n,content:k,title:h,selector:m});a[e]=l}),b.opts=f.extend(!0,{},b.defaults,d),d.keys!==w&&(b.opts.keys=d.keys?f.extend({},b.defaults.keys,d.keys):!1),b.group=a,b._start(b.opts.index)},cancel:function(){var a=b.coming;a&&!1===b.trigger("onCancel")||(b.hideLoading(),a&&(b.ajaxLoad&&b.ajaxLoad.abort(),b.ajaxLoad=null,b.imgPreload&&(b.imgPreload.onload=b.imgPreload.onerror=null),a.wrap&&a.wrap.stop(!0,!0).trigger("onReset").remove(), +b.coming=null,b.current||b._afterZoomOut(a)))},close:function(a){b.cancel();!1!==b.trigger("beforeClose")&&(b.unbindEvents(),b.isActive&&(b.isOpen&&!0!==a?(b.isOpen=b.isOpened=!1,b.isClosing=!0,f(".fancybox-item, .fancybox-nav").remove(),b.wrap.stop(!0,!0).removeClass("fancybox-opened"),b.transitions[b.current.closeMethod]()):(f(".fancybox-wrap").stop(!0).trigger("onReset").remove(),b._afterZoomOut())))},play:function(a){var d=function(){clearTimeout(b.player.timer)},e=function(){d();b.current&&b.player.isActive&& +(b.player.timer=setTimeout(b.next,b.current.playSpeed))},c=function(){d();p.unbind(".player");b.player.isActive=!1;b.trigger("onPlayEnd")};!0===a||!b.player.isActive&&!1!==a?b.current&&(b.current.loop||b.current.index=c.index?"next":"prev"],b.router=e||"jumpto",c.loop&&(0>a&&(a=c.group.length+a%c.group.length),a%=c.group.length),c.group[a]!==w&&(b.cancel(),b._start(a)))},reposition:function(a,d){var e=b.current,c=e?e.wrap:null,l;c&&(l=b._getPosition(d),a&&"scroll"===a.type?(delete l.position,c.stop(!0,!0).animate(l,200)):(c.css(l),e.pos=f.extend({},e.dim,l)))}, +update:function(a){var d=a&&a.originalEvent&&a.originalEvent.type,e=!d||"orientationchange"===d;e&&(clearTimeout(C),C=null);b.isOpen&&!C&&(C=setTimeout(function(){var c=b.current;c&&!b.isClosing&&(b.wrap.removeClass("fancybox-tmp"),(e||"load"===d||"resize"===d&&c.autoResize)&&b._setDimension(),"scroll"===d&&c.canShrink||b.reposition(a),b.trigger("onUpdate"),C=null)},e&&!t?0:300))},toggle:function(a){b.isOpen&&(b.current.fitToView="boolean"===f.type(a)?a:!b.current.fitToView,t&&(b.wrap.removeAttr("style").addClass("fancybox-tmp"), +b.trigger("onUpdate")),b.update())},hideLoading:function(){p.unbind(".loading");f("#fancybox-loading").remove()},showLoading:function(){var a,d;b.hideLoading();a=f('
    ').click(b.cancel).appendTo("body");p.bind("keydown.loading",function(a){27===(a.which||a.keyCode)&&(a.preventDefault(),b.cancel())});b.defaults.fixed||(d=b.getViewport(),a.css({position:"absolute",top:0.5*d.h+d.y,left:0.5*d.w+d.x}));b.trigger("onLoading")},getViewport:function(){var a=b.current&& +b.current.locked||!1,d={x:q.scrollLeft(),y:q.scrollTop()};a&&a.length?(d.w=a[0].clientWidth,d.h=a[0].clientHeight):(d.w=t&&s.innerWidth?s.innerWidth:q.width(),d.h=t&&s.innerHeight?s.innerHeight:q.height());return d},unbindEvents:function(){b.wrap&&u(b.wrap)&&b.wrap.unbind(".fb");p.unbind(".fb");q.unbind(".fb")},bindEvents:function(){var a=b.current,d;a&&(q.bind("orientationchange.fb"+(t?"":" resize.fb")+(a.autoCenter&&!a.locked?" scroll.fb":""),b.update),(d=a.keys)&&p.bind("keydown.fb",function(e){var c= +e.which||e.keyCode,l=e.target||e.srcElement;if(27===c&&b.coming)return!1;e.ctrlKey||e.altKey||e.shiftKey||e.metaKey||l&&(l.type||f(l).is("[contenteditable]"))||f.each(d,function(d,l){if(1h[0].clientWidth||h[0].clientHeight&&h[0].scrollHeight>h[0].clientHeight),h=f(h).parent();0!==c&&!k&&1g||0>l)&&b.next(0>g?"up":"right"),d.preventDefault())}))},trigger:function(a,d){var e,c=d||b.coming||b.current;if(c){f.isFunction(c[a])&&(e=c[a].apply(c,Array.prototype.slice.call(arguments,1)));if(!1===e)return!1;c.helpers&&f.each(c.helpers,function(d,e){if(e&& +b.helpers[d]&&f.isFunction(b.helpers[d][a]))b.helpers[d][a](f.extend(!0,{},b.helpers[d].defaults,e),c)})}p.trigger(a)},isImage:function(a){return r(a)&&a.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i)},isSWF:function(a){return r(a)&&a.match(/\.(swf)((\?|#).*)?$/i)},_start:function(a){var d={},e,c;a=m(a);e=b.group[a]||null;if(!e)return!1;d=f.extend(!0,{},b.opts,e);e=d.margin;c=d.padding;"number"===f.type(e)&&(d.margin=[e,e,e,e]);"number"===f.type(c)&&(d.padding=[c,c, +c,c]);d.modal&&f.extend(!0,d,{closeBtn:!1,closeClick:!1,nextClick:!1,arrows:!1,mouseWheel:!1,keys:null,helpers:{overlay:{closeClick:!1}}});d.autoSize&&(d.autoWidth=d.autoHeight=!0);"auto"===d.width&&(d.autoWidth=!0);"auto"===d.height&&(d.autoHeight=!0);d.group=b.group;d.index=a;b.coming=d;if(!1===b.trigger("beforeLoad"))b.coming=null;else{c=d.type;e=d.href;if(!c)return b.coming=null,b.current&&b.router&&"jumpto"!==b.router?(b.current.index=a,b[b.router](b.direction)):!1;b.isActive=!0;if("image"=== +c||"swf"===c)d.autoHeight=d.autoWidth=!1,d.scrolling="visible";"image"===c&&(d.aspectRatio=!0);"iframe"===c&&t&&(d.scrolling="scroll");d.wrap=f(d.tpl.wrap).addClass("fancybox-"+(t?"mobile":"desktop")+" fancybox-type-"+c+" fancybox-tmp "+d.wrapCSS).appendTo(d.parent||"body");f.extend(d,{skin:f(".fancybox-skin",d.wrap),outer:f(".fancybox-outer",d.wrap),inner:f(".fancybox-inner",d.wrap)});f.each(["Top","Right","Bottom","Left"],function(a,b){d.skin.css("padding"+b,x(d.padding[a]))});b.trigger("onReady"); +if("inline"===c||"html"===c){if(!d.content||!d.content.length)return b._error("content")}else if(!e)return b._error("href");"image"===c?b._loadImage():"ajax"===c?b._loadAjax():"iframe"===c?b._loadIframe():b._afterLoad()}},_error:function(a){f.extend(b.coming,{type:"html",autoWidth:!0,autoHeight:!0,minWidth:0,minHeight:0,scrolling:"no",hasError:a,content:b.coming.tpl.error});b._afterLoad()},_loadImage:function(){var a=b.imgPreload=new Image;a.onload=function(){this.onload=this.onerror=null;b.coming.width= +this.width/b.opts.pixelRatio;b.coming.height=this.height/b.opts.pixelRatio;b._afterLoad()};a.onerror=function(){this.onload=this.onerror=null;b._error("image")};a.src=b.coming.href;!0!==a.complete&&b.showLoading()},_loadAjax:function(){var a=b.coming;b.showLoading();b.ajaxLoad=f.ajax(f.extend({},a.ajax,{url:a.href,error:function(a,e){b.coming&&"abort"!==e?b._error("ajax",a):b.hideLoading()},success:function(d,e){"success"===e&&(a.content=d,b._afterLoad())}}))},_loadIframe:function(){var a=b.coming, +d=f(a.tpl.iframe.replace(/\{rnd\}/g,(new Date).getTime())).attr("scrolling",t?"auto":a.iframe.scrolling).attr("src",a.href);f(a.wrap).bind("onReset",function(){try{f(this).find("iframe").hide().attr("src","//about:blank").end().empty()}catch(a){}});a.iframe.preload&&(b.showLoading(),d.one("load",function(){f(this).data("ready",1);t||f(this).bind("load.fb",b.update);f(this).parents(".fancybox-wrap").width("100%").removeClass("fancybox-tmp").show();b._afterLoad()}));a.content=d.appendTo(a.inner);a.iframe.preload|| +b._afterLoad()},_preloadImages:function(){var a=b.group,d=b.current,e=a.length,c=d.preload?Math.min(d.preload,e-1):0,f,g;for(g=1;g<=c;g+=1)f=a[(d.index+g)%e],"image"===f.type&&f.href&&((new Image).src=f.href)},_afterLoad:function(){var a=b.coming,d=b.current,e,c,l,g,h;b.hideLoading();if(a&&!1!==b.isActive)if(!1===b.trigger("afterLoad",a,d))a.wrap.stop(!0).trigger("onReset").remove(),b.coming=null;else{d&&(b.trigger("beforeChange",d),d.wrap.stop(!0).removeClass("fancybox-opened").find(".fancybox-item, .fancybox-nav").remove()); +b.unbindEvents();e=a.content;c=a.type;l=a.scrolling;f.extend(b,{wrap:a.wrap,skin:a.skin,outer:a.outer,inner:a.inner,current:a,previous:d});g=a.href;switch(c){case "inline":case "ajax":case "html":a.selector?e=f("
    ").html(e).find(a.selector):u(e)&&(e.data("fancybox-placeholder")||e.data("fancybox-placeholder",f('
    ').insertAfter(e).hide()),e=e.show().detach(),a.wrap.bind("onReset",function(){f(this).find(e).length&&e.hide().replaceAll(e.data("fancybox-placeholder")).data("fancybox-placeholder", +!1)}));break;case "image":e=a.tpl.image.replace(/\{href\}/g,g);break;case "swf":e='',h="",f.each(a.swf,function(a,b){e+='';h+=" "+a+'="'+b+'"'}),e+='"}u(e)&&e.parent().is(a.inner)||a.inner.append(e);b.trigger("beforeShow"); +a.inner.css("overflow","yes"===l?"scroll":"no"===l?"hidden":l);b._setDimension();b.reposition();b.isOpen=!1;b.coming=null;b.bindEvents();if(!b.isOpened)f(".fancybox-wrap").not(a.wrap).stop(!0).trigger("onReset").remove();else if(d.prevMethod)b.transitions[d.prevMethod]();b.transitions[b.isOpened?a.nextMethod:a.openMethod]();b._preloadImages()}},_setDimension:function(){var a=b.getViewport(),d=0,e=!1,c=!1,e=b.wrap,l=b.skin,g=b.inner,h=b.current,c=h.width,k=h.height,n=h.minWidth,v=h.minHeight,p=h.maxWidth, +q=h.maxHeight,t=h.scrolling,r=h.scrollOutside?h.scrollbarWidth:0,y=h.margin,z=m(y[1]+y[3]),s=m(y[0]+y[2]),w,A,u,D,B,G,C,E,I;e.add(l).add(g).width("auto").height("auto").removeClass("fancybox-tmp");y=m(l.outerWidth(!0)-l.width());w=m(l.outerHeight(!0)-l.height());A=z+y;u=s+w;D=F(c)?(a.w-A)*m(c)/100:c;B=F(k)?(a.h-u)*m(k)/100:k;if("iframe"===h.type){if(I=h.content,h.autoHeight&&1===I.data("ready"))try{I[0].contentWindow.document.location&&(g.width(D).height(9999),G=I.contents().find("body"),r&&G.css("overflow-x", +"hidden"),B=G.outerHeight(!0))}catch(H){}}else if(h.autoWidth||h.autoHeight)g.addClass("fancybox-tmp"),h.autoWidth||g.width(D),h.autoHeight||g.height(B),h.autoWidth&&(D=g.width()),h.autoHeight&&(B=g.height()),g.removeClass("fancybox-tmp");c=m(D);k=m(B);E=D/B;n=m(F(n)?m(n,"w")-A:n);p=m(F(p)?m(p,"w")-A:p);v=m(F(v)?m(v,"h")-u:v);q=m(F(q)?m(q,"h")-u:q);G=p;C=q;h.fitToView&&(p=Math.min(a.w-A,p),q=Math.min(a.h-u,q));A=a.w-z;s=a.h-s;h.aspectRatio?(c>p&&(c=p,k=m(c/E)),k>q&&(k=q,c=m(k*E)),cA||z>s)&&c>n&&k>v&&!(19p&&(c=p,k=m(c/E)),g.width(c).height(k),e.width(c+y),a=e.width(),z=e.height();else c=Math.max(n,Math.min(c,c-(a-A))),k=Math.max(v,Math.min(k,k-(z-s)));r&&"auto"===t&&kA||z>s)&&c>n&&k>v;c=h.aspectRatio?cv&&k
    ').appendTo(d&&d.lenth?d:"body");this.fixed=!1;a.fixed&&b.defaults.fixed&&(this.overlay.addClass("fancybox-overlay-fixed"),this.fixed=!0)},open:function(a){var d=this;a=f.extend({},this.defaults,a);this.overlay?this.overlay.unbind(".overlay").width("auto").height("auto"):this.create(a);this.fixed||(q.bind("resize.overlay",f.proxy(this.update,this)),this.update());a.closeClick&&this.overlay.bind("click.overlay", +function(a){if(f(a.target).hasClass("fancybox-overlay"))return b.isActive?b.close():d.close(),!1});this.overlay.css(a.css).show()},close:function(){q.unbind("resize.overlay");this.el.hasClass("fancybox-lock")&&(f(".fancybox-margin").removeClass("fancybox-margin"),this.el.removeClass("fancybox-lock"),q.scrollTop(this.scrollV).scrollLeft(this.scrollH));f(".fancybox-overlay").remove().hide();f.extend(this,{overlay:null,fixed:!1})},update:function(){var a="100%",b;this.overlay.width(a).height("100%"); +J?(b=Math.max(H.documentElement.offsetWidth,H.body.offsetWidth),p.width()>b&&(a=p.width())):p.width()>q.width()&&(a=p.width());this.overlay.width(a).height(p.height())},onReady:function(a,b){var e=this.overlay;f(".fancybox-overlay").stop(!0,!0);e||this.create(a);a.locked&&this.fixed&&b.fixed&&(b.locked=this.overlay.append(b.wrap),b.fixed=!1);!0===a.showEarly&&this.beforeShow.apply(this,arguments)},beforeShow:function(a,b){b.locked&&!this.el.hasClass("fancybox-lock")&&(!1!==this.fixPosition&&f("*").filter(function(){return"fixed"=== +f(this).css("position")&&!f(this).hasClass("fancybox-overlay")&&!f(this).hasClass("fancybox-wrap")}).addClass("fancybox-margin"),this.el.addClass("fancybox-margin"),this.scrollV=q.scrollTop(),this.scrollH=q.scrollLeft(),this.el.addClass("fancybox-lock"),q.scrollTop(this.scrollV).scrollLeft(this.scrollH));this.open(a)},onUpdate:function(){this.fixed||this.update()},afterClose:function(a){this.overlay&&!b.coming&&this.overlay.fadeOut(a.speedOut,f.proxy(this.close,this))}};b.helpers.title={defaults:{type:"float", +position:"bottom"},beforeShow:function(a){var d=b.current,e=d.title,c=a.type;f.isFunction(e)&&(e=e.call(d.element,d));if(r(e)&&""!==f.trim(e)){d=f('
    '+e+"
    ");switch(c){case "inside":c=b.skin;break;case "outside":c=b.wrap;break;case "over":c=b.inner;break;default:c=b.skin,d.appendTo("body"),J&&d.width(d.width()),d.wrapInner(''),b.current.margin[2]+=Math.abs(m(d.css("margin-bottom")))}d["top"===a.position?"prependTo": +"appendTo"](c)}}};f.fn.fancybox=function(a){var d,e=f(this),c=this.selector||"",l=function(g){var h=f(this).blur(),k=d,l,m;g.ctrlKey||g.altKey||g.shiftKey||g.metaKey||h.is(".fancybox-wrap")||(l=a.groupAttr||"data-fancybox-group",m=h.attr(l),m||(l="rel",m=h.get(0)[l]),m&&""!==m&&"nofollow"!==m&&(h=c.length?f(c):e,h=h.filter("["+l+'="'+m+'"]'),k=h.index(this)),a.index=k,!1!==b.open(h,a)&&g.preventDefault())};a=a||{};d=a.index||0;c&&!1!==a.live?p.undelegate(c,"click.fb-start").delegate(c+":not('.fancybox-item, .fancybox-nav')", +"click.fb-start",l):e.unbind("click.fb-start").bind("click.fb-start",l);this.filter("[data-fancybox-start=1]").trigger("click");return this};p.ready(function(){var a,d;f.scrollbarWidth===w&&(f.scrollbarWidth=function(){var a=f('
    ').appendTo("body"),b=a.children(),b=b.innerWidth()-b.height(99).innerWidth();a.remove();return b});f.support.fixedPosition===w&&(f.support.fixedPosition=function(){var a=f('
    ').appendTo("body"), +b=20===a[0].offsetTop||15===a[0].offsetTop;a.remove();return b}());f.extend(b.defaults,{scrollbarWidth:f.scrollbarWidth(),fixed:f.support.fixedPosition,parent:f("body")});a=f(s).width();K.addClass("fancybox-lock-test");d=f(s).width();K.removeClass("fancybox-lock-test");f("").appendTo("head")})})(window,document,jQuery); \ No newline at end of file diff --git a/themes/landscape/source/js/script.js b/themes/landscape/source/js/script.js new file mode 100644 index 0000000..1e58767 --- /dev/null +++ b/themes/landscape/source/js/script.js @@ -0,0 +1,137 @@ +(function($){ + // Search + var $searchWrap = $('#search-form-wrap'), + isSearchAnim = false, + searchAnimDuration = 200; + + var startSearchAnim = function(){ + isSearchAnim = true; + }; + + var stopSearchAnim = function(callback){ + setTimeout(function(){ + isSearchAnim = false; + callback && callback(); + }, searchAnimDuration); + }; + + $('#nav-search-btn').on('click', function(){ + if (isSearchAnim) return; + + startSearchAnim(); + $searchWrap.addClass('on'); + stopSearchAnim(function(){ + $('.search-form-input').focus(); + }); + }); + + $('.search-form-input').on('blur', function(){ + startSearchAnim(); + $searchWrap.removeClass('on'); + stopSearchAnim(); + }); + + // Share + $('body').on('click', function(){ + $('.article-share-box.on').removeClass('on'); + }).on('click', '.article-share-link', function(e){ + e.stopPropagation(); + + var $this = $(this), + url = $this.attr('data-url'), + encodedUrl = encodeURIComponent(url), + id = 'article-share-box-' + $this.attr('data-id'), + offset = $this.offset(); + + if ($('#' + id).length){ + var box = $('#' + id); + + if (box.hasClass('on')){ + box.removeClass('on'); + return; + } + } else { + var html = [ + '
    ', + '', + '
    ', + '', + '', + '', + '', + '
    ', + '
    ' + ].join(''); + + var box = $(html); + + $('body').append(box); + } + + $('.article-share-box.on').hide(); + + box.css({ + top: offset.top + 25, + left: offset.left + }).addClass('on'); + }).on('click', '.article-share-box', function(e){ + e.stopPropagation(); + }).on('click', '.article-share-box-input', function(){ + $(this).select(); + }).on('click', '.article-share-box-link', function(e){ + e.preventDefault(); + e.stopPropagation(); + + window.open(this.href, 'article-share-box-window-' + Date.now(), 'width=500,height=450'); + }); + + // Caption + $('.article-entry').each(function(i){ + $(this).find('img').each(function(){ + if ($(this).parent().hasClass('fancybox')) return; + + var alt = this.alt; + + if (alt) $(this).after('' + alt + ''); + + $(this).wrap(''); + }); + + $(this).find('.fancybox').each(function(){ + $(this).attr('rel', 'article' + i); + }); + }); + + if ($.fancybox){ + $('.fancybox').fancybox(); + } + + // Mobile nav + var $container = $('#container'), + isMobileNavAnim = false, + mobileNavAnimDuration = 200; + + var startMobileNavAnim = function(){ + isMobileNavAnim = true; + }; + + var stopMobileNavAnim = function(){ + setTimeout(function(){ + isMobileNavAnim = false; + }, mobileNavAnimDuration); + } + + $('#main-nav-toggle').on('click', function(){ + if (isMobileNavAnim) return; + + startMobileNavAnim(); + $container.toggleClass('mobile-nav-on'); + stopMobileNavAnim(); + }); + + $('#wrap').on('click', function(){ + if (isMobileNavAnim || !$container.hasClass('mobile-nav-on')) return; + + $container.removeClass('mobile-nav-on'); + }); +})(jQuery); \ No newline at end of file diff --git a/themes/next-5.1.4/.bowerrc b/themes/next-5.1.4/.bowerrc new file mode 100644 index 0000000..8013f26 --- /dev/null +++ b/themes/next-5.1.4/.bowerrc @@ -0,0 +1,3 @@ +{ + "directory": "source/lib" +} diff --git a/themes/next-5.1.4/.editorconfig b/themes/next-5.1.4/.editorconfig new file mode 100644 index 0000000..f0627b9 --- /dev/null +++ b/themes/next-5.1.4/.editorconfig @@ -0,0 +1,14 @@ +# editorconfig.org + +root = true + +[*] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true +indent_style = space +indent_size = 2 + +[*.py] +indent_size = 4 diff --git a/themes/next-5.1.4/.gitattributes b/themes/next-5.1.4/.gitattributes new file mode 100644 index 0000000..7ead58e --- /dev/null +++ b/themes/next-5.1.4/.gitattributes @@ -0,0 +1,2 @@ +source/lib/* linguist-vendored +scripts/merge.js linguist-vendored diff --git a/themes/next-5.1.4/.github/CONTRIBUTING.md b/themes/next-5.1.4/.github/CONTRIBUTING.md new file mode 100644 index 0000000..9175b91 --- /dev/null +++ b/themes/next-5.1.4/.github/CONTRIBUTING.md @@ -0,0 +1,6 @@ +Before submitting an issue, please search for the issue [here](https://github.com/iissnan/hexo-theme-next/issues?utf8=%E2%9C%93&q=) to find if the issue is already reported. + +Also, you can search for answers on the [NexT Documentation Site](http://theme-next.iissnan.com/): + +- [常见问题 - 中文文档](http://theme-next.iissnan.com/faqs.html) +- FAQs (Work in progress) diff --git a/themes/next-5.1.4/.github/ISSUE_TEMPLATE.md b/themes/next-5.1.4/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..debe5b4 --- /dev/null +++ b/themes/next-5.1.4/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,58 @@ + + +### I agree and want to create new issue + + +- [] Yes, I was on [Hexo Docs page](https://hexo.io/docs/), especially on [Templates](https://hexo.io/docs/templates.html), [Variables](https://hexo.io/docs/variables.html), [Helpers](https://hexo.io/docs/helpers.html) and [Troubleshooting](https://hexo.io/docs/troubleshooting.html). +- [] Yes, I was on [NexT Documentation Site](http://theme-next.iissnan.com/). +- [] And yes, I already searched for current [issues](https://github.com/iissnan/hexo-theme-next/issues?utf8=%E2%9C%93&q=is%3Aissue) and this is not help to me. + +*** + +### Expected behavior + + +### Actual behavior + + +### Steps to reproduce the behavior +1. N/A +2. N/A +3. N/A + +* Link to demo site with this issue: N/A +* Link(s) to source code or any usefull link(s): N/A + +### Hexo Information + +``` + +``` + +### NexT Information + +**NexT Version:** + +``` +[] Latest Master branch. +[] Latest Release version. +[] Old version - +``` + +**NexT Scheme:** + +``` +[] All schemes +[] Muse +[] Mist +[] Pisces +[] Gemini +``` + +### Other Information diff --git a/themes/next-5.1.4/.github/PULL_REQUEST_TEMPLATE.md b/themes/next-5.1.4/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..af32032 --- /dev/null +++ b/themes/next-5.1.4/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,87 @@ + + + + +## PR Checklist +**Please check if your PR fulfills the following requirements:** + +- [ ] The commit message follows [our guidelines](https://github.com/iissnan/hexo-theme-next/blob/master/.github/CONTRIBUTING.md). +- [ ] Tests for the changes have been added (for bug fixes / features). + - [ ] Muse | Mist have been tested. + - [ ] Pisces | Gemini have been tested. +- [ ] Docs have been added / updated (for bug fixes / features). + +## PR Type +**What kind of change does this PR introduce?** + +- [ ] Bugfix. +- [ ] Feature. +- [ ] Code style update (formatting, local variables). +- [ ] Refactoring (no functional changes, no api changes). +- [ ] Build related changes. +- [ ] CI related changes. +- [ ] Documentation content changes. +- [ ] Other... Please describe: + +## What is the current behavior? + + +Issue Number(s): N/A + +## What is the new behavior? +Description about this pull, in several words... + +* Screens with this changes: N/A +* Link to demo site with this changes: N/A + +### How to use? +In NexT `_config.yml`: +```yml +... +``` + +## Does this PR introduce a breaking change? +- [ ] Yes. +- [ ] No. + + + + + + diff --git a/themes/next-5.1.4/.github/browserstack_logo.png b/themes/next-5.1.4/.github/browserstack_logo.png new file mode 100644 index 0000000..0be37e7 Binary files /dev/null and b/themes/next-5.1.4/.github/browserstack_logo.png differ diff --git a/themes/next-5.1.4/.gitignore b/themes/next-5.1.4/.gitignore new file mode 100644 index 0000000..df03369 --- /dev/null +++ b/themes/next-5.1.4/.gitignore @@ -0,0 +1,20 @@ +.DS_Store +.idea/ +*.log +*.iml +yarn.lock +package-lock.json +node_modules/ + +# Ignore unused verdors' files +source/lib/fancybox/* +!source/lib/fancybox/source/ + +source/lib/font-awesome/less/ +source/lib/font-awesome/scss/ + +source/lib/ua-parser-js/* +!source/lib/ua-parser-js/dist/ + +source/lib/Han/* +!source/lib/Han/dist/ diff --git a/themes/next-5.1.4/.hound.yml b/themes/next-5.1.4/.hound.yml new file mode 100644 index 0000000..534bae8 --- /dev/null +++ b/themes/next-5.1.4/.hound.yml @@ -0,0 +1,4 @@ +javascript: + enabled: true + config_file: .jshintrc + ignore_file: .javascript_ignore diff --git a/themes/next-5.1.4/.javascript_ignore b/themes/next-5.1.4/.javascript_ignore new file mode 100644 index 0000000..ad0d1ea --- /dev/null +++ b/themes/next-5.1.4/.javascript_ignore @@ -0,0 +1,5 @@ +source/vendors/* +source/lib/* +source/js/src/affix.js +source/js/src/scrollspy.js +source/js/src/js.cookie.js diff --git a/themes/next-5.1.4/.jshintrc b/themes/next-5.1.4/.jshintrc new file mode 100644 index 0000000..a2d0ed3 --- /dev/null +++ b/themes/next-5.1.4/.jshintrc @@ -0,0 +1,27 @@ +{ + "asi": false, + "bitwise": true, + "browser": true, + "camelcase": true, + "curly": true, + "forin": true, + "immed": true, + "latedef": "nofunc", + "maxlen": 120, + "newcap": true, + "noarg": true, + "noempty": true, + "nonew": true, + "predef": [ + "$", + "jQuery", + "NexT", + "CONFIG" + ], + "quotmark": true, + "trailing": true, + "undef": true, + "unused": true, + + "expr": true +} diff --git a/themes/next-5.1.4/.stylintrc b/themes/next-5.1.4/.stylintrc new file mode 100644 index 0000000..38e6ac1 --- /dev/null +++ b/themes/next-5.1.4/.stylintrc @@ -0,0 +1,45 @@ +{ + "blocks": false, + "brackets": "always", + "colons": "always", + "colors": "always", + "commaSpace": "always", + "commentSpace": "always", + "cssLiteral": "never", + "customProperties": [], + "depthLimit": false, + "duplicates": true, + "efficient": "always", + "exclude": [], + "extendPref": false, + "globalDupe": false, + "groupOutputByFile": true, + "indentPref": false, + "leadingZero": "never", + "maxErrors": false, + "maxWarnings": false, + "mixed": false, + "mixins": [], + "namingConvention": "lowercase-dash", + "namingConventionStrict": false, + "none": "never", + "noImportant": true, + "parenSpace": false, + "placeholders": "always", + "prefixVarsWithDollar": "always", + "quotePref": false, + "reporterOptions": { + "columns": ["lineData", "severity", "description", "rule"], + "columnSplitter": " ", + "showHeaders": false, + "truncate": true + }, + "semicolons": "always", + "sortOrder": "grouped", + "stackedProperties": false, + "trailingWhitespace": "never", + "universal": false, + "valid": true, + "zeroUnits": "never", + "zIndexNormalize": false +} diff --git a/themes/next-5.1.4/.travis.yml b/themes/next-5.1.4/.travis.yml new file mode 100644 index 0000000..a607f87 --- /dev/null +++ b/themes/next-5.1.4/.travis.yml @@ -0,0 +1,17 @@ +language: node_js +node_js: node + +cache: + directories: + - node_modules + +install: npm install + +before_script: + - npm install -g gulp + +addons: + browserstack: + username: "ivannginx1" + access_key: + secure: "NutOhdgtUdBUXMPZhy8X1F1Jq+tan1LeNOV0FArBt15SNlxtNArqhiyTi4XnG9MPruX4306aGF2RBrKso+OiGNRdGtRGngH613Q0GWNtlC/boMqnI7fHqLIyCs6S12y2uA8PK4Ifxg9bZ0VtCTYYbMy+p1KvBM//L12vmtfdnby8z5Qvex3tB3dLoPOR50CKkINHJVDLm+iVRFrdz4/83oDsulZSRRGIaxu5taDWPIcp3fYZtre2Nc+RXcsyFDyjN7U0Hvr5tKBbloJxXEQEBv2xLkMOtp85nmCPD06s1Il8Wus1ux3raVsfUyaW5FpNX37Jeb5e00RQUM1wgU5m75H6qiGwDvQswbugJG0i/a2nNfsgVmbrSZdMnkHcx2Uxmrw4ejyEP5NSrJSBi05Ck1fQ4UsZ4Qkdf1fd04SI0LpLWt43eoNO/7rHKsQoP4LCX9gxKUuC075NEBLODyJ529RYfA6dKKwwH6o0ZbOgASmCoAWaM65g4+FHRnJcKL/Kj9ZWklQtRa7/ynlHaA65jefFS2lB8Ut6d3rXDDBih9mIrwV1uUaEH96xgAN42bgU/vY6FGzNkDOYZqj4YfsepDM0wbOsslFie7JZq7iFjsYvrXqLvYUMk37AZwQ2Sb6uH4tIT4Qw/4oZfDzA1En3/8HdZJ28nKW/lzjwMSqheIY=" diff --git a/themes/next-5.1.4/LICENSE b/themes/next-5.1.4/LICENSE new file mode 100644 index 0000000..0bf8716 --- /dev/null +++ b/themes/next-5.1.4/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2014-2017 iissnan + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/themes/next-5.1.4/README.cn.md b/themes/next-5.1.4/README.cn.md new file mode 100644 index 0000000..c9eb9a8 --- /dev/null +++ b/themes/next-5.1.4/README.cn.md @@ -0,0 +1,383 @@ +#
    e x T
    + +

    NexT 是一个高质量并且优雅的Hexo 主题。这是精心制作做出来的 hexo 主题。

    + +![NexT Schemes](http://iissnan.com/nexus/next/next-schemes.jpg) + +[![Join the chat at https://gitter.im/iissnan/hexo-theme-next](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/iissnan/hexo-theme-next?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) +[![mnt-image]][commits-url] +[![travis-image]][travis-url] +[![rel-image]][releases-url] +[![hexo-image]][hexo-url] +[![lic-image]](LICENSE) + +* NexT 使用文档 | [English Documentation](README.md) + +## 实时预览 Live Preview + + +* :heart_decoration: Muse 方案: [XiaMo](https://notes.wanghao.work) | [OAwan](https://oawan.me) | [Hui Wang](http://hui-wang.info) +* :six_pointed_star: Mist 方案: [Jeff](https://blog.zzbd.org) | [uchuhimo](http://uchuhimo.me) | [xirong](http://www.ixirong.com) +* :pisces: Pisces 方案: [Vi](http://notes.iissnan.com) | [Acris](https://acris.me) | [Rainy](https://rainylog.com) +* :gemini: Gemini 方案: [Ivan.Nginx](https://almostover.ru) | [Alynx](http://sh.alynx.xyz) | [Raincal](https://raincal.top) + + +更多 NexT 例子点击 [这里](https://github.com/iissnan/hexo-theme-next/issues/119). + +## 安装 Installation + +**1.** 在终端切换到**hexo 根**目录. 在hexo目录下一定有 `node_modules`, `source`, `themes` 和其他文件夹: + ```sh + $ cd hexo + $ ls + _config.yml node_modules package.json public scaffolds source themes + ``` + +**2.** 从 github 上获取主题 。这里有几种方式来获取主题: + +### 下载[最新发布的版本][releases-latest-url] Download tagged release version +   在大多数情况下 **稳定**。 推荐用户下载这个。 + + [![curl-tar-wget-image]][curl-tar-wget-url] + + ```sh + $ mkdir themes/next + $ curl -s https://api.github.com/repos/iissnan/hexo-theme-next/releases/latest | grep tarball_url | cut -d '"' -f 4 | wget -i - -O- | tar -zx -C themes/next --strip-components=1 + ``` + +### 下载[标签发布版本][releases-url] Download tagged release version +   您必须定义版本。从[标签列表][tags-url]里选择版本替换`v5.1.2`。 + + [![curl-tar-image]][curl-tar-url] + + ```sh + $ mkdir themes/next + $ curl -L https://api.github.com/repos/iissnan/hexo-theme-next/tarball/v5.1.2 | tar -zxv -C themes/next --strip-components=1 + ``` + + [![git-image]][git-url] + + ```sh + $ git clone --branch v5.1.2 https://github.com/iissnan/hexo-theme-next themes/next + ``` + +### 下载[最新的 master 分支][download-latest-url] Download latest master branch +  可能会 **不稳定**, 但是包含最新的特色,推荐开发者下载. + + [![curl-tar-image]][curl-tar-url] + + ```sh + $ mkdir themes/next + $ curl -L https://api.github.com/repos/iissnan/hexo-theme-next/tarball | tar -zxv -C themes/next --strip-components=1 + ``` + + [![git-image]][git-url] + + ```sh + $ git clone https://github.com/iissnan/hexo-theme-next themes/next + ``` + + 使用克隆命令,你将得到**整个存储库**。而且在任何时候你都可以切换到任何标签发布版本。 + 获取标签列表: + + ```sh + $ cd themes/next + $ git tag -l + … + v5.0.0 + v5.0.1 + v5.1.0 + v5.1.1 + v5.1.2 + ``` + +   例如, 你想要切换到`v5.1.0` [标签发布版本][tags-url]. 输入以下命令: + + ```sh + $ git checkout tags/v5.1.0 + Note: checking out 'tags/v5.1.0'. + … + HEAD now on 1f72f68... CSS: Remove global list-style setting of ul + ``` + +   如果你想切换回 [master 分支][commits-url]的话, 输入这个命令: + + ```sh + $ git checkout master + ``` + +**3.** 在 **hexo 根目录下** 的配置文件`_config.yml`里设置主题: + + theme: next + +### Bugs +对于那些遇到 **Error: Cannot find module 'hexo-util'** [问题](https://github.com/iissnan/hexo-theme-next/issues/1490)的人, 请检查你的NPM 版本. + +- `版本 > 3`: 如果仍然不行的话,请移除 `node_modules` 文件 然后重新安装,使用 `npm install`命令。 +- `版本 < 3`: 请通过`npm install --save-dev hexo-util`命令添加`hexo-util`到你的站点包依赖里 + +## 更新 Update + +```sh +$ cd themes/next +$ git pull +``` + +### Bugs + +> 提交您的更改或存储它们,然后才能合并。 + +您必须提交,存储或放弃本地更改. 看 [here](https://stackoverflow.com/a/15745424/5861495) 是如何做的。 + +### 使用Hexo data files([#328](https://github.com/iissnan/hexo-theme-next/issues/328))配置主题 Theme configurations using Hexo data files #328 + + +目前升级 NexT 主题的时候并不是非常的流畅。若使用 `git pull` 的方式,很多时候可能会产生冲突;而下载新版本覆盖安装的方式又需要手动合并主题的 `_config.yml` 文件。 + +在此修改之前, NexT 建议将配置分离,一部分在 站点的配置文件中,另外一部分在主题的配置文件中。将需要自定的选项放置在 站点配置文件中,从而脱离避免更新主题时可能遇到的麻烦。这种方式是可行,但是有一些缺点: + +1. 配置分离成了两个部分 +2. 用户可能会疑惑一些选项该放置在哪里比较合适 + +为了解决这个问题, NexT 将会使用 Hexo 的 [Data Files](https://hexo.io/docs/data-files.html) 。然而由于 Data Files 是在 Hexo 3 版本时引进的,所以要使用这个特性,需要 Hexo 的版本不低于 3。 + +若你比较喜欢 Hexo 2.x 版本,可以继续使用原先的配置方式。 NexT 保持着向下兼容。 + + +#### 特性 Benefits + +通过这个特性,你可以将所有的主题配置放置在站点的 `source/_data/next.yml` 文件中。原先放置在 站点配置文件 中的选项可以迁移到新的位置,同时,主题配置文件可以不用做任何修改。若后续版本有配置相关的改动时,你仅需在 `next.yml` 中做相应调整即可 + + +#### 如何使用这个特性 How to use this feature + +1. 请先确保你所使用的 Hexo 版本在 3 以上 +2. 在站点的 `source/_data` 目录下新建 `next.yml` 文件(`_data`目录可能需要新建) +3. 迁移站点配置文件和主题配置文件中的配置到 `next.yml` 中 +4. 使用 `--config source/_data/next.yml` 参数启动服务器, 生成或者部署。\ +   例如: `hexo clean --config source/_data/next.yml && hexo g --config source/_data/next.yml`。 + +## 特色 Features + +### 支持多国语言, 包括: +:cn: 简体中文 & 繁体中文
    +:us: 英语
    +:ru: 俄语
    +:fr: 法语
    +:de: 德语
    +:jp: 日语
    +:indonesia: 印度尼西亚语
    +:portugal: 葡萄牙语 (巴西)
    +:kr: 朝鲜语
    +:it: 意大利语
    +:netherlands: 荷兰语 + +默认语言是英语。 + +```yml +language: en +# language: zh-Hans +# language: zh-hk +# language: zh-tw +# language: ru +# language: fr-FR +# language: de +# language: ja +# language: id +# language: pt +# language: pt-BR +# language: ko +# language: it +# language: nl-NL +``` + +在站点配置文件`_config.yml`中可以将语言切换成中文 + +```yml +language: zh-Hans +``` + +### 评论支持 Comment support + +NexT 已经原生支持 `多说` and `Disqus` 评论系统。 + +添加以下代码到你的主题配置文件 `_config.yml`: + +```yml +duoshuo: + enable: true + shortname: your-duoshuo-shortname +``` + +或者 + +```yml +disqus_shortname: your-disqus-shortname +``` + +### 标签页 Tags page + +> 添加一个标签页面,里面包含您网站中的所有标签。 + +- 创建一个名为 `tags` 页面 + + hexo new page "tags" + +- 编辑标签页, 设置页面类型为`tags`. + + title: All tags + date: 2014-12-22 12:39:04 + type: "tags" + +- 添加 `tags` 到主题配置文件 `_config.yml` 里: + + menu: + home: / + archives: /archives + tags: /tags + +### 分类页 Categories page + +> 添加一个分类页面,里面包含您网站中的所有分类。 + +- 创建一个名为 `categories` 页面 + + hexo new page "categories" + +- 编辑分类页, 设置页面类型为 `categories`. + + title: All categories + date: 2014-12-22 12:39:04 + type: "categories" + +- 添加 `categories` 到主题配置文件 `_config.yml` 里: + + menu: + home: / + archives: /archives + categories: /categories + +### 社交媒体 Social Media + +NexT 可以自动添加链接到您的社交媒体帐户里: + +```yml +social: + GitHub: your-github-url + Twitter: your-twitter-url + Weibo: your-weibo-url + DouBan: your-douban-url + ZhiHu: your-zhihu-url +``` + +### Feed 链接 Feed link + +> 显示 feed 链接。 + +在主题配置文件`_config.yml`里设置`rss` , 如下所示: + +1. `rss: false` 会禁用 feed 链接。 +2. `rss: ` 使用站点 feed 链接。这是默认的选项。 + +    按照插件[hexo-generator-feed](https://github.com/hexojs/hexo-generator-feed)的README中的安装说明进行操作。在完成这个插件的配置后,Feed链接也生成好了 + +3. `rss: http://your-feed-url` 设置你的 feed 链接. + +### 内置5种代码高亮主题 Up to 5 code highlight themes built-in + +NexT 使用的是 [Tomorrow 主题](https://github.com/chriskempson/tomorrow-theme) ,一共有5种主题供你选择。 +Next 默认使用 `normal`. 下面是 `normal` 和 `night` 主题的预览: + +![Tomorrow Normal Preview](http://iissnan.com/nexus/next/tomorrow-normal.png) +![Tomorrow Night Preview](http://iissnan.com/nexus/next/tomorrow-night.png) + +查看更多信息点击[Tomorrow 主题](https://github.com/chriskempson/tomorrow-theme)。 + +## 配置 Configuration + +NexT 的配置很少 + +```yml + +# Menu configuration. +menu: + home: / + archives: /archives + +# Favicon +favicon: /favicon.ico + +# Avatar (put the image into next/source/images/) +# can be any image format supported by web browsers (JPEG,PNG,GIF,SVG,..) +avatar: /default_avatar.png + +# Code highlight theme +# available: normal | night | night eighties | night blue | night bright +highlight_theme: normal + +# Fancybox for image gallery +fancybox: true + +# Specify the date when the site was setup +since: 2013 + +``` + + +## 浏览器支持 Browser support + +![Browser support](http://iissnan.com/nexus/next/browser-support.png) + +[![Browser Stack](.github/browserstack_logo.png)](https://www.browserstack.com/) +>**BrowserStack** is a cloud-based cross-browser testing tool that enables developers to test their websites across various browsers on different operating systems and mobile devices, without requiring users to install virtual machines, devices or emulators. + +## 贡献 Contributing + +接受各种形式的贡献,包括不限于提交问题与需求,修复代码。等待您的`Pull Request`。 + +Any types of contribution are welcome. Thanks. + +**ATTENTION! Contributors on Chinese docs needed!**\ +Need to translate from [English docs](README.md) to Chinese docs.\ +Any help wanted!\ +Thank's a lot! + +## 开发 Development + +NexT 主旨在于简洁优雅且易于使用,所以首先要尽量确保 NexT 的简洁易用性。 + +NexT is built for easily use with elegant appearance. First things first, always keep things simple. + +## [开发历史 Changelog](https://github.com/iissnan/hexo-theme-next/wiki/Changelog) + + + +[browser-image]: https://img.shields.io/badge/browser-%20chrome%20%7C%20firefox%20%7C%20opera%20%7C%20safari%20%7C%20ie%20%3E%3D%209-lightgrey.svg +[browser-url]: https://www.browserstack.com + +[gitter-image]: https://badges.gitter.im/Join%20Chat.svg +[gitter-url]: https://gitter.im/iissnan/hexo-theme-next?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge + +[travis-image]: https://travis-ci.org/iissnan/hexo-theme-next.svg?branch=master +[travis-url]: https://travis-ci.org/iissnan/hexo-theme-next?branch=master "Travis CI" + +[hexo-image]: https://img.shields.io/badge/hexo-%3E%3D%203.0-blue.svg +[hexo-url]: http://hexo.io + +[mnt-image]: https://img.shields.io/maintenance/yes/2017.svg +[rel-image]: https://img.shields.io/github/release/iissnan/hexo-theme-next.svg + +[lic-image]: https://img.shields.io/dub/l/vibe-d.svg + +[git-image]: https://img.shields.io/badge/install%20with%20-git-blue.svg +[curl-tar-image]: https://img.shields.io/badge/install%20with%20-curl%20%7C%20tar-blue.svg +[curl-tar-wget-image]: https://img.shields.io/badge/install%20with%20-curl%20%7C%20tar%20%7C%20wget-blue.svg +[git-url]: http://lmgtfy.com/?q=linux+git+install +[curl-tar-url]: http://lmgtfy.com/?q=linux+curl+tar+install +[curl-tar-wget-url]: http://lmgtfy.com/?q=linux+curl+tar+wget+install + +[download-latest-url]: https://github.com/iissnan/hexo-theme-next/archive/master.zip +[releases-latest-url]: https://github.com/iissnan/hexo-theme-next/releases/latest +[releases-url]: https://github.com/iissnan/hexo-theme-next/releases +[tags-url]: https://github.com/iissnan/hexo-theme-next/tags +[commits-url]: https://github.com/iissnan/hexo-theme-next/commits/master diff --git a/themes/next-5.1.4/README.md b/themes/next-5.1.4/README.md new file mode 100644 index 0000000..1de8710 --- /dev/null +++ b/themes/next-5.1.4/README.md @@ -0,0 +1,371 @@ +

    NexT

    + +

    NexT is a high quality elegant Hexo theme. It is crafted from scratch, with love.

    + +[![gitter-image]][gitter-url] +[![mnt-image]](https://github.com/theme-next/hexo-theme-next) +[![travis-image]][travis-url] +[![rel-image]][releases-url] +[![hexo-image]][hexo-url] +[![lic-image]](LICENSE) + +* [Chinese Documentation](README.cn.md) + +## Live Preview + +* :heart_decoration: Muse scheme: [XiaMo](https://notes.wanghao.work) | [OAwan](https://oawan.me) | [Hui Wang](http://hui-wang.info) +* :six_pointed_star: Mist scheme: [Jeff](https://blog.zzbd.org) | [uchuhimo](http://uchuhimo.me) | [xirong](http://www.ixirong.com) +* :pisces: Pisces scheme: [Vi](http://notes.iissnan.com) | [Acris](https://acris.me) | [Rainy](https://rainylog.com) +* :gemini: Gemini scheme: [Ivan.Nginx](https://almostover.ru) | [Alynx](http://sh.alynx.xyz) | [Raincal](https://raincal.top) + +More NexT examples [here](https://github.com/iissnan/hexo-theme-next/issues/119). + +## Installation + +**1.** Change dir to **hexo root** directory. There must be `node_modules`, `source`, `themes` and other directories: + ```sh + $ cd hexo + $ ls + _config.yml node_modules package.json public scaffolds source themes + ``` + +**2.** Get theme from GitHub. There are several variants to do it: + +### Download [latest release version][releases-latest-url]. + At most cases **stable**. Recommended for most users. + + [![curl-tar-wget-image]][curl-tar-wget-url] + + ```sh + $ mkdir themes/next + $ curl -s https://api.github.com/repos/iissnan/hexo-theme-next/releases/latest | grep tarball_url | cut -d '"' -f 4 | wget -i - -O- | tar -zx -C themes/next --strip-components=1 + ``` + +### Download [tagged release version][releases-url]. + You must define version. Replace `v5.1.2` with any version from [tags list][tags-url]. + + [![curl-tar-image]][curl-tar-url] + + ```sh + $ mkdir themes/next + $ curl -L https://api.github.com/repos/iissnan/hexo-theme-next/tarball/v5.1.2 | tar -zxv -C themes/next --strip-components=1 + ``` + + [![git-image]][git-url] + + ```sh + $ git clone --branch v5.1.2 https://github.com/iissnan/hexo-theme-next themes/next + ``` + +### Download [latest master branch][download-latest-url]. + May be **unstable**, but includes latest features. Recommended for developers. + + [![curl-tar-image]][curl-tar-url] + + ```sh + $ mkdir themes/next + $ curl -L https://api.github.com/repos/iissnan/hexo-theme-next/tarball | tar -zxv -C themes/next --strip-components=1 + ``` + + [![git-image]][git-url] + + ```sh + $ git clone https://github.com/iissnan/hexo-theme-next themes/next + ``` + + Clone command will give you the **whole repository**. And in any time you can switch to any tagged release.\ + Get tags list: + + ```sh + $ cd themes/next + $ git tag -l + … + v5.0.0 + v5.0.1 + v5.1.0 + v5.1.1 + v5.1.2 + ``` + + For example, you want to switch on `v5.1.0` [tagged release version][tags-url]. Input the following command: + + ```sh + $ git checkout tags/v5.1.0 + Note: checking out 'tags/v5.1.0'. + … + HEAD now on 1f72f68... CSS: Remove global list-style setting of ul + ``` + + And if you want to switch back on [master branch][commits-url], input this command: + + ```sh + $ git checkout master + ``` + +**3.** Set theme in main **hexo root config** `_config.yml` file: + + theme: next + +### Bugs +For those who also encounter **Error: Cannot find module 'hexo-util'** [issue](https://github.com/iissnan/hexo-theme-next/issues/1490), please check your NPM version. + +- `> 3`: Still not work. Please remove `node_modules` directory and reinstall using `npm install`. +- `< 3`: Please add `hexo-util` explicitly via `npm install --save-dev hexo-util` to you site package deps. + +## Update + +```sh +$ cd themes/next +$ git pull +``` + +### Bugs + +> Commit your changes or stash them before you can merge + +You must Commit, Stash or Discard local changes. See [here](https://stackoverflow.com/a/15745424/5861495) how to do it. + +### Theme configurations using Hexo data files ([#328](https://github.com/iissnan/hexo-theme-next/issues/328)) + +Currently, it is not smooth to update NexT theme from pulling or downloading new releases. It is quite often running into conflict status when updating NexT theme via `git pull`, or need to merge configurations manually when upgrading to new releases. + + At present, NexT encourages users to store some options in site's `_config.yml` and other options in theme's `_config.yml`. This approach is applicable, but has some drawbacks: +1. Configurations are splited into two pieces +2. Users maybe confuse which place should be for options + +In order to resolve this issue, NexT will take advantage of Hexo [Data files](https://hexo.io/docs/data-files.html). Because Data files is introduced in Hexo 3, so you need upgrade Hexo to 3.0 (or above) to use this feature. + +If you prefer Hexo 2.x, you can still use the old approach for configurations. NexT is still compatible with Hexo 2.x. + +#### Benefits + +With this feature, now you can put all your configurations into one place (`source/_data/next.yml`), you don't need to touch `next/_config.yml`. If there are any new options in new releases, you just need to copy those options from `next/_config.yml`, paste into `_data/next.yml` and set their values to whatever you want. + +#### How to use this feature + +1. Please ensure you are using Hexo 3 (or above) +2. Create an file named `next.yml` in site's `source/_data` directory (create `_data` directory if it did not exist) +3. Copy NexT theme options both in site's `_config.yml` and theme's `_config.yml` into `next.yml`. +4. Use `--config source/_data/next.yml` parameter to start server, generate or deploy.\ + For example: `hexo clean --config source/_data/next.yml && hexo g --config source/_data/next.yml`. + +## Features + +### Multiple languages support, including: +:cn: Simplified Chinese & Traditional Chinese.
    +:us: English
    +:ru: Russian
    +:fr: French
    +:de: German
    +:jp: Japanese
    +:indonesia: Indonesian
    +:portugal: Portuguese (Brazil)
    +:kr: Korean
    +:it: Italian
    +:netherlands: Dutch
    +:vietnam: Vietnamese + +Default language is English. + +```yml +language: en +# language: zh-Hans +# language: zh-hk +# language: zh-tw +# language: ru +# language: fr-FR +# language: de +# language: ja +# language: id +# language: pt +# language: pt-BR +# language: ko +# language: it +# language: nl-NL +# language: vi +``` + +Set `language` field as following in site `_config.yml` to change to Chinese. + +```yml +language: zh-Hans +``` + +### Comment support. + +NexT has native support for `DuoShuo` and `Disqus` comment systems. + +Add the following snippets to your `_config.yml`: + +```yml +duoshuo: + enable: true + shortname: your-duoshuo-shortname +``` + +OR + +```yml +disqus_shortname: your-disqus-shortname +``` + +### Tags page. + +> Add a tags page contains all tags in your site. + +- Create a page named `tags` + + hexo new page "tags" + +- Edit tags page, set page type to `tags`. + + title: All tags + date: 2014-12-22 12:39:04 + type: "tags" + +- Add `tags` to theme `_config.yml`: + + menu: + home: / + archives: /archives + tags: /tags + +### Categories page. + +> Add a categories page contains all categories in your site. + +- Create a page named `categories` + + hexo new page "categories" + +- Edit categories page, set page type to `categories`. + + title: All categories + date: 2014-12-22 12:39:04 + type: "categories" + +- Add `categories` to theme `_config.yml`: + + menu: + home: / + archives: /archives + categories: /categories + +### Social Media + +NexT can automatically add links to your Social Media accounts: + +```yml +social: + GitHub: your-github-url + Twitter: your-twitter-url + Weibo: your-weibo-url + DouBan: your-douban-url + ZhiHu: your-zhihu-url +``` + +### Feed link. + +> Show a feed link. + +Set `rss` field in theme's `_config.yml`, as the following value: + +1. `rss: false` will totally disable feed link. +2. `rss: ` use sites' feed link. This is the default option. + + Follow the installation instruction in the plugin's README. After the configuration is done for this plugin, the feed link is ready too. + +3. `rss: http://your-feed-url` set specific feed link. + +### Up to 5 code highlight themes built-in. + +NexT uses [Tomorrow Theme](https://github.com/chriskempson/tomorrow-theme) with 5 themes for you to choose from. +Next use `normal` by default. Have a preview about `normal` and `night`: + +![Tomorrow Normal Preview](http://iissnan.com/nexus/next/tomorrow-normal.png) +![Tomorrow Night Preview](http://iissnan.com/nexus/next/tomorrow-night.png) + +Head over to [Tomorrow Theme](https://github.com/chriskempson/tomorrow-theme) for more details. + +## Configuration + +NexT comes with few configurations. + +```yml + +# Menu configuration. +menu: + home: / + archives: /archives + +# Favicon +favicon: /favicon.ico + +# Avatar (put the image into next/source/images/) +# can be any image format supported by web browsers (JPEG,PNG,GIF,SVG,..) +avatar: /default_avatar.png + +# Code highlight theme +# available: normal | night | night eighties | night blue | night bright +highlight_theme: normal + +# Fancybox for image gallery +fancybox: true + +# Specify the date when the site was setup +since: 2013 + +``` + +## Browser support + +![browser-image] + +[![Browser Stack](.github/browserstack_logo.png)](https://www.browserstack.com/) +>**BrowserStack** is a cloud-based cross-browser testing tool that enables developers to test their websites across various browsers on different operating systems and mobile devices, without requiring users to install virtual machines, devices or emulators. + +## Contributing + +Contribution is welcome, feel free to open an issue and fork. Waiting for your pull request. + + +[browser-image]: https://img.shields.io/badge/browser-%20chrome%20%7C%20firefox%20%7C%20opera%20%7C%20safari%20%7C%20ie%20%3E%3D%209-lightgrey.svg +[browser-url]: https://www.browserstack.com + +[gitter-image]: https://badges.gitter.im/Join%20Chat.svg +[gitter-url]: https://gitter.im/iissnan/hexo-theme-next?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge + +[travis-image]: https://travis-ci.org/iissnan/hexo-theme-next.svg?branch=master +[travis-url]: https://travis-ci.org/iissnan/hexo-theme-next?branch=master "Travis CI" + +[hexo-image]: https://img.shields.io/badge/hexo-%3E%3D%203.0-blue.svg +[hexo-url]: http://hexo.io + +[mnt-image]: https://img.shields.io/maintenance/yes/2017.svg +[rel-image]: https://img.shields.io/github/release/iissnan/hexo-theme-next.svg + +[lic-image]: https://img.shields.io/dub/l/vibe-d.svg + +[git-image]: https://img.shields.io/badge/install%20with%20-git-blue.svg +[curl-tar-image]: https://img.shields.io/badge/install%20with%20-curl%20%7C%20tar-blue.svg +[curl-tar-wget-image]: https://img.shields.io/badge/install%20with%20-curl%20%7C%20tar%20%7C%20wget-blue.svg +[git-url]: http://lmgtfy.com/?q=linux+git+install +[curl-tar-url]: http://lmgtfy.com/?q=linux+curl+tar+install +[curl-tar-wget-url]: http://lmgtfy.com/?q=linux+curl+tar+wget+install + +[download-latest-url]: https://github.com/iissnan/hexo-theme-next/archive/master.zip +[releases-latest-url]: https://github.com/iissnan/hexo-theme-next/releases/latest +[releases-url]: https://github.com/iissnan/hexo-theme-next/releases +[tags-url]: https://github.com/iissnan/hexo-theme-next/tags +[commits-url]: https://github.com/iissnan/hexo-theme-next/commits/master diff --git a/themes/next-5.1.4/_config.yml b/themes/next-5.1.4/_config.yml new file mode 100644 index 0000000..b86619e --- /dev/null +++ b/themes/next-5.1.4/_config.yml @@ -0,0 +1,813 @@ +# =============================================================== +# ========================= ATTENTION! ========================== +# =============================================================== +# NexT repository is moving here: https://github.com/theme-next +# =============================================================== +# It's rebase to v6.0.0 and future maintenance will resume there +# =============================================================== + +# --------------------------------------------------------------- +# Theme Core Configuration Settings +# --------------------------------------------------------------- + +# Set to true, if you want to fully override the default configuration. +# Useful if you don't want to inherit the theme _config.yml configurations. +override: false + +# --------------------------------------------------------------- +# Site Information Settings +# --------------------------------------------------------------- + +# To get or check favicons visit: https://realfavicongenerator.net +# Put your favicons into `hexo-site/source/` (recommend) or `hexo-site/themes/next/source/images/` directory. + +# Default NexT favicons placed in `hexo-site/themes/next/source/images/` directory. +# And if you want to place your icons in `hexo-site/source/` root directory, you must remove `/images` prefix from pathes. + +# For example, you put your favicons into `hexo-site/source/images` directory. +# Then need to rename & redefine they on any other names, otherwise icons from Next will rewrite your custom icons in Hexo. +favicon: + small: /images/favicon-16x16-next.png + medium: /images/favicon-32x32-next.png + apple_touch_icon: /images/apple-touch-icon-next.png + safari_pinned_tab: /images/logo.svg + #android_manifest: /images/manifest.json + #ms_browserconfig: /images/browserconfig.xml + +# Set default keywords (Use a comma to separate) +keywords: "Hexo, NexT" + +# Set rss to false to disable feed link. +# Leave rss as empty to use site's feed link. +# Set rss to specific value if you have burned your feed already. +rss: + +footer: + # Specify the date when the site was setup. + # If not defined, current year will be used. + #since: 2015 + + # Icon between year and copyright info. + icon: user + + # If not defined, will be used `author` from Hexo main config. + copyright: + # ------------------------------------------------------------- + # Hexo link (Powered by Hexo). + powered: true + + theme: + # Theme & scheme info link (Theme - NexT.scheme). + enable: true + # Version info of NexT after scheme info (vX.X.X). + version: true + # ------------------------------------------------------------- + # Any custom text can be defined here. + #custom_text: Hosted by GitHub Pages + +# --------------------------------------------------------------- +# SEO Settings +# --------------------------------------------------------------- + +# Canonical, set a canonical link tag in your hexo, you could use it for your SEO of blog. +# See: https://support.google.com/webmasters/answer/139066 +# Tips: Before you open this tag, remember set up your URL in hexo _config.yml ( ex. url: http://yourdomain.com ) +canonical: true + +# Change headers hierarchy on site-subtitle (will be main site description) and on all post/pages titles for better SEO-optimization. +seo: false + +# If true, will add site-subtitle to index page, added in main hexo config. +# subtitle: Subtitle +index_with_subtitle: false + + +# --------------------------------------------------------------- +# Menu Settings +# --------------------------------------------------------------- + +# When running the site in a subdirectory (e.g. domain.tld/blog), remove the leading slash from link value (/archives -> archives). +# Usage: `Key: /link/ || icon` +# Key is the name of menu item. If translate for this menu will find in languages - this translate will be loaded; if not - Key name will be used. Key is case-senstive. +# Value before `||` delimeter is the target link. +# Value after `||` delimeter is the name of FontAwesome icon. If icon (with or without delimeter) is not specified, question icon will be loaded. +menu: + home: / || home + #about: /about/ || user + tags: /tags/ || tags + categories: /categories/ || th + archives: /archives/ || archive + #schedule: /schedule/ || calendar + #sitemap: /sitemap.xml || sitemap + #commonweal: /404/ || heartbeat + +# Enable/Disable menu icons. +menu_icons: + enable: true + + +# --------------------------------------------------------------- +# Scheme Settings +# --------------------------------------------------------------- + +# Schemes +scheme: Gemini +#scheme: Mist +#scheme: Pisces +#scheme: Gemini + + +# --------------------------------------------------------------- +# Sidebar Settings +# --------------------------------------------------------------- + +# Social Links. +# Usage: `Key: permalink || icon` +# Key is the link label showing to end users. +# Value before `||` delimeter is the target permalink. +# Value after `||` delimeter is the name of FontAwesome icon. If icon (with or without delimeter) is not specified, globe icon will be loaded. +#social: + #GitHub: https://github.com/yourname || github + #E-Mail: mailto:yourname@gmail.com || envelope + #Google: https://plus.google.com/yourname || google + #Twitter: https://twitter.com/yourname || twitter + #FB Page: https://www.facebook.com/yourname || facebook + #VK Group: https://vk.com/yourname || vk + #StackOverflow: https://stackoverflow.com/yourname || stack-overflow + #YouTube: https://youtube.com/yourname || youtube + #Instagram: https://instagram.com/yourname || instagram + #Skype: skype:yourname?call|chat || skype + +social_icons: + enable: true + icons_only: false + transition: false + +# Blog rolls +links_icon: link +links_title: Links +links_layout: block +#links_layout: inline +#links: + #Title: http://example.com/ + +# Sidebar Avatar +# in theme directory(source/images): /images/avatar.gif +# in site directory(source/uploads): /uploads/avatar.gif +avatar: https://avatars2.githubusercontent.com/u/7332504?s=400&u=a3a4e327f64825ed221713053c243f2163ed26b9&v=4 + +# Table Of Contents in the Sidebar +toc: + enable: true + + # Automatically add list number to toc. + number: true + + # If true, all words will placed on next lines if header width longer then sidebar width. + wrap: false + +# Creative Commons 4.0 International License. +# http://creativecommons.org/ +# Available: by | by-nc | by-nc-nd | by-nc-sa | by-nd | by-sa | zero +#creative_commons: by-nc-sa +#creative_commons: + +sidebar: + # Sidebar Position, available value: left | right (only for Pisces | Gemini). + position: left + #position: right + + # Sidebar Display, available value (only for Muse | Mist): + # - post expand on posts automatically. Default. + # - always expand for all pages automatically + # - hide expand only when click on the sidebar toggle icon. + # - remove Totally remove sidebar including sidebar toggle. + display: post + #display: always + #display: hide + #display: remove + + # Sidebar offset from top menubar in pixels (only for Pisces | Gemini). + offset: 12 + + # Back to top in sidebar (only for Pisces | Gemini). + b2t: false + + # Scroll percent label in b2t button. + scrollpercent: false + + # Enable sidebar on narrow view (only for Muse | Mist). + onmobile: false + + +# --------------------------------------------------------------- +# Post Settings +# --------------------------------------------------------------- + +# Automatically scroll page to section which is under mark. +scroll_to_more: true + +# Automatically saving scroll position on each post/page in cookies. +save_scroll: false + +# Automatically excerpt description in homepage as preamble text. +excerpt_description: true + +# Automatically Excerpt. Not recommend. +# Please use in the post to control excerpt accurately. +auto_excerpt: + enable: true + length: 150 + +# Post meta display settings +post_meta: + item_text: true + created_at: true + updated_at: false + categories: true + +# Post wordcount display settings +# Dependencies: https://github.com/willin/hexo-wordcount +post_wordcount: + item_text: true + wordcount: false + min2read: false + totalcount: false + separated_meta: true + +# Wechat Subscriber +#wechat_subscriber: + #enabled: true + #qcode: /path/to/your/wechatqcode ex. /uploads/wechat-qcode.jpg + #description: ex. subscribe to my blog by scanning my public wechat account + +# Reward +#reward_comment: Donate comment here +#wechatpay: /images/wechatpay.jpg +#alipay: /images/alipay.jpg +#bitcoin: /images/bitcoin.png + +# Declare license on posts +post_copyright: + enable: false + license: CC BY-NC-SA 3.0 + license_url: https://creativecommons.org/licenses/by-nc-sa/3.0/ + + +# --------------------------------------------------------------- +# Misc Theme Settings +# --------------------------------------------------------------- + +# Reduce padding / margin indents on devices with narrow width. +mobile_layout_economy: false + +# Android Chrome header panel color ($black-deep). +android_chrome_color: "#222" + +# Custom Logo. +# !!Only available for Default Scheme currently. +# Options: +# enabled: [true/false] - Replace with specific image +# image: url-of-image - Images's url +custom_logo: + enabled: false + image: + +# Code Highlight theme +# Available value: +# normal | night | night eighties | night blue | night bright +# https://github.com/chriskempson/tomorrow-theme +highlight_theme: normal + + +# --------------------------------------------------------------- +# Font Settings +# - Find fonts on Google Fonts (https://www.google.com/fonts) +# - All fonts set here will have the following styles: +# light, light italic, normal, normal italic, bold, bold italic +# - Be aware that setting too much fonts will cause site running slowly +# - Introduce in 5.0.1 +# --------------------------------------------------------------- +# CAUTION! Safari Version 10.1.2 bug: https://github.com/iissnan/hexo-theme-next/issues/1844 +# To avoid space between header and sidebar in Pisces / Gemini themes recommended to use Web Safe fonts for `global` (and `logo`): +# Arial | Tahoma | Helvetica | Times New Roman | Courier New | Verdana | Georgia | Palatino | Garamond | Comic Sans MS | Trebuchet MS +# --------------------------------------------------------------- +font: + enable: false + + # Uri of fonts host. E.g. //fonts.googleapis.com (Default). + host: + + # Font options: + # `external: true` will load this font family from `host` above. + # `family: Times New Roman`. Without any quotes. + # `size: xx`. Use `px` as unit. + + # Global font settings used on element. + global: + external: true + family: Lato + size: + + # Font settings for Headlines (h1, h2, h3, h4, h5, h6). + # Fallback to `global` font settings. + headings: + external: true + family: + size: + + # Font settings for posts. + # Fallback to `global` font settings. + posts: + external: true + family: + + # Font settings for Logo. + # Fallback to `global` font settings. + logo: + external: true + family: + size: + + # Font settings for and code blocks. + codes: + external: true + family: + size: + + +# --------------------------------------------------------------- +# Third Party Services Settings +# --------------------------------------------------------------- + +# MathJax Support +mathjax: + enable: false + per_page: false + cdn: //cdn.bootcss.com/mathjax/2.7.1/latest.js?config=TeX-AMS-MML_HTMLorMML + +# Han Support docs: https://hanzi.pro/ +han: false + +# Swiftype Search API Key +#swiftype_key: + +# Baidu Analytics ID +baidu_analytics: e22181c41b28e5cfb1dda27dad0a5e6e + +# Duoshuo ShortName +#duoshuo_shortname: + +# Disqus +disqus: + enable: false + shortname: + count: true + +# Hypercomments +#hypercomments_id: + +# changyan +changyan: + enable: false + appid: + appkey: + + +# Valine. +# You can get your appid and appkey from https://leancloud.cn +# more info please open https://valine.js.org +valine: + enable: false + appid: # your leancloud application appid + appkey: # your leancloud application appkey + notify: false # mail notifier , https://github.com/xCss/Valine/wiki + verify: false # Verification code + placeholder: Just go go # comment box placeholder + avatar: mm # gravatar style + guest_info: nick,mail,link # custom comment header + pageSize: 10 # pagination size + + +# Support for youyan comments system. +# You can get your uid from http://www.uyan.cc +#youyan_uid: your uid + +# Support for LiveRe comments system. +# You can get your uid from https://livere.com/insight/myCode (General web site) +#livere_uid: your uid + +# Gitment +# Introduction: https://imsun.net/posts/gitment-introduction/ +# You can get your Github ID from https://api.github.com/users/ +gitment: + enable: true + mint: true # RECOMMEND, A mint on Gitment, to support count, language and proxy_gateway + count: true # Show comments count in post meta area + lazy: false # Comments lazy loading with a button + cleanly: false # Hide 'Powered by ...' on footer, and more + language: # Force language, or auto switch by theme + github_user: sslf # MUST HAVE, Your Github ID + github_repo: sslf.github.io # MUST HAVE, The repo you use to store Gitment comments + client_id: 76c17d044e0fef278057 # MUST HAVE, Github client id for the Gitment + client_secret: 0f102766c5ee9762bcac14d9a33e01d0d4ddafdb # EITHER this or proxy_gateway, Github access secret token for the Gitment + proxy_gateway: # Address of api proxy, See: https://github.com/aimingoo/intersect + redirect_protocol: # Protocol of redirect_uri with force_redirect_protocol when mint enabled + +# Baidu Share +# Available value: +# button | slide +# Warning: Baidu Share does not support https. +#baidushare: +## type: button + +# Share +# This plugin is more useful in China, make sure you known how to use it. +# And you can find the use guide at official webiste: http://www.jiathis.com/. +# Warning: JiaThis does not support https. +#jiathis: + ##uid: Get this uid from http://www.jiathis.com/ +#add_this_id: + +# Share +#duoshuo_share: true + +# NeedMoreShare2 +# This plugin is a pure javascript sharing lib which is useful in China. +# See: https://github.com/revir/need-more-share2 +# Also see: https://github.com/DzmVasileusky/needShareButton +# iconStyle: default | box +# boxForm: horizontal | vertical +# position: top / middle / bottom + Left / Center / Right +# networks: Weibo,Wechat,Douban,QQZone,Twitter,Linkedin,Mailto,Reddit, +# Delicious,StumbleUpon,Pinterest,Facebook,GooglePlus,Slashdot, +# Technorati,Posterous,Tumblr,GoogleBookmarks,Newsvine, +# Evernote,Friendfeed,Vkontakte,Odnoklassniki,Mailru +needmoreshare2: + enable: false + postbottom: + enable: false + options: + iconStyle: box + boxForm: horizontal + position: bottomCenter + networks: Weibo,Wechat,Douban,QQZone,Twitter,Facebook + float: + enable: false + options: + iconStyle: box + boxForm: horizontal + position: middleRight + networks: Weibo,Wechat,Douban,QQZone,Twitter,Facebook + +# Google Webmaster tools verification setting +# See: https://www.google.com/webmasters/ +#google_site_verification: + +# Google Analytics +#google_analytics: + +# Bing Webmaster tools verification setting +# See: https://www.bing.com/webmaster/ +#bing_site_verification: + +# Yandex Webmaster tools verification setting +# See: https://webmaster.yandex.ru/ +#yandex_site_verification: + +# CNZZ count +cnzz_siteid: 1262238490 + +# Application Insights +# See https://azure.microsoft.com/en-us/services/application-insights/ +# application_insights: + +# Make duoshuo show UA +# user_id must NOT be null when admin_enable is true! +# you can visit http://dev.duoshuo.com get duoshuo user id. +duoshuo_info: + ua_enable: true + admin_enable: false + user_id: 0 + #admin_nickname: Author + +# Post widgets & FB/VK comments settings. +# --------------------------------------------------------------- +# Facebook SDK Support. +# https://github.com/iissnan/hexo-theme-next/pull/410 +facebook_sdk: + enable: false + app_id: # + fb_admin: # + like_button: #true + webmaster: #true + +# Facebook comments plugin +# This plugin depends on Facebook SDK. +# If facebook_sdk.enable is false, Facebook comments plugin is unavailable. +facebook_comments_plugin: + enable: false + num_of_posts: 10 # min posts num is 1 + width: 100% # default width is 550px + scheme: light # default scheme is light (light or dark) + +# VKontakte API Support. +# To get your AppID visit https://vk.com/editapp?act=create +vkontakte_api: + enable: false + app_id: # + like: true + comments: true + num_of_posts: 10 + +# Star rating support to each article. +# To get your ID visit https://widgetpack.com +rating: + enable: false + id: # + color: fc6423 +# --------------------------------------------------------------- + +# Show number of visitors to each article. +# You can visit https://leancloud.cn get AppID and AppKey. +leancloud_visitors: + enable: true + app_id: DBTCLoQdLGuW27zR2cJlBGkl-gzGzoHsz # + app_key: 1yfdLbbm1zKgNpQnpLUAg49e # + +# Another tool to show number of visitors to each article. +# visit https://console.firebase.google.com/u/0/ to get apiKey and projectId +# visit https://firebase.google.com/docs/firestore/ to get more information about firestore +firestore: + enable: false + collection: articles #required, a string collection name to access firestore database + apiKey: #required + projectId: #required + bluebird: false #enable this if you want to include bluebird 3.5.1(core version) Promise polyfill + +# Show PV/UV of the website/page with busuanzi. +# Get more information on http://ibruce.info/2015/04/04/busuanzi/ +busuanzi_count: + # count values only if the other configs are false + enable: false + # custom uv span for the whole site + site_uv: true + site_uv_header: + site_uv_footer: + # custom pv span for the whole site + site_pv: true + site_pv_header: + site_pv_footer: + # custom pv span for one page only + page_pv: true + page_pv_header: + page_pv_footer: + + +# Tencent analytics ID +# tencent_analytics: + +# Tencent MTA ID +# tencent_mta: + + +# Enable baidu push so that the blog will push the url to baidu automatically which is very helpful for SEO +baidu_push: false + +# Google Calendar +# Share your recent schedule to others via calendar page +# +# API Documentation: +# https://developers.google.com/google-apps/calendar/v3/reference/events/list +calendar: + enable: false + calendar_id: + api_key: + orderBy: startTime + offsetMax: 24 + offsetMin: 4 + timeZone: + showDeleted: false + singleEvents: true + maxResults: 250 + +# Algolia Search +algolia_search: + enable: false + hits: + per_page: 10 + labels: + input_placeholder: Search for Posts + hits_empty: "We didn't find any results for the search: ${query}" + hits_stats: "${hits} results found in ${time} ms" + +# Local search +# Dependencies: https://github.com/flashlab/hexo-generator-search +local_search: + enable: false + # if auto, trigger search by changing input + # if manual, trigger search by pressing enter key or search button + trigger: auto + # show top n results per article, show all results by setting to -1 + top_n_per_article: 1 + + +# --------------------------------------------------------------- +# Tags Settings +# --------------------------------------------------------------- + +# External URL with BASE64 encrypt & decrypt. +# Usage: {% exturl text url "title" %} +# Alias: {% extlink text url "title" %} +exturl: false + +# Note tag (bs-callout). +note: + # Note tag style values: + # - simple bs-callout old alert style. Default. + # - modern bs-callout new (v2-v3) alert style. + # - flat flat callout style with background, like on Mozilla or StackOverflow. + # - disabled disable all CSS styles import of note tag. + style: simple + icons: false + border_radius: 3 + # Offset lighter of background in % for modern and flat styles (modern: -12 | 12; flat: -18 | 6). + # Offset also applied to label tag variables. This option can work with disabled note tag. + light_bg_offset: 0 + +# Label tag. +label: true + +# Tabs tag. +tabs: + enable: true + transition: + tabs: false + labels: true + border_radius: 0 + + +#! --------------------------------------------------------------- +#! DO NOT EDIT THE FOLLOWING SETTINGS +#! UNLESS YOU KNOW WHAT YOU ARE DOING +#! --------------------------------------------------------------- + +# Use velocity to animate everything. +motion: + enable: false + async: false + transition: + # Transition variants: + # fadeIn | fadeOut | flipXIn | flipXOut | flipYIn | flipYOut | flipBounceXIn | flipBounceXOut | flipBounceYIn | flipBounceYOut + # swoopIn | swoopOut | whirlIn | whirlOut | shrinkIn | shrinkOut | expandIn | expandOut + # bounceIn | bounceOut | bounceUpIn | bounceUpOut | bounceDownIn | bounceDownOut | bounceLeftIn | bounceLeftOut | bounceRightIn | bounceRightOut + # slideUpIn | slideUpOut | slideDownIn | slideDownOut | slideLeftIn | slideLeftOut | slideRightIn | slideRightOut + # slideUpBigIn | slideUpBigOut | slideDownBigIn | slideDownBigOut | slideLeftBigIn | slideLeftBigOut | slideRightBigIn | slideRightBigOut + # perspectiveUpIn | perspectiveUpOut | perspectiveDownIn | perspectiveDownOut | perspectiveLeftIn | perspectiveLeftOut | perspectiveRightIn | perspectiveRightOut + post_block: fadeIn + post_header: slideDownIn + post_body: slideDownIn + coll_header: slideLeftIn + # Only for Pisces | Gemini. + sidebar: slideUpIn + +# Fancybox +fancybox: true + +# Progress bar in the top during page loading. +pace: false +# Themes list: +#pace-theme-big-counter +#pace-theme-bounce +#pace-theme-barber-shop +#pace-theme-center-atom +#pace-theme-center-circle +#pace-theme-center-radar +#pace-theme-center-simple +#pace-theme-corner-indicator +#pace-theme-fill-left +#pace-theme-flash +#pace-theme-loading-bar +#pace-theme-mac-osx +#pace-theme-minimal +# For example +# pace_theme: pace-theme-center-simple +pace_theme: pace-theme-minimal + +# Canvas-nest +canvas_nest: false + +# three_waves +three_waves: false + +# canvas_lines +canvas_lines: false + +# canvas_sphere +canvas_sphere: false + +# Only fit scheme Pisces +# Canvas-ribbon +# size: The width of the ribbon. +# alpha: The transparency of the ribbon. +# zIndex: The display level of the ribbon. +canvas_ribbon: + enable: false + size: 300 + alpha: 0.6 + zIndex: -1 + +# Script Vendors. +# Set a CDN address for the vendor you want to customize. +# For example +# jquery: https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js +# Be aware that you should use the same version as internal ones to avoid potential problems. +# Please use the https protocol of CDN files when you enable https on your site. +vendors: + # Internal path prefix. Please do not edit it. + _internal: lib + + # Internal version: 2.1.3 + jquery: + + # Internal version: 2.1.5 + # See: http://fancyapps.com/fancybox/ + fancybox: + fancybox_css: + + # Internal version: 1.0.6 + # See: https://github.com/ftlabs/fastclick + fastclick: + + # Internal version: 1.9.7 + # See: https://github.com/tuupola/jquery_lazyload + lazyload: + + # Internal version: 1.2.1 + # See: http://VelocityJS.org + velocity: + + # Internal version: 1.2.1 + # See: http://VelocityJS.org + velocity_ui: + + # Internal version: 0.7.9 + # See: https://faisalman.github.io/ua-parser-js/ + ua_parser: + + # Internal version: 4.6.2 + # See: http://fontawesome.io/ + fontawesome: + + # Internal version: 1 + # https://www.algolia.com + algolia_instant_js: + algolia_instant_css: + + # Internal version: 1.0.2 + # See: https://github.com/HubSpot/pace + # Or use direct links below: + # pace: //cdn.bootcss.com/pace/1.0.2/pace.min.js + # pace_css: //cdn.bootcss.com/pace/1.0.2/themes/blue/pace-theme-flash.min.css + pace: + pace_css: + + # Internal version: 1.0.0 + # https://github.com/hustcc/canvas-nest.js + canvas_nest: + + # three + three: + + # three_waves + # https://github.com/jjandxa/three_waves + three_waves: + + # three_waves + # https://github.com/jjandxa/canvas_lines + canvas_lines: + + # three_waves + # https://github.com/jjandxa/canvas_sphere + canvas_sphere: + + # Internal version: 1.0.0 + # https://github.com/zproo/canvas-ribbon + canvas_ribbon: + + # Internal version: 3.3.0 + # https://github.com/ethantw/Han + han: + + # needMoreShare2 + # https://github.com/revir/need-more-share2 + needMoreShare2: + + +# Assets +css: css +js: js +images: images + +# Theme version +version: 5.1.4 diff --git a/themes/next-5.1.4/bower.json b/themes/next-5.1.4/bower.json new file mode 100644 index 0000000..d884845 --- /dev/null +++ b/themes/next-5.1.4/bower.json @@ -0,0 +1,37 @@ +{ + "name": "isn-next", + "version": "5.1.4", + "homepage": "https://github.com/iissnan/hexo-theme-next", + "authors": [ + "iissnan " + ], + "description": "Elegant theme for Hexo", + "repository": "https://github.com/iissnan/hexo-theme-next", + "keywords": [ + "hexo", + "notes", + "theme", + "iissnan", + "NexT" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "source/lib", + "test", + "tests", + "screenshots" + ], + "dependencies": { + "fancybox": "~2.1.5", + "velocity": "~1.2.1", + "jquery": "http://code.jquery.com/jquery-2.1.3.min.js", + "fastclick": "~1.0.6", + "font-awesome": "fontawesome#*", + "jquery_lazyload": "jquery.lazyload#~1.9.7", + "ua-parser-js": "~0.7.9", + "Han": "^3.3.0" + } +} diff --git a/themes/next-5.1.4/gulpfile.coffee b/themes/next-5.1.4/gulpfile.coffee new file mode 100644 index 0000000..c7d706b --- /dev/null +++ b/themes/next-5.1.4/gulpfile.coffee @@ -0,0 +1,54 @@ +fs = require('fs') +path = require('path') +gulp = require('gulp') +jshint = require('gulp-jshint') +stylish = require('jshint-stylish') +shell = require('gulp-shell') +yaml = require('js-yaml') + +gulp.task 'lint', -> + return gulp.src([ + './source/js/src/utils.js', + './source/js/src/motion.js', + './source/js/src/hook-duoshuo.js', + './source/js/src/algolia-search.js', + './source/js/src/bootstrap.js', + './source/js/src/post-details.js', + './source/js/src/schemes/pisces.js' + ]).pipe jshint() + .pipe jshint.reporter(stylish) + +gulp.task 'lint:stylus', shell.task [ + '"./node_modules/.bin/stylint" ./source/css/' +] + +gulp.task 'validate:config', (cb) -> + themeConfig = fs.readFileSync path.join(__dirname, '_config.yml') + + try + yaml.safeLoad(themeConfig) + cb() + catch error + cb new Error(error) + +gulp.task 'validate:languages', (cb) -> + languagesPath = path.join __dirname, 'languages' + languages = fs.readdirSync languagesPath + errors = [] + + for lang in languages + languagePath = path.join languagesPath, lang + try + yaml.safeLoad fs.readFileSync(languagePath), { + filename: path.relative(__dirname, languagePath) + } + catch error + errors.push error + + if errors.length == 0 + cb() + else + cb(errors) + + +gulp.task 'default', ['lint', 'validate:config', 'validate:languages'] diff --git a/themes/next-5.1.4/languages/de.yml b/themes/next-5.1.4/languages/de.yml new file mode 100644 index 0000000..8c74a69 --- /dev/null +++ b/themes/next-5.1.4/languages/de.yml @@ -0,0 +1,90 @@ +title: + archive: Archiv + category: Kategorie + tag: Tag + +author: Author + +menu: + home: Startseite + archives: Archiv + categories: Kategorien + tags: Tags + about: Über + feed: RSS + search: Suche + +sidebar: + overview: Übersicht + toc: Inhaltsverzeichnis + +post: + created: Post created + sticky: Sticky + posted: Veröffentlicht am + modified: Updated at + in: in + read_more: Weiterlesen + untitled: Unbenannt + toc_empty: Dieser Artikel hat kein Inhaltsverzeichnis + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Gesamt + tags: tags + +footer: + powered: "Erstellt mit %s" + theme: Theme + +counter: + tag_cloud: + zero: Keine Tags + one: Insgesamt ein Tag + other: "Insgesamt %d Tags" + + categories: + zero: Keine Kategorien + one: Insgesamt eine Kategorie + other: "Insgesamt %d Kategorien" + + archive_posts: + zero: Keine Artikel vorhanden. + one: Ein Artikel. + other: "Insgesamt %d Artikel." + +state: + posts: Artikel + pages: Seiten + tags: Tags + categories: Kategorien + +cheers: + um: Öhm.. + ok: OK + nice: Schön + good: Gut + great: Wunderbar + excellent: Exzellent + +keep_on: Bleib dran. + +symbol: + comma: '. ' + period: ', ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/default.yml b/themes/next-5.1.4/languages/default.yml new file mode 100644 index 0000000..b1fec61 --- /dev/null +++ b/themes/next-5.1.4/languages/default.yml @@ -0,0 +1,97 @@ +title: + archive: Archive + category: Category + tag: Tag + schedule: Schedule + +author: Author + +menu: + home: Home + archives: Archives + categories: Categories + tags: Tags + about: About + search: Search + schedule: Schedule + sitemap: Sitemap + commonweal: Commonweal 404 + +sidebar: + overview: Overview + toc: Table of Contents + +post: + created: Post created + modified: Post modified + sticky: Sticky + posted: Posted on + in: In + more: more + read_more: Read more + untitled: Untitled + toc_empty: This post does not have a Table of Contents + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Totally + tags: tags + +footer: + powered: "Powered by %s" + theme: Theme + +counter: + tag_cloud: + zero: No tags + one: 1 tag in total + other: "%d tags in total" + + categories: + zero: No categories + one: 1 category in total + other: "%d categories in total" + + archive_posts: + zero: No posts. + one: 1 post. + other: "%d posts in total." + +state: + posts: posts + pages: pages + tags: tags + categories: categories + +search: + placeholder: Searching... + +cheers: + um: Um.. + ok: OK + nice: Nice + good: Good + great: Great + excellent: Excellent + +keep_on: Keep on posting. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/en.yml b/themes/next-5.1.4/languages/en.yml new file mode 100644 index 0000000..37fe1db --- /dev/null +++ b/themes/next-5.1.4/languages/en.yml @@ -0,0 +1,99 @@ +title: + archive: Archive + category: Category + tag: Tag + schedule: Schedule + +author: Author + +menu: + home: Home + archives: Archives + categories: Categories + tags: Tags + about: About + search: Search + schedule: Schedule + sitemap: Sitemap + commonweal: Commonweal 404 + +sidebar: + overview: Overview + toc: Table of Contents + +post: + created: Post created + modified: Post modified + sticky: Sticky + posted: Posted on + in: In + more: more + read_more: Read more + untitled: Untitled + toc_empty: This post does not have a Table of Contents + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Totally + tags: tags + +footer: + powered: "Powered by %s" + theme: Theme + +counter: + tag_cloud: + zero: No tags + one: 1 tag in total + other: "%d tags in total" + + categories: + zero: No categories + one: 1 category in total + other: "%d categories in total" + + archive_posts: + zero: No posts. + one: 1 post. + other: "%d posts in total." + +state: + posts: posts + pages: pages + tags: tags + categories: categories + +search: + placeholder: Searching... + +cheers: + um: Um.. + ok: OK + nice: Nice + good: Good + great: Great + excellent: Excellent + +keep_on: Keep on posting. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin + +gitmentbutton: Show comments from Gitment diff --git a/themes/next-5.1.4/languages/fr-FR.yml b/themes/next-5.1.4/languages/fr-FR.yml new file mode 100644 index 0000000..6a3d2ae --- /dev/null +++ b/themes/next-5.1.4/languages/fr-FR.yml @@ -0,0 +1,88 @@ +title: + archive: Archive + category: Catégorie + tag: Tag + +author: Author + +menu: + home: Accueil + archives: Archives + categories: Categories + tags: Tags + about: A propos + search: recherche + +sidebar: + overview: Ensemble + toc: Table Des Matières + +post: + sticky: Sticky + posted: Posté le + modified: Updated at + in: In + read_more: Lire la suite + untitled: Non titré + toc_empty: This post does not have a Table of Contents + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Total + tags: tags + +footer: + powered: "Powered by %s" + theme: Thème + +counter: + tag_cloud: + zero: Aucun tags + one: 1 tag au total + other: "%d tags au total" + + categories: + zero: Aucun categories + one: 1 category au total + other: "%d categories au total" + + archive_posts: + zero: Aucun article. + one: 1 article. + other: "%d articles au total." + +state: + posts: articles + pages: pages + tags: tags + categories: categories + +cheers: + um: Um.. + ok: OK + nice: Jolie + good: Bien + great: Super + excellent: Excellent + +keep_on: Et ca ne fait que commencer. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/id.yml b/themes/next-5.1.4/languages/id.yml new file mode 100644 index 0000000..0e81fe4 --- /dev/null +++ b/themes/next-5.1.4/languages/id.yml @@ -0,0 +1,88 @@ +title: + archive: Arsip + category: Kategori + tag: Tag + +author: Penulis + +menu: + home: Beranda + archives: Arsip + categories: Kategori + tags: Tags + about: Tentang + search: Pencarian + +sidebar: + overview: Ikhtisar + toc: Daftar Isi + +post: + sticky: Sticky + posted: Diposting di + modified: Updated at + in: Di + read_more: Baca lebih + untitled: Tidak ada title + toc_empty: Posting ini tidak memiliki Daftar Isi + visitors: Pengunjung + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Total + tags: tags + +footer: + powered: "Powered by %s" + theme: Tema + +counter: + tag_cloud: + zero: Tidak ada tags + one: 1 total tag + other: "%d total tags" + + categories: + zero: Tidak ada kategori + one: 1 total categori + other: "%d total kategori" + + archive_posts: + zero: Tidak ada posting. + one: 1 posting. + other: "%d total posting." + +state: + posts: posting + pages: halaman + tags: tags + categories: kategori + +cheers: + um: Um.. + ok: OK + nice: Bagus + good: Bagus + great: Besar + excellent: Baik + +keep_on: Terus Posting. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/it.yml b/themes/next-5.1.4/languages/it.yml new file mode 100644 index 0000000..39aa40e --- /dev/null +++ b/themes/next-5.1.4/languages/it.yml @@ -0,0 +1,97 @@ +title: + archive: Archivio + category: Categoria + tag: Tag + schedule: Programma + +author: Autore + +menu: + home: Home + archives: Archivi + categories: Categorie + tags: Tags + about: Informazioni su + search: Cerca + schedule: Programma + sitemap: Sitemap + commonweal: Commonweal 404 + +sidebar: + overview: Panoramica + toc: Indice + +post: + created: Post creato + modified: Post modificato + sticky: Sticky + posted: Scritto il + in: In + more: espandi + read_more: Leggi di più + untitled: Senza titolo + toc_empty: Questo post non ha un indice + visitors: Visitatori + wordcount: Numero di parole nell'articolo + min2read: Tempo di lettura + totalcount: Numero totale di parole + copyright: + author: Autore + link: Link + license_title: Copyright + license_content: 'Tutti gli articoli in questo sito sono sotto licenza + %s salvo disposizione contraria.' + +page: + totally: Totale + tags: tags + +footer: + powered: "Powered by %s" + theme: Tema + +counter: + tag_cloud: + zero: Nessun tag + one: 1 tag in totale + other: "%d tags in totale." + + categories: + zero: Nessuna categoria + one: 1 categoria in totale + other: "%d categorie in totale." + + archive_posts: + zero: Nessun post. + one: 1 post. + other: "%d posts in totale." + +state: + posts: posts + pages: pagine + tags: tags + categories: categorie + +search: + placeholder: Cerca... + +cheers: + um: Mh.. + ok: OK + nice: Bello + good: Buono + great: Ottimo + excellent: Eccellente + +keep_on: Continua così. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Dona + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/ja.yml b/themes/next-5.1.4/languages/ja.yml new file mode 100644 index 0000000..990e5f2 --- /dev/null +++ b/themes/next-5.1.4/languages/ja.yml @@ -0,0 +1,88 @@ +title: + archive: アーカイブ + category: カテゴリ + tag: タグ + +author: Author + +menu: + home: ホーム + archives: アーカイブ + categories: カテゴリ + tags: タグ + about: About + search: 検索 + +sidebar: + overview: 概要 + toc: 見出し + +post: + sticky: 固定 + posted: 投稿日 + modified: Updated at + in: In + read_more: 続きを読む + untitled: 無題 + toc_empty: 見出しがありません + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: 全ページ + tags: タグ + +footer: + powered: "Powered by %s" + theme: Theme + +counter: + tag_cloud: + zero: タグなし + one: "全 1 タグ" + other: "全 %d タグ" + + categories: + zero: カテゴリなし + one: "全 1 カテゴリ" + other: "全 %d カテゴリ" + + archive_posts: + zero: ポストなし + one: "全 1 ポスト" + other: "全 %d ポスト" + +state: + posts: ポスト + pages: ページ + tags: タグ + categories: カテゴリ + +cheers: + um: うーん + ok: OK + nice: まあまあ + good: いいね + great: すごい + excellent: 最高 + +keep_on: もっと書こう! + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/ko.yml b/themes/next-5.1.4/languages/ko.yml new file mode 100644 index 0000000..df4e736 --- /dev/null +++ b/themes/next-5.1.4/languages/ko.yml @@ -0,0 +1,88 @@ +title: + archive: 아카이브 + category: 카테고리 + tag: 태그 + +author: 작성자 + +menu: + home: 홈 + archives: 아카이브 + categories: 카테고리 + tags: 태그 + about: About + search: 검색 + +sidebar: + overview: 흝어보기 + toc: 목차 + +post: + sticky: 고정 + posted: 작성일 + modified: Updated at + in: In + read_more: 더 읽어보기 + untitled: 제목 없음 + toc_empty: 목차 없음 + visitors: 방문객 + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: 모두 + tags: 태그 + +footer: + powered: "Powered by %s" + theme: Theme + +counter: + tag_cloud: + zero: 태그 없음 + one: 1개의 태그 + other: "총 %d개의 태그" + + categories: + zero: 카테고리 없음 + one: 1개의 카테고리 + other: "총 %d개의 카테고리" + + archive_posts: + zero: 포스트 없음 + one: 1개의 포스트 + other: "총 %d개의 포스트" + +state: + posts: 포스트 + pages: 페이지 + tags: 태그 + categories: 카테고리 + +cheers: + um: 음.. + ok: OK + nice: 잘했어요 + good: 좋아요 + great: 훌륭해요 + excellent: 완벽해요 + +keep_on: 포스트를 마저 작성하세요 + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/nl-NL.yml b/themes/next-5.1.4/languages/nl-NL.yml new file mode 100644 index 0000000..4acd836 --- /dev/null +++ b/themes/next-5.1.4/languages/nl-NL.yml @@ -0,0 +1,97 @@ +title: + archive: Archief + category: Categorie + tag: Label + schedule: Rooster + +author: Auteur + +menu: + home: Home + archives: Archieven + categories: Categorieën + tags: Labels + about: Over + search: Zoeken + schedule: Rooster + sitemap: Sitemap + commonweal: Gezond verstand 404 + +sidebar: + overview: Overzicht + toc: Inhoudsopgave + +post: + created: Post aangemaakt + modified: Post aangepast + sticky: Sticky + posted: Geplaatst op + in: In + more: meer + read_more: Lees meer + untitled: Naamloos + toc_empty: Deze post heeft geen inhoudsopgave + visitors: Bezoekers + wordcount: Aantal woorden in artikel + min2read: Leestijd + totalcount: Aantal woorden in site + copyright: + author: Post auteur + link: Post link + license_title: Copyright melding + license_content: 'Alle artikelen op deze blog zijn gelicenseerd onder + %s, mits niet anders aangegeven.' + +page: + totally: Totaal + tags: labels + +footer: + powered: "Mede mogelijk gemaakt door %s" + theme: Thema + +counter: + tag_cloud: + zero: Geen labels + one: 1 label in totaal + other: "%d labels in totaal" + + categories: + zero: Geen categorieën + one: 1 categorie in totaal + other: "%d categorieën in totaal" + + archive_posts: + zero: Geen posts. + one: 1 post. + other: "%d posts in totaal." + +state: + posts: posts + pages: pagina's + tags: labels + categories: categorieën + +search: + placeholder: Zoeken... + +cheers: + um: Um.. + ok: Oké + nice: Leuk + good: Goed + great: Geweldig + excellent: Uitstekend + +keep_on: Blijf posten. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Doneer + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/pt-BR.yml b/themes/next-5.1.4/languages/pt-BR.yml new file mode 100644 index 0000000..64f2da0 --- /dev/null +++ b/themes/next-5.1.4/languages/pt-BR.yml @@ -0,0 +1,88 @@ +title: + archive: Arquivo + category: Categoria + tag: Tag + +author: Autor + +menu: + home: Home + archives: Arquivos + categories: Categorias + tags: Tags + about: Sobre + search: Pesquisar + +sidebar: + overview: Visão geral + toc: Tabela de conteúdo + +post: + sticky: Sticky + posted: Postado em + modified: Updated at + in: Em + read_more: Leia mais + untitled: Sem título + toc_empty: Este post não possui tabela de conteúdo + visitors: Visitantes + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Totalmente + tags: tags + +footer: + powered: "Feito com %s" + theme: Tema + +counter: + tag_cloud: + zero: Sem tags + one: 1 tag no total de + other: "%d tags no total de" + + categories: + zero: Sem categoria + one: 1 categoria no total de + other: "%d categoria no total de" + + archive_posts: + zero: Sem posts. + one: 1 post. + other: "%d posts no total." + +state: + posts: Posts + pages: Páginas + tags: Tags + categories: Categorias + +cheers: + um: Uhmmmm... + ok: OK + nice: Bom + good: Muito Bom + great: Ótimo + excellent: Excelente + +keep_on: Continuar no post. + +symbol: + comma: '. ' + period: ', ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/pt.yml b/themes/next-5.1.4/languages/pt.yml new file mode 100644 index 0000000..9c83699 --- /dev/null +++ b/themes/next-5.1.4/languages/pt.yml @@ -0,0 +1,88 @@ +title: + archive: Arquivo + category: Categoria + tag: Tag + +author: Author + +menu: + home: Home + archives: Arquivos + categories: Categorias + tags: Tags + about: Sobre + search: Pesquisa + +sidebar: + overview: Visão Geral + toc: Tabela de Conteúdo + +post: + sticky: Sticky + posted: Postado em + modified: Updated at + in: Em + read_more: Ler mais + untitled: Sem título + toc_empty: Esta publicação não possui uma tabela de conteúdo + visitors: Visitors + wordcount: Words count in article + min2read: Reading time + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: Totalmente + tags: tags + +footer: + powered: "Desenvolvido com amor com %s" + theme: Tema + +counter: + tag_cloud: + zero: Sem tags + one: 1 tag no total + other: "%d tags no total" + + categories: + zero: Sem categorias + one: 1 categoria no total + other: "%d categorias no total" + + archive_posts: + zero: Sem publicações. + one: 1 post. + other: "%d publicações no total." + +state: + posts: publicações + pages: páginas + tags: tags + categories: categorias + +cheers: + um: Um.. + ok: OK + nice: Legal + good: Bom + great: Grandioso + excellent: Excelente + +keep_on: Mantenha-se publicando! + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Donate + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/ru.yml b/themes/next-5.1.4/languages/ru.yml new file mode 100644 index 0000000..55b6df1 --- /dev/null +++ b/themes/next-5.1.4/languages/ru.yml @@ -0,0 +1,105 @@ +title: + archive: Архив + category: Категория + tag: Тэг + schedule: Календарь + +author: Автор + +menu: + home: Главная + archives: Архив + categories: Категории + tags: Тэги + about: О сайте + search: Поиск + schedule: Календарь + sitemap: Карта сайта + +sidebar: + overview: Обзор + toc: Содержание + +post: + created: Дата создания записи + modified: Дата обновления записи + sticky: Ссылка + posted: Размещено + in: в категории + more: далее + read_more: Читать полностью + untitled: Без имени + toc_empty: Эта запись без оглавления + visitors: Просмотров + wordcount: Кол-во слов в статье + min2read: Время чтения в минутах + totalcount: Общее кол-во слов в записях + copyright: + author: Автор записи + link: Ссылка на запись + license_title: Информация об авторских правах + license_content: 'Все записи на этом сайте защищены лицензией + %s если не указано дополнительно.' + +page: + totally: Всего + tags: тэги + +footer: + powered: "Powered by %s" + theme: Theme + +counter: + tag_cloud: + zero: Нет тэгов. + one: 1 тэг. + two: "%d тэга всего." + three: "%d тэга всего." + four: "%d тэга всего." + other: "%d тэгов всего." + + categories: + zero: Нет категорий. + one: 1 категория. + two: "%d категории всего." + three: "%d категории всего." + four: "%d категории всего." + other: "%d категорий всего." + + archive_posts: + zero: Нет записей. + one: 1 запись. + two: "%d записи всего." + three: "%d записи всего." + four: "%d записи всего." + other: "%d записей всего." + +state: + posts: Архив + pages: Страницы + tags: Тэги + categories: Категории + +search: + placeholder: Поиск... + +cheers: + um: Эм.. + ok: OK + nice: Неплохо + good: Хорошо + great: Замечательно + excellent: Великолепно + +keep_on: Продолжаю писать. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Донат + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin diff --git a/themes/next-5.1.4/languages/vi.yml b/themes/next-5.1.4/languages/vi.yml new file mode 100644 index 0000000..1d46c26 --- /dev/null +++ b/themes/next-5.1.4/languages/vi.yml @@ -0,0 +1,99 @@ +title: + archive: Lưu Trữ + category: Phân Loại + tag: Thẻ + schedule: Danh Mục + +author: Tác giả + +menu: + home: Trang Chủ + archives: Lưu Trữ + categories: Đầu Mục + tags: Thẻ + about: Giới Thiệu + search: Tìm Kiếm + schedule: Danh Mục + sitemap: Bản đồ trang + commonweal: Commonweal 404 + +sidebar: + overview: Tổng Quan + toc: Mục Lục + +post: + created: Được tạo + modified: Được thay đổi + sticky: Đính + posted: Tạo lúc + in: Trong + more: thêm + read_more: Đọc tiếp + untitled: Không có tiêu đề + toc_empty: Bài viết này không có mục lục + visitors: Người xem + wordcount: Số từ trong bài viết + min2read: Thời gian đọc + totalcount: Số từ trong trang + copyright: + author: Người viết + link: Liên kết bài viết + license_title: Chú ý bản quyền + license_content: 'Tất cả bài viết trong blog này được đăng ký bởi + %s trừ khi có thông báo bổ sung.' + +page: + totally: Toàn bộ + tags: thẻ + +footer: + powered: "Cung cấp bởi %s" + theme: Giao Diện + +counter: + tag_cloud: + zero: Không có thẻ nào + one: có 1 thẻ tất cả + other: "có %d thẻ tất cả" + + categories: + zero: Không có trong mục nào + one: có 1 mục tất cả + other: "có %d mục tất cả" + + archive_posts: + zero: Không có bài viết. + one: 1 bài viết. + other: "tổng số %d bài viết." + +state: + posts: bài viết + pages: trang + tags: thẻ + categories: mục + +search: + placeholder: Đang tìm... + +cheers: + um: Um.. + ok: Đồng Ý + nice: Hay + good: Tốt + great: Tuyệt vời + excellent: Tuyệt cú mèo + +keep_on: Giữ tiến độ nha. + +symbol: + comma: ', ' + period: '. ' + colon: ':' + +reward: + donate: Tài trợ + wechatpay: WeChat Pay + alipay: Alipay + bitcoin: Bitcoin + +gitmentbutton: Hiển thị bình luận từ Gitment diff --git a/themes/next-5.1.4/languages/zh-Hans.yml b/themes/next-5.1.4/languages/zh-Hans.yml new file mode 100644 index 0000000..1159864 --- /dev/null +++ b/themes/next-5.1.4/languages/zh-Hans.yml @@ -0,0 +1,98 @@ +title: + archive: 归档 + category: 分类 + tag: 标签 + schedule: 日程表 + +author: 博主 + +menu: + home: 首页 + archives: 归档 + categories: 分类 + tags: 标签 + about: 关于 + search: 搜索 + schedule: 日程表 + sitemap: 站点地图 + commonweal: 公益404 + +sidebar: + overview: 站点概览 + toc: 文章目录 + +post: + created: 创建于 + modified: 更新于 + sticky: 置顶 + posted: 发表于 + in: 分类于 + read_more: 阅读全文 + untitled: 未命名 + toc_empty: 此文章未包含目录 + visitors: 阅读次数 + wordcount: 字数统计 + min2read: 阅读时长 + totalcount: Site words total count + copyright: + author: 本文作者 + link: 本文链接 + license_title: 版权声明 + license_content: '本博客所有文章除特别声明外,均采用 + %s 许可协议。转载请注明出处!' + +page: + totally: 共有 + tags: 标签 + +footer: + powered: "由 %s 强力驱动" + theme: 主题 + +counter: + tag_cloud: + zero: 暂无标签 + one: 目前共计 1 个标签 + other: "目前共计 %d 个标签" + + categories: + zero: 暂无分类 + one: 目前共计 1 个分类 + other: "目前共计 %d 个分类" + + archive_posts: + zero: 暂无日志。 + one: 目前共计 1 篇日志。 + other: "目前共计 %d 篇日志。" + +state: + posts: 日志 + pages: 页面 + tags: 标签 + categories: 分类 + +search: + placeholder: 搜索... + +cheers: + um: 嗯.. + ok: OK + nice: 好 + good: 很好 + great: 非常好 + excellent: 太棒了 + +keep_on: 继续努力。 + +symbol: + comma: ', ' + period: '。 ' + colon: ':' + +reward: + donate: 打赏 + wechatpay: 微信支付 + alipay: 支付宝 + bitcoin: 比特币 + +gitmentbutton: 显示 Gitment 评论 diff --git a/themes/next-5.1.4/languages/zh-hk.yml b/themes/next-5.1.4/languages/zh-hk.yml new file mode 100644 index 0000000..dddc1f3 --- /dev/null +++ b/themes/next-5.1.4/languages/zh-hk.yml @@ -0,0 +1,98 @@ +title: + archive: 歸檔 + category: 分類 + tag: 標籤 + schedule: 日程表 + +author: 博主 + +menu: + home: 首頁 + archives: 歸檔 + categories: 分類 + tags: 標籤 + about: 關於 + search: 檢索 + schedule: 日程表 + sitemap: 站點地圖 + commonweal: 公益404 + +sidebar: + overview: 本站概覽 + toc: 文章目錄 + +post: + created: 創建於 + modified: 更新於 + sticky: 置頂 + posted: 發表於 + in: 分類於 + read_more: 閱讀全文 + untitled: 未命名 + toc_empty: 此文章未包含目錄 + visitors: 閱讀次數 + wordcount: 字數統計 + min2read: 閱讀時長 + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: 共有 + tags: 標籤 + +footer: + powered: "由 %s 強力驅動" + theme: 主題 + +counter: + tag_cloud: + zero: 暫無標籤 + one: 目前共有 1 個標籤 + other: "目前共有 %d 個標籤" + + categories: + zero: 暫無分類 + one: 目前共有 1 個分類 + other: "目前共有 %d 個分類" + + archive_posts: + zero: 暫無文章。 + one: 目前共有 1 篇文章。 + other: "目前共有 %d 篇文章。" + +state: + posts: 文章 + pages: 頁面 + tags: 標籤 + categories: 分類 + +search: + placeholder: 搜索... + +cheers: + um: 嗯.. + ok: OK + nice: 好 + good: 很好 + great: 非常好 + excellent: 激爆好 + +keep_on: 繼續努力。 + +symbol: + comma: ', ' + period: '。 ' + colon: ':' + +reward: + donate: 打賞 + wechatpay: 微信支付 + alipay: 支付寶 + bitcoin: 比特幣 + +gitmentbutton: 顯示 Gitment 評論 diff --git a/themes/next-5.1.4/languages/zh-tw.yml b/themes/next-5.1.4/languages/zh-tw.yml new file mode 100644 index 0000000..1b87af5 --- /dev/null +++ b/themes/next-5.1.4/languages/zh-tw.yml @@ -0,0 +1,98 @@ +title: + archive: 歸檔 + category: 分類 + tag: 標籤 + schedule: 日程表 + +author: 博主 + +menu: + home: 首頁 + archives: 歸檔 + categories: 分類 + tags: 標籤 + about: 關於 + search: 檢索 + schedule: 日程表 + sitemap: 站點地圖 + commonweal: 公益404 + +sidebar: + overview: 本站概覽 + toc: 文章目錄 + +post: + created: 創建於 + modified: 更新於 + sticky: 置頂 + posted: 發表於 + in: 分類於 + read_more: 閱讀全文 + untitled: 未命名 + toc_empty: 此文章未包含目錄 + visitors: 閱讀次數 + wordcount: 字數統計 + min2read: 閱讀時長 + totalcount: Site words total count + copyright: + author: Post author + link: Post link + license_title: Copyright Notice + license_content: 'All articles in this blog are licensed under + %s unless stating additionally.' + +page: + totally: 共有 + tags: 標籤 + +footer: + powered: "由 %s 強力驅動" + theme: 主題 + +counter: + tag_cloud: + zero: 暫無標籤 + one: 目前共計 1 個標籤 + other: "目前共計 %d 個標籤" + + categories: + zero: 暫無分類 + one: 目前共計 1 個分類 + other: "目前共計 %d 個分類" + + archive_posts: + zero: 暫無文章。 + one: 目前共計 1 篇文章。 + other: "目前共計 %d 篇文章。" + +state: + posts: 文章 + pages: 頁面 + tags: 標籤 + categories: 分類 + +search: + placeholder: 搜索... + +cheers: + um: 嗯.. + ok: OK + nice: 好 + good: 很好 + great: 非常好 + excellent: 非常屌 + +keep_on: 繼續努力。 + +symbol: + comma: ', ' + period: '。 ' + colon: ':' + +reward: + donate: 打賞 + wechatpay: 微信支付 + alipay: 支付寶 + bitcoin: 比特幣 + +gitmentbutton: 顯示 Gitment 評論 diff --git a/themes/next-5.1.4/layout/_custom/header.swig b/themes/next-5.1.4/layout/_custom/header.swig new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/themes/next-5.1.4/layout/_custom/header.swig @@ -0,0 +1 @@ + diff --git a/themes/next-5.1.4/layout/_custom/sidebar.swig b/themes/next-5.1.4/layout/_custom/sidebar.swig new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/themes/next-5.1.4/layout/_custom/sidebar.swig @@ -0,0 +1 @@ + diff --git a/themes/next-5.1.4/layout/_layout.swig b/themes/next-5.1.4/layout/_layout.swig new file mode 100644 index 0000000..9b52671 --- /dev/null +++ b/themes/next-5.1.4/layout/_layout.swig @@ -0,0 +1,92 @@ + + +{% set html_class = 'theme-next ' + theme.scheme %} +{% if theme.motion.enable %} + {% set html_class = html_class + ' use-motion' %} +{% endif %} + + + + {% include '_partials/head.swig' %} + {% block title %}{% endblock %} + {% include '_third-party/analytics/index.swig' %} + + + + + {% set container_class = "container " %} + {% if theme.sidebar.position %} + {% set container_class = container_class + 'sidebar-position-' + theme.sidebar.position %} + {% endif %} + +
    +
    + + + +
    +
    +
    +
    + {% block content %}{% endblock %} +
    + {% include '_third-party/duoshuo-hot-articles.swig' %} + {% include '_partials/comments.swig' %} +
    + {% if theme.sidebar.display !== 'remove' %} + {% block sidebar %}{% endblock %} + {% endif %} +
    +
    + +
    + +
    + + {% if not theme.sidebar.b2t %} +
    + + {% if theme.sidebar.scrollpercent %} + 0% + {% endif %} +
    + {% endif %} + + {% if theme.needmoreshare2.enable and theme.needmoreshare2.float.enable %} +
    + + + +
    + {% endif %} + +
    + + {% include '_scripts/vendors.swig' %} + {% include '_scripts/commons.swig' %} + + {% set scheme_script = '_scripts/schemes/' + theme.scheme | lower + '.swig' %} + {% include scheme_script %} + + {% block script_extra %}{% endblock %} + + {% include '_scripts/boostrap.swig' %} + + {% include '_third-party/comments/index.swig' %} + {% include '_third-party/search/index.swig' %} + {% include '_third-party/analytics/lean-analytics.swig' %} + {% include '_third-party/analytics/firestore.swig' %} + {% include '_third-party/seo/baidu-push.swig' %} + {% include '_third-party/needsharebutton.swig' %} + {% include '_third-party/rating.swig' %} + {% include '_third-party/mathjax.swig' %} + {% include '_third-party/scroll-cookie.swig' %} + {% include '_third-party/exturl.swig' %} + + diff --git a/themes/next-5.1.4/layout/_macro/post-collapse.swig b/themes/next-5.1.4/layout/_macro/post-collapse.swig new file mode 100644 index 0000000..1894d24 --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/post-collapse.swig @@ -0,0 +1,34 @@ +{% macro render(post) %} + + + +{% endmacro %} diff --git a/themes/next-5.1.4/layout/_macro/post-copyright.swig b/themes/next-5.1.4/layout/_macro/post-copyright.swig new file mode 100644 index 0000000..4ad0490 --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/post-copyright.swig @@ -0,0 +1,14 @@ +
      +
    • + {{ __('post.copyright.author') + __('symbol.colon') }} + {{ post.author | default(config.author) }} +
    • +
    • + {{ __('post.copyright.link') + __('symbol.colon') }} + {{ post.url | default(post.permalink) }} +
    • +
    • + {{ __('post.copyright.license_title') + __('symbol.colon') }} + {{ __('post.copyright.license_content', theme.post_copyright.license_url, theme.post_copyright.license) }} +
    • +
    diff --git a/themes/next-5.1.4/layout/_macro/post.swig b/themes/next-5.1.4/layout/_macro/post.swig new file mode 100644 index 0000000..12a6d58 --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/post.swig @@ -0,0 +1,436 @@ +{% macro render(post, is_index, post_extra_class) %} + + {% set headlessPost = Array.prototype.indexOf.call(['quote', 'picture'], post.type) > -1 %} + + {% set post_class = 'post post-type-' + post.type | default('normal') %} + {% if post_extra_class > 0 %} + {% set post_class = post_class + ' ' + post_extra_class | default('') %} + {% endif %} + {% if post.sticky > 0 %} + {% set post_class = post_class + ' ' + 'post-sticky' %} + {% endif %} + +
    + {##################} + {### POST BLOCK ###} + {##################} +
    + + + + + + + {% if not headlessPost %} +
    + + {# Not to show title for quote posts that do not have a title #} + {% if not (is_index and post.type === 'quote' and not post.title) %} + <{% if theme.seo %}h2{% else %}h1{% endif %} class="post-title{% if post.direction && post.direction.toLowerCase() === 'rtl' %} rtl{% endif %}" itemprop="name headline">{# + #}{# Link posts #}{# + #}{% if post.link %} + {% if post.sticky > 0 %} + {{ post.sticky }} + + + + {% endif %} + + {% else %}{# + #}{% if is_index %} + {% if post.sticky > 0 %} + + + + {% endif %} + {# + #}{% else %}{{ post.title }}{% endif %}{# + #}{% endif %}{# + #} + {% endif %} + + +
    + {% endif %} + + {#################} + {### POST BODY ###} + {#################} +
    + + {# Gallery support #} + {% if post.photos and post.photos.length %} +
    + {% set COLUMN_NUMBER = 3 %} + {% for photo in post.photos %} + {% if loop.index0 % COLUMN_NUMBER === 0 %}
    {% endif %} + + {% if loop.index0 % COLUMN_NUMBER === 2 %}
    {% endif %} + {% endfor %} + + {# Append end tag for `post-gallery-row` when (photos size mod COLUMN_NUMBER) is less than COLUMN_NUMBER #} + {% if post.photos.length % COLUMN_NUMBER > 0 %}
    {% endif %} +
    + {% endif %} + + {% if is_index %} + {% if post.description and theme.excerpt_description %} + {{ post.description }} + +
    + + {{ __('post.read_more') }} » + +
    + + {% elif post.excerpt %} + {{ post.excerpt }} + +
    + + {{ __('post.read_more') }} » + +
    + + {% elif theme.auto_excerpt.enable %} + {% set content = post.content | striptags %} + {{ content.substring(0, theme.auto_excerpt.length) }} + {% if content.length > theme.auto_excerpt.length %}...{% endif %} + +
    + + {{ __('post.read_more') }} » + +
    + + {% else %} + {% if post.type === 'picture' %} + {{ post.content }} + {% else %} + {{ post.content }} + {% endif %} + {% endif %} + {% else %} + {{ post.content }} + {% endif %} +
    + {#####################} + {### END POST BODY ###} + {#####################} + + {% if theme.wechat_subscriber.enabled and not is_index %} +
    + {% include 'wechat-subscriber.swig' %} +
    + {% endif %} + + {% if (theme.alipay or theme.wechatpay or theme.bitcoin) and not is_index %} +
    + {% include 'reward.swig' %} +
    + {% endif %} + + {% if theme.post_copyright.enable and not is_index %} +
    + {% include 'post-copyright.swig' with { post: post } %} +
    + {% endif %} + +
    + {% if post.tags and post.tags.length and not is_index %} + + {% endif %} + + {% if not is_index %} + {% if theme.rating.enable or (theme.vkontakte_api.enable and theme.vkontakte_api.like) or (theme.facebook_sdk.enable and theme.facebook_sdk.like_button) or (theme.needmoreshare2.enable and theme.needmoreshare2.postbottom.enable) %} +
    + {% if theme.rating.enable %} +
    +
    +
    + {% endif %} + + {% if (theme.vkontakte_api.enable and theme.vkontakte_api.like) or (theme.facebook_sdk.enable and theme.facebook_sdk.like_button) %} + + {% endif %} + + {% if theme.needmoreshare2.enable and theme.needmoreshare2.postbottom.enable %} + {% if (theme.vkontakte_api.enable and theme.vkontakte_api.like) or (theme.facebook_sdk.enable and theme.facebook_sdk.like_button) %} + + {% endif %} +
    + + + +
    + {% endif %} +
    + {% endif %} + {% endif %} + + {% if not is_index and (post.prev or post.next) %} +
    +
    + {% if post.next %} + + {% endif %} +
    + + + +
    + {% if post.prev %} + + {% endif %} +
    +
    + {% endif %} + + {% set isLast = loop.index % page.per_page === 0 %} + {% if is_index and not isLast %} +
    + {% endif %} +
    +
    + {######################} + {### END POST BLOCK ###} + {######################} + + +{% endmacro %} diff --git a/themes/next-5.1.4/layout/_macro/reward.swig b/themes/next-5.1.4/layout/_macro/reward.swig new file mode 100644 index 0000000..268436e --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/reward.swig @@ -0,0 +1,30 @@ +
    +
    {{ theme.reward_comment }}
    + + +
    diff --git a/themes/next-5.1.4/layout/_macro/sidebar.swig b/themes/next-5.1.4/layout/_macro/sidebar.swig new file mode 100644 index 0000000..8f1229a --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/sidebar.swig @@ -0,0 +1,175 @@ +{% macro render(is_post) %} + + + +{% endmacro %} diff --git a/themes/next-5.1.4/layout/_macro/wechat-subscriber.swig b/themes/next-5.1.4/layout/_macro/wechat-subscriber.swig new file mode 100644 index 0000000..b1d4364 --- /dev/null +++ b/themes/next-5.1.4/layout/_macro/wechat-subscriber.swig @@ -0,0 +1,4 @@ +
    + {{ theme.author }} wechat +
    {{ theme.wechat_subscriber.description }}
    +
    diff --git a/themes/next-5.1.4/layout/_partials/comments.swig b/themes/next-5.1.4/layout/_partials/comments.swig new file mode 100644 index 0000000..cee3114 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/comments.swig @@ -0,0 +1,70 @@ +{% if page.comments %} + + {% if (theme.duoshuo and theme.duoshuo.shortname) or theme.duoshuo_shortname %} +
    +
    +
    +
    + + {% elseif theme.facebook_sdk.enable and theme.facebook_comments_plugin.enable %} +
    +
    +
    +
    + + {% elseif theme.vkontakte_api.enable and theme.vkontakte_api.comments %} +
    +
    +
    + + {% elseif theme.disqus.enable %} +
    +
    + +
    +
    + + {% elseif theme.hypercomments_id %} +
    +
    +
    + + {% elseif theme.youyan_uid %} +
    +
    +
    + + {% elseif theme.livere_uid %} +
    +
    +
    + + {% elseif theme.changyan.appid and theme.changyan.appkey %} +
    +
    +
    + + {% elseif theme.gitment.enable %} +
    + {% if theme.gitment.lazy %} +
    {{ __('gitmentbutton') }}
    + + {% else %} +
    + {% endif %} +
    + + {% elseif theme.valine.appid and theme.valine.appkey %} +
    +
    + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_partials/footer.swig b/themes/next-5.1.4/layout/_partials/footer.swig new file mode 100644 index 0000000..68e7e5e --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/footer.swig @@ -0,0 +1,47 @@ + + +{% if theme.footer.powered %} +
    {# + #}{{ __('footer.powered', 'Hexo') }}{# +#}
    +{% endif %} + +{% if theme.footer.powered and theme.footer.theme.enable %} + +{% endif %} + +{% if theme.footer.theme.enable %} +
    {# + #}{{ __('footer.theme') }} — {# + #}{# + #}NexT.{{ theme.scheme }}{# + #}{% if theme.footer.theme.version %} v{{ theme.version }}{% endif %}{# +#}
    +{% endif %} + +{% if theme.footer.custom_text %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_partials/head.swig b/themes/next-5.1.4/layout/_partials/head.swig new file mode 100644 index 0000000..1e03db6 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/head.swig @@ -0,0 +1,158 @@ + + + + + + +{% if theme.pace %} + {% set pace_css_uri = url_for(theme.vendors._internal + '/pace/'+ theme.pace_theme +'.min.css?v=1.0.2') %} + {% set pace_js_uri = url_for(theme.vendors._internal + '/pace/pace.min.js?v=1.0.2') %} + {% if theme.vendors.pace %} + {% set pace_js_uri = theme.vendors.pace %} + {% endif %} + {% if theme.vendors.pace_css %} + {% set pace_css_uri = theme.vendors.pace_css %} + {% endif %} + + +{% endif %} + + +{% if theme.han %} + {% set Han_uri = url_for(theme.vendors._internal + '/Han/dist/han.min.css?v=3.3') %} + {% if theme.vendors.Han %} + {% set Han_uri = theme.vendors.Han %} + {% endif %} + +{% endif %} + + +{# #238, Disable Baidu tranformation #} + + + + +{% if theme.google_site_verification %} + +{% endif %} + +{% if theme.bing_site_verification %} + +{% endif %} + +{% if theme.yandex_site_verification %} + +{% endif %} + + +{% if theme.baidu_site_verification %} + +{% endif %} + + +{% if theme.qihu_site_verification %} + +{% endif %} + + +{% if theme.fancybox %} + {% set fancybox_css_uri = url_for(theme.vendors._internal + '/fancybox/source/jquery.fancybox.css?v=2.1.5') %} + {% if theme.vendors.fancybox_css %} + {% set fancybox_css_uri = theme.vendors.fancybox_css %} + {% endif %} + +{% endif %} + +{% include "./head/external-fonts.swig" %} + +{% set font_awesome_uri = url_for(theme.vendors._internal + '/font-awesome/css/font-awesome.min.css?v=4.6.2') %} +{% if theme.vendors.fontawesome %} + {% set font_awesome_uri = theme.vendors.fontawesome %} +{% endif %} + + + + +{% if theme.favicon.apple_touch_icon %} + +{% endif %} +{% if theme.favicon.medium %} + +{% endif %} +{% if theme.favicon.small %} + +{% endif %} +{% if theme.favicon.safari_pinned_tab %} + +{% endif %} +{% if theme.favicon.android_manifest %} + +{% endif %} +{% if theme.favicon.ms_browserconfig %} + +{% endif %} + +{% if page.keywords %} + +{% elif page.tags and page.tags.length %} + +{% elif theme.keywords %} + +{% endif %} + + +{% if theme.rss === '' and config.feed and config.feed.path %} + {% set theme.rss = config.feed.path %} +{% endif %} +{% if theme.rss %} + +{% endif %} + + +{% if theme.facebook_sdk.enable and theme.facebook_sdk.webmaster %} + + +{% endif %} + + +{{ + open_graph({ + twitter_id: theme.twitter, + google_plus: theme.google_plus, + fb_admins: theme.fb_admins, + fb_app_id: theme.fb_app_id + }) +}} + + +{# Export some HEXO Configurations to Front-End #} + + +{# Canonical, good for google search engine (SEO) : https://support.google.com/webmasters/answer/139066 #} +{% if theme.canonical %} + +{% endif %} + +{% include 'head/custom-head.swig' %} diff --git a/themes/next-5.1.4/layout/_partials/head/custom-head.swig b/themes/next-5.1.4/layout/_partials/head/custom-head.swig new file mode 100644 index 0000000..6aed40d --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/head/custom-head.swig @@ -0,0 +1,3 @@ +{# +Custom head. +#} diff --git a/themes/next-5.1.4/layout/_partials/head/external-fonts.swig b/themes/next-5.1.4/layout/_partials/head/external-fonts.swig new file mode 100644 index 0000000..876e12e --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/head/external-fonts.swig @@ -0,0 +1,51 @@ +{% if theme.font.enable %} + + {% set font_config = theme.font %} + {% set font_families = '' %} + {% set font_styles = ':300,300italic,400,400italic,700,700italic' %} + {% set font_found = false %} + + {% if font_config.global.family and font_config.global.external %} + {% set font_families += font_config.global.family + font_styles %} + {% set font_found = true %} + {% endif %} + + {% if font_config.headings.family and font_config.headings.external %} + {% if font_found %} + {% set font_families += '|' %} + {% endif %} + + {% set font_families += font_config.headings.family + font_styles %} + {% endif %} + + {% if font_config.posts.family and font_config.posts.external %} + {% if font_found %} + {% set font_families += '|' %} + {% endif %} + + {% set font_families += font_config.posts.family + font_styles %} + {% endif %} + + {% if font_config.logo.family and font_config.logo.external %} + {% if font_found %} + {% set font_families += '|' %} + {% endif %} + + {% set font_families += font_config.logo.family + font_styles %} + {% endif %} + + {% if font_config.codes.family and font_config.codes.external %} + {% if font_found %} + {% set font_families += '|' %} + {% endif %} + + {% set font_families += font_config.codes.family + font_styles %} + {% endif %} + + {% if font_families !== '' %} + {% set font_families += '&subset=latin,latin-ext' %} + {% set font_host = font_config.host | default('//fonts.googleapis.com') %} + + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_partials/header.swig b/themes/next-5.1.4/layout/_partials/header.swig new file mode 100644 index 0000000..81d5d74 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/header.swig @@ -0,0 +1,76 @@ +
    +
    + {% if theme.custom_logo.image and theme.scheme === 'Muse' %} +
    + + {{ config.title }} + +
    + {% endif %} + + + {% if theme.seo %} +

    {{ config.subtitle }}

    + {% else %} +

    {{ config.subtitle }}

    + {% endif %} +
    + + +
    + + + +{% include '../_custom/header.swig' %} diff --git a/themes/next-5.1.4/layout/_partials/page-header.swig b/themes/next-5.1.4/layout/_partials/page-header.swig new file mode 100644 index 0000000..1e1f890 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/page-header.swig @@ -0,0 +1,11 @@ +
    + + <{% if theme.seo %}h2{% else %}h1{% endif %} class="post-title" itemprop="name headline">{{ page.title }} + +{% if page.description %} + +{% endif %} + +
    diff --git a/themes/next-5.1.4/layout/_partials/pagination.swig b/themes/next-5.1.4/layout/_partials/pagination.swig new file mode 100644 index 0000000..5f96b99 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/pagination.swig @@ -0,0 +1,11 @@ +{% if page.prev or page.next %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_partials/search.swig b/themes/next-5.1.4/layout/_partials/search.swig new file mode 100644 index 0000000..a507d27 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/search.swig @@ -0,0 +1,9 @@ +{% if theme.algolia_search.enable %} + {% include '../_third-party/search/algolia-search/dom.swig' %} +{% elseif theme.swiftype_key %} + {% include 'search/swiftype.swig' %} +{% elseif theme.tinysou_Key %} + {% include 'search/tinysou.swig' %} +{% elseif theme.local_search.enable %} + {% include 'search/localsearch.swig' %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_partials/search/localsearch.swig b/themes/next-5.1.4/layout/_partials/search/localsearch.swig new file mode 100644 index 0000000..f106aa0 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/search/localsearch.swig @@ -0,0 +1,16 @@ + diff --git a/themes/next-5.1.4/layout/_partials/search/swiftype.swig b/themes/next-5.1.4/layout/_partials/search/swiftype.swig new file mode 100644 index 0000000..732e0c1 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/search/swiftype.swig @@ -0,0 +1,12 @@ +
    + +
    + + diff --git a/themes/next-5.1.4/layout/_partials/search/tinysou.swig b/themes/next-5.1.4/layout/_partials/search/tinysou.swig new file mode 100644 index 0000000..2dfa3e3 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/search/tinysou.swig @@ -0,0 +1,3 @@ +
    + +
    diff --git a/themes/next-5.1.4/layout/_partials/share/add-this.swig b/themes/next-5.1.4/layout/_partials/share/add-this.swig new file mode 100644 index 0000000..ae0a6b4 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/share/add-this.swig @@ -0,0 +1,4 @@ + +
    + +
    diff --git a/themes/next-5.1.4/layout/_partials/share/baidushare.swig b/themes/next-5.1.4/layout/_partials/share/baidushare.swig new file mode 100644 index 0000000..6be4898 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/share/baidushare.swig @@ -0,0 +1,57 @@ +{% if theme.baidushare.type === "button" %} +
    + + + + + + + + + + +
    + +{% elseif theme.baidushare.type === "slide" %} + +{% endif %} + diff --git a/themes/next-5.1.4/layout/_partials/share/duoshuo_share.swig b/themes/next-5.1.4/layout/_partials/share/duoshuo_share.swig new file mode 100644 index 0000000..bfa26f4 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/share/duoshuo_share.swig @@ -0,0 +1,18 @@ +
    +
    + +
    +
    +
    +
    \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_partials/share/jiathis.swig b/themes/next-5.1.4/layout/_partials/share/jiathis.swig new file mode 100644 index 0000000..3251352 --- /dev/null +++ b/themes/next-5.1.4/layout/_partials/share/jiathis.swig @@ -0,0 +1,25 @@ + + + + + \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_scripts/boostrap.swig b/themes/next-5.1.4/layout/_scripts/boostrap.swig new file mode 100644 index 0000000..5e95090 --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/boostrap.swig @@ -0,0 +1,9 @@ +{% + set boot_scripts = [ + 'src/bootstrap.js' + ] +%} + +{% for bs in boot_scripts %} + +{% endfor %} diff --git a/themes/next-5.1.4/layout/_scripts/commons.swig b/themes/next-5.1.4/layout/_scripts/commons.swig new file mode 100644 index 0000000..abc2971 --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/commons.swig @@ -0,0 +1,10 @@ +{% + set js_commons = [ + 'src/utils.js', + 'src/motion.js' + ] +%} + +{% for common in js_commons %} + +{% endfor %} diff --git a/themes/next-5.1.4/layout/_scripts/pages/post-details.swig b/themes/next-5.1.4/layout/_scripts/pages/post-details.swig new file mode 100644 index 0000000..6938779 --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/pages/post-details.swig @@ -0,0 +1,2 @@ + + diff --git a/themes/next-5.1.4/layout/_scripts/schemes/gemini.swig b/themes/next-5.1.4/layout/_scripts/schemes/gemini.swig new file mode 100644 index 0000000..5119eba --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/schemes/gemini.swig @@ -0,0 +1,10 @@ +{% + set scripts = [ + 'src/affix.js', + 'src/schemes/pisces.js' + ] +%} + +{% for script in scripts %} + +{% endfor %} diff --git a/themes/next-5.1.4/layout/_scripts/schemes/mist.swig b/themes/next-5.1.4/layout/_scripts/schemes/mist.swig new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/layout/_scripts/schemes/muse.swig b/themes/next-5.1.4/layout/_scripts/schemes/muse.swig new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/layout/_scripts/schemes/pisces.swig b/themes/next-5.1.4/layout/_scripts/schemes/pisces.swig new file mode 100644 index 0000000..5119eba --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/schemes/pisces.swig @@ -0,0 +1,10 @@ +{% + set scripts = [ + 'src/affix.js', + 'src/schemes/pisces.js' + ] +%} + +{% for script in scripts %} + +{% endfor %} diff --git a/themes/next-5.1.4/layout/_scripts/vendors.swig b/themes/next-5.1.4/layout/_scripts/vendors.swig new file mode 100644 index 0000000..d0b86fd --- /dev/null +++ b/themes/next-5.1.4/layout/_scripts/vendors.swig @@ -0,0 +1,49 @@ +{# Reset `window.Promise` when it was not a function. #} +{# IE refers the element whose id is `Promise` as `window.Promise`, this causes Velocity throwing an exception #} + + +{% set js_vendors = {} %} +{% set js_vendors.jquery = 'jquery/index.js?v=2.1.3' %} +{% set js_vendors.fastclick = 'fastclick/lib/fastclick.min.js?v=1.0.6' %} +{% set js_vendors.lazyload = 'jquery_lazyload/jquery.lazyload.js?v=1.9.7' %} +{% set js_vendors.velocity = 'velocity/velocity.min.js?v=1.2.1' %} +{% set js_vendors.velocity_ui = 'velocity/velocity.ui.min.js?v=1.2.1' %} + +{% if theme.fancybox %} + {% set js_vendors.fancybox = 'fancybox/source/jquery.fancybox.pack.js?v=2.1.5' %} +{% endif %} +{% if theme.canvas_nest %} + {% set js_vendors.canvas_nest = 'canvas-nest/canvas-nest.min.js' %} +{% endif %} + +{% if theme.three_waves %} + {% set js_vendors.three = 'three/three.min.js' %} + {% set js_vendors.three_waves = 'three/three-waves.min.js' %} +{% endif %} + +{% if theme.canvas_lines %} + {% set js_vendors.three = 'three/three.min.js' %} + {% set js_vendors.canvas_lines = 'three/canvas_lines.min.js' %} +{% endif %} + +{% if theme.canvas_sphere %} + {% set js_vendors.three = 'three/three.min.js' %} + {% set js_vendors.canvas_sphere = 'three/canvas_sphere.min.js' %} +{% endif %} + +{% if theme.canvas_ribbon.enable and theme.scheme === 'Pisces'%} + {% set js_vendors.canvas_ribbon = 'canvas-ribbon/canvas-ribbon.js' %} +{% endif %} + +{% for name, internal in js_vendors %} + {% set internal_script = url_for(theme.vendors._internal) + '/' + internal %} + {% if name == 'canvas_ribbon' %} + + {% else %} + + {% endif %} +{% endfor %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/analytics-with-widget.swig b/themes/next-5.1.4/layout/_third-party/analytics/analytics-with-widget.swig new file mode 100644 index 0000000..f2a4049 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/analytics-with-widget.swig @@ -0,0 +1,4 @@ +{% include 'busuanzi-counter.swig' %} +{% include 'tencent-mta.swig' %} +{% include 'tencent-analytics.swig' %} +{% include 'cnzz-analytics.swig' %} \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_third-party/analytics/application-insights.swig b/themes/next-5.1.4/layout/_third-party/analytics/application-insights.swig new file mode 100644 index 0000000..c0af16f --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/application-insights.swig @@ -0,0 +1,11 @@ +{% if theme.application_insights %} + +{% endif %} \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_third-party/analytics/baidu-analytics.swig b/themes/next-5.1.4/layout/_third-party/analytics/baidu-analytics.swig new file mode 100644 index 0000000..9ae1d83 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/baidu-analytics.swig @@ -0,0 +1,11 @@ +{% if theme.baidu_analytics %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/busuanzi-counter.swig b/themes/next-5.1.4/layout/_third-party/analytics/busuanzi-counter.swig new file mode 100644 index 0000000..721b2c8 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/busuanzi-counter.swig @@ -0,0 +1,21 @@ +{% if theme.busuanzi_count.enable %} +
    + + + {% if theme.busuanzi_count.site_uv %} + + {{ theme.busuanzi_count.site_uv_header }} + + {{ theme.busuanzi_count.site_uv_footer }} + + {% endif %} + + {% if theme.busuanzi_count.site_pv %} + + {{ theme.busuanzi_count.site_pv_header }} + + {{ theme.busuanzi_count.site_pv_footer }} + + {% endif %} +
    +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/cnzz-analytics.swig b/themes/next-5.1.4/layout/_third-party/analytics/cnzz-analytics.swig new file mode 100644 index 0000000..4d9523e --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/cnzz-analytics.swig @@ -0,0 +1,7 @@ +{% if theme.cnzz_siteid %} + +
    + +
    + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/facebook-sdk.swig b/themes/next-5.1.4/layout/_third-party/analytics/facebook-sdk.swig new file mode 100644 index 0000000..7b5a291 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/facebook-sdk.swig @@ -0,0 +1,19 @@ +{% if theme.facebook_sdk.enable %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/firestore.swig b/themes/next-5.1.4/layout/_third-party/analytics/firestore.swig new file mode 100644 index 0000000..7493c75 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/firestore.swig @@ -0,0 +1,99 @@ +{% if theme.firestore.enable %} + + + {% if theme.firestore.bluebird %} + + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/google-analytics.swig b/themes/next-5.1.4/layout/_third-party/analytics/google-analytics.swig new file mode 100644 index 0000000..c66d461 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/google-analytics.swig @@ -0,0 +1,10 @@ +{% if theme.google_analytics %} + +{% endif %} \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_third-party/analytics/index.swig b/themes/next-5.1.4/layout/_third-party/analytics/index.swig new file mode 100644 index 0000000..78ae38e --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/index.swig @@ -0,0 +1,5 @@ +{% include 'facebook-sdk.swig' %} +{% include 'vkontakte-api.swig' %} +{% include 'google-analytics.swig' %} +{% include 'baidu-analytics.swig' %} +{% include 'application-insights.swig' %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/lean-analytics.swig b/themes/next-5.1.4/layout/_third-party/analytics/lean-analytics.swig new file mode 100644 index 0000000..2e8bb98 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/lean-analytics.swig @@ -0,0 +1,108 @@ +{% if theme.leancloud_visitors.enable %} + + {# custom analytics part create by xiamo #} + + + + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/tencent-analytics.swig b/themes/next-5.1.4/layout/_third-party/analytics/tencent-analytics.swig new file mode 100644 index 0000000..c2fab35 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/tencent-analytics.swig @@ -0,0 +1,10 @@ +{% if theme.tencent_analytics %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/tencent-mta.swig b/themes/next-5.1.4/layout/_third-party/analytics/tencent-mta.swig new file mode 100644 index 0000000..f4b6470 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/tencent-mta.swig @@ -0,0 +1,14 @@ +{% if theme.tencent_mta %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/analytics/vkontakte-api.swig b/themes/next-5.1.4/layout/_third-party/analytics/vkontakte-api.swig new file mode 100644 index 0000000..913a8fc --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/analytics/vkontakte-api.swig @@ -0,0 +1,27 @@ +{% if theme.vkontakte_api.enable %} + +
    + + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/changyan.swig b/themes/next-5.1.4/layout/_third-party/comments/changyan.swig new file mode 100644 index 0000000..d816b2c --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/changyan.swig @@ -0,0 +1,18 @@ +{% if theme.changyan.enable and theme.changyan.appid and theme.changyan.appkey %} + {% if is_home() %} + + {% else %} + + + {% endif %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/disqus.swig b/themes/next-5.1.4/layout/_third-party/comments/disqus.swig new file mode 100644 index 0000000..2d14907 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/disqus.swig @@ -0,0 +1,23 @@ +{% if not (theme.duoshuo and theme.duoshuo.shortname) and not theme.duoshuo_shortname %} + {% if theme.disqus.enable %} + + {% if theme.disqus.count %} + + {% endif %} + + {% if page.comments %} + + {% endif %} + + {% endif %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/duoshuo.swig b/themes/next-5.1.4/layout/_third-party/comments/duoshuo.swig new file mode 100644 index 0000000..c8499b2 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/duoshuo.swig @@ -0,0 +1,33 @@ +{% if (theme.duoshuo and theme.duoshuo.shortname) or theme.duoshuo_shortname %} + + {% if theme.duoshuo %} + {% set duoshuo_shortname = theme.duoshuo.shortname %} + {% else %} + {% set duoshuo_shortname = theme.duoshuo_shortname %} + {% endif %} + + + + {% if theme.duoshuo_info.ua_enable %} + {% if theme.duoshuo_info.admin_enable %} + {% set ua_parser_internal = url_for(theme.vendors._internal) + '/ua-parser-js/dist/ua-parser.min.js?v=0.7.9' %} + + + {% endif %} + {% set ua_parser_internal = url_for(theme.vendors._internal) + '/ua-parser-js/dist/ua-parser.min.js?v=0.7.9' %} + + + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/gitment.swig b/themes/next-5.1.4/layout/_third-party/comments/gitment.swig new file mode 100644 index 0000000..1bfad59 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/gitment.swig @@ -0,0 +1,60 @@ +{% if not (theme.duoshuo and theme.duoshuo.shortname) and not theme.duoshuo_shortname %} +{% if theme.gitment.enable and theme.gitment.client_id %} + + {% if theme.gitment.mint %} + {% set CommentsClass = "Gitmint" %} + + + {% else %} + {% set CommentsClass = "Gitment" %} + + + {% endif %} + + + {% if theme.gitment.cleanly %} + + {% endif %} + + {% if page.comments %} + + {% endif %} + +{% endif %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/hypercomments.swig b/themes/next-5.1.4/layout/_third-party/comments/hypercomments.swig new file mode 100644 index 0000000..de693e4 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/hypercomments.swig @@ -0,0 +1,27 @@ +{% if not (theme.duoshuo and theme.duoshuo.shortname) and not theme.duoshuo_shortname and not theme.disqus_shortname %} + + {% if theme.hypercomments_id %} + + + + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/index.swig b/themes/next-5.1.4/layout/_third-party/comments/index.swig new file mode 100644 index 0000000..b2da232 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/index.swig @@ -0,0 +1,8 @@ +{% include 'duoshuo.swig' %} +{% include 'disqus.swig' %} +{% include 'hypercomments.swig' %} +{% include 'youyan.swig' %} +{% include 'livere.swig' %} +{% include 'changyan.swig' %} +{% include 'gitment.swig' %} +{% include 'valine.swig' %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/livere.swig b/themes/next-5.1.4/layout/_third-party/comments/livere.swig new file mode 100644 index 0000000..9e1e165 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/livere.swig @@ -0,0 +1,16 @@ +{% if not (theme.duoshuo and theme.duoshuo.shortname) and not theme.duoshuo_shortname and not (theme.disqus.enable and theme.disqus.shortname) and not theme.hypercomments_id %} + + {% if page.comments and theme.livere_uid %} + + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/valine.swig b/themes/next-5.1.4/layout/_third-party/comments/valine.swig new file mode 100644 index 0000000..9bf5663 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/valine.swig @@ -0,0 +1,23 @@ +{% if theme.valine.enable and theme.valine.appid and theme.valine.appkey %} + + + + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/comments/youyan.swig b/themes/next-5.1.4/layout/_third-party/comments/youyan.swig new file mode 100644 index 0000000..dbf3e8a --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/comments/youyan.swig @@ -0,0 +1,16 @@ +{% if not (theme.duoshuo and theme.duoshuo.shortname) + and not theme.duoshuo_shortname + and not theme.disqus_shortname + and not theme.hypercomments_id %} + + {% if theme.youyan_uid %} + {% set uid = theme.youyan_uid %} + + {% if page.comments %} + + + + {% endif %} + {% endif %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/duoshuo-hot-articles.swig b/themes/next-5.1.4/layout/_third-party/duoshuo-hot-articles.swig new file mode 100644 index 0000000..2d1088d --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/duoshuo-hot-articles.swig @@ -0,0 +1,5 @@ +{# 多说热评文章 #} +{% if (theme.duoshuo_hotartical and page.title) %} +

    热评文章

    +
    +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/exturl.swig b/themes/next-5.1.4/layout/_third-party/exturl.swig new file mode 100644 index 0000000..329ab50 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/exturl.swig @@ -0,0 +1,3 @@ +{% if theme.exturl %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/mathjax.swig b/themes/next-5.1.4/layout/_third-party/mathjax.swig new file mode 100644 index 0000000..89db7b4 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/mathjax.swig @@ -0,0 +1,23 @@ +{% if theme.mathjax.enable %} + {% if not theme.mathjax.per_page or (page.total or page.mathjax) %} + + + + + {% endif %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/needsharebutton.swig b/themes/next-5.1.4/layout/_third-party/needsharebutton.swig new file mode 100644 index 0000000..73d8e4b --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/needsharebutton.swig @@ -0,0 +1,30 @@ +{% if theme.needmoreshare2.enable %} + {% set needmoreshare2_css = url_for(theme.vendors._internal + '/needsharebutton/needsharebutton.css') %} + {% if theme.vendors.needmoreshare2 %} + {% set needmoreshare2_css = theme.vendors.needmoreshare2_css %} + {% endif %} + + + {% set needmoreshare2_js = url_for(theme.vendors._internal + '/needsharebutton/needsharebutton.js') %} + {% if theme.vendors.needmoreshare2_js %} + {% set needmoreshare2_js = theme.vendors.needmoreshare2_js %} + {% endif %} + + + +{% endif %} \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_third-party/rating.swig b/themes/next-5.1.4/layout/_third-party/rating.swig new file mode 100644 index 0000000..3b376ce --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/rating.swig @@ -0,0 +1,18 @@ +{% if theme.rating.enable and (not is_home() and is_post()) %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/schedule.swig b/themes/next-5.1.4/layout/_third-party/schedule.swig new file mode 100644 index 0000000..6db3a3c --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/schedule.swig @@ -0,0 +1,185 @@ +{% if theme.calendar.enable %} +{% if page.type == 'schedule' %} + + + +{% endif %} +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/scroll-cookie.swig b/themes/next-5.1.4/layout/_third-party/scroll-cookie.swig new file mode 100644 index 0000000..9fbb0eb --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/scroll-cookie.swig @@ -0,0 +1,4 @@ +{% if theme.save_scroll %} + + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/search/algolia-search/assets.swig b/themes/next-5.1.4/layout/_third-party/search/algolia-search/assets.swig new file mode 100644 index 0000000..069504f --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/search/algolia-search/assets.swig @@ -0,0 +1,18 @@ +{% if theme.algolia_search.enable %} + + {# S: Include Algolia instantsearch.js library #} + {% set algolia_instant_css = url_for(theme.vendors._internal + '/algolia-instant-search/instantsearch.min.css') %} + {% if theme.vendors.algolia_instant_css %} + {% set algolia_instant_css = theme.vendors.algolia_instant_css %} + {% endif %} + + + {% set algolia_instant_js = url_for(theme.vendors._internal + '/algolia-instant-search/instantsearch.min.js') %} + {% if theme.vendors.algolia_instant_js %} + {% set algolia_instant_js = theme.vendors.algolia_instant_js %} + {% endif %} + + {# E: Include Algolia instantsearch.js library #} + + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/search/algolia-search/dom.swig b/themes/next-5.1.4/layout/_third-party/search/algolia-search/dom.swig new file mode 100644 index 0000000..a733bb1 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/search/algolia-search/dom.swig @@ -0,0 +1,20 @@ +{% if theme.algolia_search.enable %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/search/index.swig b/themes/next-5.1.4/layout/_third-party/search/index.swig new file mode 100644 index 0000000..0a352bc --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/search/index.swig @@ -0,0 +1,3 @@ +{% include 'tinysou.swig' %} +{% include 'localsearch.swig' %} +{% include 'algolia-search/assets.swig' %} diff --git a/themes/next-5.1.4/layout/_third-party/search/localsearch.swig b/themes/next-5.1.4/layout/_third-party/search/localsearch.swig new file mode 100644 index 0000000..c373e5c --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/search/localsearch.swig @@ -0,0 +1,318 @@ +{% if theme.local_search.enable %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/_third-party/search/tinysou.swig b/themes/next-5.1.4/layout/_third-party/search/tinysou.swig new file mode 100644 index 0000000..6e18684 --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/search/tinysou.swig @@ -0,0 +1,23 @@ +{% if config.tinysou_Key %} + +{% endif %} \ No newline at end of file diff --git a/themes/next-5.1.4/layout/_third-party/seo/baidu-push.swig b/themes/next-5.1.4/layout/_third-party/seo/baidu-push.swig new file mode 100644 index 0000000..ee6838f --- /dev/null +++ b/themes/next-5.1.4/layout/_third-party/seo/baidu-push.swig @@ -0,0 +1,16 @@ +{% if theme.baidu_push %} + +{% endif %} diff --git a/themes/next-5.1.4/layout/archive.swig b/themes/next-5.1.4/layout/archive.swig new file mode 100644 index 0000000..970491f --- /dev/null +++ b/themes/next-5.1.4/layout/archive.swig @@ -0,0 +1,62 @@ +{% extends '_layout.swig' %} +{% import '_macro/post-collapse.swig' as post_template %} +{% import '_macro/sidebar.swig' as sidebar_template %} + +{% block title %}{{ __('title.archive') }} | {{ config.title }}{% endblock %} + +{% block page_class %}page-archive{% endblock %} + +{% block content %} + + {#####################} + {### ARCHIVE BLOCK ###} + {#####################} +
    +
    + + + + {% set cheers %} + {% set posts_length = site.posts.length %} + {% if posts_length > 210 %} {% set cheers = 'excellent' %} + {% elif posts_length > 130 %} {% set cheers = 'great' %} + {% elif posts_length > 80 %} {% set cheers = 'good' %} + {% elif posts_length > 50 %} {% set cheers = 'nice' %} + {% elif posts_length > 30 %} {% set cheers = 'ok' %} + {% else %} + {% set cheers = 'um' %} + {% endif %} + {{ __('cheers.' + cheers) }}! {{ _p("counter.archive_posts", site.posts.length) }} {{ __('keep_on') }} + + + {% for post in page.posts %} + + {# Show year #} + {% set year %} + {% set post.year = date(post.date, 'YYYY') %} + + {% if post.year !== year %} + {% set year = post.year %} +
    + <{% if theme.seo %}h2{% else %}h1{% endif %} class="archive-year" id="archive-year-{{ year }}">{{ year }} +
    + {% endif %} + {# endshow #} + + {{ post_template.render(post) }} + + {% endfor %} + +
    +
    + {#########################} + {### END ARCHIVE BLOCK ###} + {#########################} + + {% include '_partials/pagination.swig' %} + +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} diff --git a/themes/next-5.1.4/layout/category.swig b/themes/next-5.1.4/layout/category.swig new file mode 100644 index 0000000..8e3aa72 --- /dev/null +++ b/themes/next-5.1.4/layout/category.swig @@ -0,0 +1,38 @@ +{% extends '_layout.swig' %} +{% import '_macro/post-collapse.swig' as post_template %} +{% import '_macro/sidebar.swig' as sidebar_template %} + +{% block title %}{{ __('title.category') }}: {{ page.category }} | {{ config.title }}{% endblock %} + +{% block content %} + + {######################} + {### CATEGORY BLOCK ###} + {######################} +
    + +
    +
    + <{% if theme.seo %}h2{% else %}h1{% endif %}>{# + #}{{ page.category }}{# + #}{{ __('title.category') }} + +
    + + {% for post in page.posts %} + {{ post_template.render(post) }} + {% endfor %} +
    + +
    + {##########################} + {### END CATEGORY BLOCK ###} + {##########################} + + {% include '_partials/pagination.swig' %} + +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} diff --git a/themes/next-5.1.4/layout/index.swig b/themes/next-5.1.4/layout/index.swig new file mode 100644 index 0000000..995c28a --- /dev/null +++ b/themes/next-5.1.4/layout/index.swig @@ -0,0 +1,23 @@ +{% extends '_layout.swig' %} +{% import '_macro/post.swig' as post_template %} +{% import '_macro/sidebar.swig' as sidebar_template %} + +{% block title %}{{ config.title }}{% if theme.index_with_subtitle and config.subtitle %} - {{config.subtitle }}{% endif %}{% endblock %} + +{% block page_class %} + {% if is_home() %}page-home{% endif -%} +{% endblock %} + +{% block content %} +
    + {% for post in page.posts %} + {{ post_template.render(post, true) }} + {% endfor %} +
    + + {% include '_partials/pagination.swig' %} +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} diff --git a/themes/next-5.1.4/layout/page.swig b/themes/next-5.1.4/layout/page.swig new file mode 100644 index 0000000..83ad7bd --- /dev/null +++ b/themes/next-5.1.4/layout/page.swig @@ -0,0 +1,70 @@ +{% extends '_layout.swig' %} +{% import '_macro/sidebar.swig' as sidebar_template %} + + {% block title %}{# + #}{% set page_title_suffix = ' | ' + config.title %}{# + + #}{% if page.type === "categories" and not page.title %}{# + #}{{ __('title.category') + page_title_suffix }}{# + #}{% elif page.type === "tags" and not page.title %}{# + #}{{ __('title.tag') + page_title_suffix }}{# + #}{% else %}{# + #}{{ page.title + page_title_suffix }}{# + #}{% endif %}{# +#}{% endblock %} + +{% block page_class %}page-post-detail{% endblock %} + +{% block content %} + +
    + {##################} + {### PAGE BLOCK ###} + {##################} +
    + {% include '_partials/page-header.swig' %} + {#################} + {### PAGE BODY ###} + {#################} +
    + {# tagcloud page support #} + {% if page.type === "tags" %} +
    +
    + {{ _p('counter.tag_cloud', site.tags.length) }} +
    +
    + {{ tagcloud({min_font: 12, max_font: 30, amount: 300, color: true, start_color: '#ccc', end_color: '#111'}) }} +
    +
    + {% elif page.type === 'categories' %} +
    +
    + {{ _p('counter.categories', site.categories.length) }} +
    +
    + {{ list_categories() }} +
    +
    + {% else %} + {{ page.content }} + {% endif %} +
    + {#####################} + {### END PAGE BODY ###} + {#####################} +
    + {######################} + {### END PAGE BLOCK ###} + {######################} +
    + +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} + +{% block script_extra %} + {% include '_scripts/pages/post-details.swig' %} +{% endblock %} diff --git a/themes/next-5.1.4/layout/post.swig b/themes/next-5.1.4/layout/post.swig new file mode 100644 index 0000000..8274630 --- /dev/null +++ b/themes/next-5.1.4/layout/post.swig @@ -0,0 +1,37 @@ +{% extends '_layout.swig' %} +{% import '_macro/post.swig' as post_template %} +{% import '_macro/sidebar.swig' as sidebar_template %} + + +{% block title %}{{ page.title }} | {{ config.title }}{% endblock %} + +{% block page_class %}page-post-detail{% endblock %} + + +{% block content %} + +
    + {{ post_template.render(page) }} + +
    + {% if theme.jiathis %} + {% include '_partials/share/jiathis.swig' %} + {% elseif theme.baidushare %} + {% include '_partials/share/baidushare.swig' %} + {% elseif theme.add_this_id %} + {% include '_partials/share/add-this.swig' %} + {% elseif theme.duoshuo_shortname and theme.duoshuo_share %} + {% include '_partials/share/duoshuo_share.swig' %} + {% endif %} +
    +
    + +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(true) }} +{% endblock %} + +{% block script_extra %} + {% include '_scripts/pages/post-details.swig' %} +{% endblock %} diff --git a/themes/next-5.1.4/layout/schedule.swig b/themes/next-5.1.4/layout/schedule.swig new file mode 100644 index 0000000..216dfea --- /dev/null +++ b/themes/next-5.1.4/layout/schedule.swig @@ -0,0 +1,25 @@ +{% extends '_layout.swig' %} +{% import '_macro/sidebar.swig' as sidebar_template %} + +{% block title %}{{ __('title.schedule') }} | {{ config.title }}{% endblock %} + +{% block page_class %}page-post-detail page-calendar{% endblock %} + +{% block content %} + {######################} + {### SCHEDULE BLOCK ###} + {######################} +
    +
    +
      +
    +
    +
    + {##########################} + {### END SCHEDULE BLOCK ###} + {##########################} +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} diff --git a/themes/next-5.1.4/layout/tag.swig b/themes/next-5.1.4/layout/tag.swig new file mode 100644 index 0000000..e570ce8 --- /dev/null +++ b/themes/next-5.1.4/layout/tag.swig @@ -0,0 +1,37 @@ +{% extends '_layout.swig' %} +{% import '_macro/post-collapse.swig' as post_template %} +{% import '_macro/sidebar.swig' as sidebar_template %} + +{% block title %}{{ __('title.tag') }}: {{ page.tag }} | {{ config.title }}{% endblock %} + +{% block content %} + + {#################} + {### TAG BLOCK ###} + {#################} +
    + +
    +
    + <{% if theme.seo %}h2{% else %}h1{% endif %}>{# + #}{{ page.tag }}{# + #}{{ __('title.tag') }} + +
    + + {% for post in page.posts %} + {{ post_template.render(post) }} + {% endfor %} +
    + +
    + {#####################} + {### END TAG BLOCK ###} + {#####################} + + {% include '_partials/pagination.swig' %} +{% endblock %} + +{% block sidebar %} + {{ sidebar_template.render(false) }} +{% endblock %} diff --git a/themes/next-5.1.4/package.json b/themes/next-5.1.4/package.json new file mode 100644 index 0000000..8de1090 --- /dev/null +++ b/themes/next-5.1.4/package.json @@ -0,0 +1,38 @@ +{ + "name": "hexo-theme-next", + "version": "5.1.4", + "description": "Elegant theme for Hexo", + "main": "index.js", + "directories": { + "test": "test" + }, + "scripts": { + "test": "gulp" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/iissnan/hexo-theme-next.git" + }, + "keywords": [ + "NexT", + "Hexo" + ], + "author": "iissnan ", + "maintainers": [ + "Ivan Nginx (https://almostover.ru)" + ], + "license": "MIT", + "bugs": { + "url": "https://github.com/iissnan/hexo-theme-next/issues" + }, + "homepage": "https://theme-next.iissnan.com", + "devDependencies": { + "coffee-script": "^1.10.0", + "gulp": "^3.9.0", + "gulp-jshint": "^1.12.0", + "gulp-shell": "^0.6.1", + "js-yaml": "^3.8.1", + "jshint-stylish": "^2.1.0", + "stylint": "^1.5.9" + } +} diff --git a/themes/next-5.1.4/scripts/merge-configs.js b/themes/next-5.1.4/scripts/merge-configs.js new file mode 100644 index 0000000..10c1eb6 --- /dev/null +++ b/themes/next-5.1.4/scripts/merge-configs.js @@ -0,0 +1,30 @@ +/* global hexo */ + +var merge = require('./merge'); + +/** + * Merge configs in _data/next.yml into hexo.theme.config. + * Note: configs in _data/next.yml will override configs in hexo.theme.config. + */ +hexo.on('generateBefore', function () { + if (hexo.locals.get) { + var data = hexo.locals.get('data'); + if ( data && data.next ) { + if ( data.next.override ) { + hexo.theme.config = data.next; + } else { + merge(hexo.theme.config, data.next); + } + } + } +}); + +hexo.on('generateAfter', function () { + hexo.log.warn("==============================================================="); + hexo.log.warn("========================= ATTENTION! =========================="); + hexo.log.warn("==============================================================="); + hexo.log.warn(" NexT repository is moving here: https://github.com/theme-next "); + hexo.log.warn("==============================================================="); + hexo.log.warn(" It's rebase to v6.0.0 and future maintenance will resume there"); + hexo.log.warn("==============================================================="); +}); diff --git a/themes/next-5.1.4/scripts/merge.js b/themes/next-5.1.4/scripts/merge.js new file mode 100644 index 0000000..f964663 --- /dev/null +++ b/themes/next-5.1.4/scripts/merge.js @@ -0,0 +1,2225 @@ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as the size to enable large array optimizations. */ +var LARGE_ARRAY_SIZE = 200; + +/** Used to stand-in for `undefined` hash values. */ +var HASH_UNDEFINED = '__lodash_hash_undefined__'; + +/** Used as references for various `Number` constants. */ +var MAX_SAFE_INTEGER = 9007199254740991; + +/** `Object#toString` result references. */ +var argsTag = '[object Arguments]', + arrayTag = '[object Array]', + boolTag = '[object Boolean]', + dateTag = '[object Date]', + errorTag = '[object Error]', + funcTag = '[object Function]', + genTag = '[object GeneratorFunction]', + mapTag = '[object Map]', + numberTag = '[object Number]', + objectTag = '[object Object]', + promiseTag = '[object Promise]', + regexpTag = '[object RegExp]', + setTag = '[object Set]', + stringTag = '[object String]', + symbolTag = '[object Symbol]', + weakMapTag = '[object WeakMap]'; + +var arrayBufferTag = '[object ArrayBuffer]', + dataViewTag = '[object DataView]', + float32Tag = '[object Float32Array]', + float64Tag = '[object Float64Array]', + int8Tag = '[object Int8Array]', + int16Tag = '[object Int16Array]', + int32Tag = '[object Int32Array]', + uint8Tag = '[object Uint8Array]', + uint8ClampedTag = '[object Uint8ClampedArray]', + uint16Tag = '[object Uint16Array]', + uint32Tag = '[object Uint32Array]'; + +/** + * Used to match `RegExp` + * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns). + */ +var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; + +/** Used to match `RegExp` flags from their coerced string values. */ +var reFlags = /\w*$/; + +/** Used to detect host constructors (Safari). */ +var reIsHostCtor = /^\[object .+?Constructor\]$/; + +/** Used to detect unsigned integer values. */ +var reIsUint = /^(?:0|[1-9]\d*)$/; + +/** Used to identify `toStringTag` values of typed arrays. */ +var typedArrayTags = {}; +typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = + typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = + typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = + typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = + typedArrayTags[uint32Tag] = true; +typedArrayTags[argsTag] = typedArrayTags[arrayTag] = + typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = + typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = + typedArrayTags[errorTag] = typedArrayTags[funcTag] = + typedArrayTags[mapTag] = typedArrayTags[numberTag] = + typedArrayTags[objectTag] = typedArrayTags[regexpTag] = + typedArrayTags[setTag] = typedArrayTags[stringTag] = + typedArrayTags[weakMapTag] = false; + +/** Used to identify `toStringTag` values supported by `_.clone`. */ +var cloneableTags = {}; +cloneableTags[argsTag] = cloneableTags[arrayTag] = + cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = + cloneableTags[boolTag] = cloneableTags[dateTag] = + cloneableTags[float32Tag] = cloneableTags[float64Tag] = + cloneableTags[int8Tag] = cloneableTags[int16Tag] = + cloneableTags[int32Tag] = cloneableTags[mapTag] = + cloneableTags[numberTag] = cloneableTags[objectTag] = + cloneableTags[regexpTag] = cloneableTags[setTag] = + cloneableTags[stringTag] = cloneableTags[symbolTag] = + cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = + cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true; +cloneableTags[errorTag] = cloneableTags[funcTag] = + cloneableTags[weakMapTag] = false; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + +/** Detect free variable `exports`. */ +var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports; + +/** Detect free variable `module`. */ +var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module; + +/** Detect the popular CommonJS extension `module.exports`. */ +var moduleExports = freeModule && freeModule.exports === freeExports; + +/** Detect free variable `process` from Node.js. */ +var freeProcess = moduleExports && freeGlobal.process; + +/** Used to access faster Node.js helpers. */ +var nodeUtil = (function () { + try { + return freeProcess && freeProcess.binding('util'); + } catch (e) { + } +}()); + +/* Node.js helper references. */ +var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray; + +/** + * Adds the key-value `pair` to `map`. + * + * @private + * @param {Object} map The map to modify. + * @param {Array} pair The key-value pair to add. + * @returns {Object} Returns `map`. + */ +function addMapEntry(map, pair) { + // Don't return `map.set` because it's not chainable in IE 11. + map.set(pair[0], pair[1]); + return map; +} + +/** + * Adds `value` to `set`. + * + * @private + * @param {Object} set The set to modify. + * @param {*} value The value to add. + * @returns {Object} Returns `set`. + */ +function addSetEntry(set, value) { + // Don't return `set.add` because it's not chainable in IE 11. + set.add(value); + return set; +} + +/** + * A faster alternative to `Function#apply`, this function invokes `func` + * with the `this` binding of `thisArg` and the arguments of `args`. + * + * @private + * @param {Function} func The function to invoke. + * @param {*} thisArg The `this` binding of `func`. + * @param {Array} args The arguments to invoke `func` with. + * @returns {*} Returns the result of `func`. + */ +function apply(func, thisArg, args) { + switch (args.length) { + case 0: + return func.call(thisArg); + case 1: + return func.call(thisArg, args[0]); + case 2: + return func.call(thisArg, args[0], args[1]); + case 3: + return func.call(thisArg, args[0], args[1], args[2]); + } + return func.apply(thisArg, args); +} + +/** + * A specialized version of `_.forEach` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns `array`. + */ +function arrayEach(array, iteratee) { + var index = -1, + length = array ? array.length : 0; + + while (++index < length) { + if (iteratee(array[index], index, array) === false) { + break; + } + } + return array; +} + +/** + * Appends the elements of `values` to `array`. + * + * @private + * @param {Array} array The array to modify. + * @param {Array} values The values to append. + * @returns {Array} Returns `array`. + */ +function arrayPush(array, values) { + var index = -1, + length = values.length, + offset = array.length; + + while (++index < length) { + array[offset + index] = values[index]; + } + return array; +} + +/** + * A specialized version of `_.reduce` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as + * the initial value. + * @returns {*} Returns the accumulated value. + */ +function arrayReduce(array, iteratee, accumulator, initAccum) { + var index = -1, + length = array ? array.length : 0; + + if (initAccum && length) { + accumulator = array[++index]; + } + while (++index < length) { + accumulator = iteratee(accumulator, array[index], index, array); + } + return accumulator; +} + +/** + * The base implementation of `_.times` without support for iteratee shorthands + * or max array length checks. + * + * @private + * @param {number} n The number of times to invoke `iteratee`. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the array of results. + */ +function baseTimes(n, iteratee) { + var index = -1, + result = Array(n); + + while (++index < n) { + result[index] = iteratee(index); + } + return result; +} + +/** + * The base implementation of `_.unary` without support for storing metadata. + * + * @private + * @param {Function} func The function to cap arguments for. + * @returns {Function} Returns the new capped function. + */ +function baseUnary(func) { + return function (value) { + return func(value); + }; +} + +/** + * Gets the value at `key` of `object`. + * + * @private + * @param {Object} [object] The object to query. + * @param {string} key The key of the property to get. + * @returns {*} Returns the property value. + */ +function getValue(object, key) { + return object == null ? undefined : object[key]; +} + +/** + * Checks if `value` is a host object in IE < 9. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a host object, else `false`. + */ +function isHostObject(value) { + // Many host objects are `Object` objects that can coerce to strings + // despite having improperly defined `toString` methods. + var result = false; + if (value != null && typeof value.toString != 'function') { + try { + result = !!(value + ''); + } catch (e) { + } + } + return result; +} + +/** + * Converts `map` to its key-value pairs. + * + * @private + * @param {Object} map The map to convert. + * @returns {Array} Returns the key-value pairs. + */ +function mapToArray(map) { + var index = -1, + result = Array(map.size); + + map.forEach(function (value, key) { + result[++index] = [key, value]; + }); + return result; +} + +/** + * Creates a unary function that invokes `func` with its argument transformed. + * + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. + */ +function overArg(func, transform) { + return function (arg) { + return func(transform(arg)); + }; +} + +/** + * Converts `set` to an array of its values. + * + * @private + * @param {Object} set The set to convert. + * @returns {Array} Returns the values. + */ +function setToArray(set) { + var index = -1, + result = Array(set.size); + + set.forEach(function (value) { + result[++index] = value; + }); + return result; +} + +/** Used for built-in method references. */ +var arrayProto = Array.prototype, + funcProto = Function.prototype, + objectProto = Object.prototype; + +/** Used to detect overreaching core-js shims. */ +var coreJsData = root['__core-js_shared__']; + +/** Used to detect methods masquerading as native. */ +var maskSrcKey = (function () { + var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || ''); + return uid ? ('Symbol(src)_1.' + uid) : ''; +}()); + +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** Used to infer the `Object` constructor. */ +var objectCtorString = funcToString.call(Object); + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** Used to detect if a method is native. */ +var reIsNative = RegExp('^' + + funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&') + .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' +); + +/** Built-in value references. */ +var Buffer = moduleExports ? root.Buffer : undefined, + Symbol = root.Symbol, + Uint8Array = root.Uint8Array, + getPrototype = overArg(Object.getPrototypeOf, Object), + objectCreate = Object.create, + propertyIsEnumerable = objectProto.propertyIsEnumerable, + splice = arrayProto.splice; + +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeGetSymbols = Object.getOwnPropertySymbols, + nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined, + nativeKeys = overArg(Object.keys, Object), + nativeMax = Math.max; + +/* Built-in method references that are verified to be native. */ +var DataView = getNative(root, 'DataView'), + Map = getNative(root, 'Map'), + Promise = getNative(root, 'Promise'), + Set = getNative(root, 'Set'), + WeakMap = getNative(root, 'WeakMap'), + nativeCreate = getNative(Object, 'create'); + +/** Used to detect maps, sets, and weakmaps. */ +var dataViewCtorString = toSource(DataView), + mapCtorString = toSource(Map), + promiseCtorString = toSource(Promise), + setCtorString = toSource(Set), + weakMapCtorString = toSource(WeakMap); + +/** Used to convert symbols to primitives and strings. */ +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = symbolProto ? symbolProto.valueOf : undefined; + +/** + * Creates a hash object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function Hash(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the hash. + * + * @private + * @name clear + * @memberOf Hash + */ +function hashClear() { + this.__data__ = nativeCreate ? nativeCreate(null) : {}; +} + +/** + * Removes `key` and its value from the hash. + * + * @private + * @name delete + * @memberOf Hash + * @param {Object} hash The hash to modify. + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function hashDelete(key) { + return this.has(key) && delete this.__data__[key]; +} + +/** + * Gets the hash value for `key`. + * + * @private + * @name get + * @memberOf Hash + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function hashGet(key) { + var data = this.__data__; + if (nativeCreate) { + var result = data[key]; + return result === HASH_UNDEFINED ? undefined : result; + } + return hasOwnProperty.call(data, key) ? data[key] : undefined; +} + +/** + * Checks if a hash value for `key` exists. + * + * @private + * @name has + * @memberOf Hash + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function hashHas(key) { + var data = this.__data__; + return nativeCreate ? data[key] !== undefined : hasOwnProperty.call(data, key); +} + +/** + * Sets the hash `key` to `value`. + * + * @private + * @name set + * @memberOf Hash + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the hash instance. + */ +function hashSet(key, value) { + var data = this.__data__; + data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value; + return this; +} + +// Add methods to `Hash`. +Hash.prototype.clear = hashClear; +Hash.prototype['delete'] = hashDelete; +Hash.prototype.get = hashGet; +Hash.prototype.has = hashHas; +Hash.prototype.set = hashSet; + +/** + * Creates an list cache object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function ListCache(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the list cache. + * + * @private + * @name clear + * @memberOf ListCache + */ +function listCacheClear() { + this.__data__ = []; +} + +/** + * Removes `key` and its value from the list cache. + * + * @private + * @name delete + * @memberOf ListCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function listCacheDelete(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + return false; + } + var lastIndex = data.length - 1; + if (index == lastIndex) { + data.pop(); + } else { + splice.call(data, index, 1); + } + return true; +} + +/** + * Gets the list cache value for `key`. + * + * @private + * @name get + * @memberOf ListCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function listCacheGet(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + return index < 0 ? undefined : data[index][1]; +} + +/** + * Checks if a list cache value for `key` exists. + * + * @private + * @name has + * @memberOf ListCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function listCacheHas(key) { + return assocIndexOf(this.__data__, key) > -1; +} + +/** + * Sets the list cache `key` to `value`. + * + * @private + * @name set + * @memberOf ListCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the list cache instance. + */ +function listCacheSet(key, value) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + data.push([key, value]); + } else { + data[index][1] = value; + } + return this; +} + +// Add methods to `ListCache`. +ListCache.prototype.clear = listCacheClear; +ListCache.prototype['delete'] = listCacheDelete; +ListCache.prototype.get = listCacheGet; +ListCache.prototype.has = listCacheHas; +ListCache.prototype.set = listCacheSet; + +/** + * Creates a map cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function MapCache(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the map. + * + * @private + * @name clear + * @memberOf MapCache + */ +function mapCacheClear() { + this.__data__ = { + 'hash': new Hash, + 'map': new (Map || ListCache), + 'string': new Hash + }; +} + +/** + * Removes `key` and its value from the map. + * + * @private + * @name delete + * @memberOf MapCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function mapCacheDelete(key) { + return getMapData(this, key)['delete'](key); +} + +/** + * Gets the map value for `key`. + * + * @private + * @name get + * @memberOf MapCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function mapCacheGet(key) { + return getMapData(this, key).get(key); +} + +/** + * Checks if a map value for `key` exists. + * + * @private + * @name has + * @memberOf MapCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function mapCacheHas(key) { + return getMapData(this, key).has(key); +} + +/** + * Sets the map `key` to `value`. + * + * @private + * @name set + * @memberOf MapCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the map cache instance. + */ +function mapCacheSet(key, value) { + getMapData(this, key).set(key, value); + return this; +} + +// Add methods to `MapCache`. +MapCache.prototype.clear = mapCacheClear; +MapCache.prototype['delete'] = mapCacheDelete; +MapCache.prototype.get = mapCacheGet; +MapCache.prototype.has = mapCacheHas; +MapCache.prototype.set = mapCacheSet; + +/** + * Creates a stack cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function Stack(entries) { + this.__data__ = new ListCache(entries); +} + +/** + * Removes all key-value entries from the stack. + * + * @private + * @name clear + * @memberOf Stack + */ +function stackClear() { + this.__data__ = new ListCache; +} + +/** + * Removes `key` and its value from the stack. + * + * @private + * @name delete + * @memberOf Stack + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function stackDelete(key) { + return this.__data__['delete'](key); +} + +/** + * Gets the stack value for `key`. + * + * @private + * @name get + * @memberOf Stack + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function stackGet(key) { + return this.__data__.get(key); +} + +/** + * Checks if a stack value for `key` exists. + * + * @private + * @name has + * @memberOf Stack + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function stackHas(key) { + return this.__data__.has(key); +} + +/** + * Sets the stack `key` to `value`. + * + * @private + * @name set + * @memberOf Stack + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the stack cache instance. + */ +function stackSet(key, value) { + var cache = this.__data__; + if (cache instanceof ListCache) { + var pairs = cache.__data__; + if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) { + pairs.push([key, value]); + return this; + } + cache = this.__data__ = new MapCache(pairs); + } + cache.set(key, value); + return this; +} + +// Add methods to `Stack`. +Stack.prototype.clear = stackClear; +Stack.prototype['delete'] = stackDelete; +Stack.prototype.get = stackGet; +Stack.prototype.has = stackHas; +Stack.prototype.set = stackSet; + +/** + * Creates an array of the enumerable property names of the array-like `value`. + * + * @private + * @param {*} value The value to query. + * @param {boolean} inherited Specify returning inherited property names. + * @returns {Array} Returns the array of property names. + */ +function arrayLikeKeys(value, inherited) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + // Safari 9 makes `arguments.length` enumerable in strict mode. + var result = (isArray(value) || isArguments(value)) + ? baseTimes(value.length, String) + : []; + + var length = result.length, + skipIndexes = !!length; + + for (var key in value) { + if ((inherited || hasOwnProperty.call(value, key)) && !(skipIndexes && (key == 'length' || isIndex(key, length)))) { + result.push(key); + } + } + return result; +} + +/** + * This function is like `assignValue` except that it doesn't assign + * `undefined` values. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ +function assignMergeValue(object, key, value) { + if ((value !== undefined && !eq(object[key], value)) || + (typeof key == 'number' && value === undefined && !(key in object))) { + object[key] = value; + } +} + +/** + * Assigns `value` to `key` of `object` if the existing value is not equivalent + * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ +function assignValue(object, key, value) { + var objValue = object[key]; + if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || + (value === undefined && !(key in object))) { + object[key] = value; + } +} + +/** + * Gets the index at which the `key` is found in `array` of key-value pairs. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} key The key to search for. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function assocIndexOf(array, key) { + var length = array.length; + while (length--) { + if (eq(array[length][0], key)) { + return length; + } + } + return -1; +} + +/** + * The base implementation of `_.assign` without support for multiple sources + * or `customizer` functions. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @returns {Object} Returns `object`. + */ +function baseAssign(object, source) { + return object && copyObject(source, keys(source), object); +} + +/** + * The base implementation of `_.clone` and `_.cloneDeep` which tracks + * traversed objects. + * + * @private + * @param {*} value The value to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @param {boolean} [isFull] Specify a clone including symbols. + * @param {Function} [customizer] The function to customize cloning. + * @param {string} [key] The key of `value`. + * @param {Object} [object] The parent object of `value`. + * @param {Object} [stack] Tracks traversed objects and their clone counterparts. + * @returns {*} Returns the cloned value. + */ +function baseClone(value, isDeep, isFull, customizer, key, object, stack) { + var result; + if (customizer) { + result = object ? customizer(value, key, object, stack) : customizer(value); + } + if (result !== undefined) { + return result; + } + if (!isObject(value)) { + return value; + } + var isArr = isArray(value); + if (isArr) { + result = initCloneArray(value); + if (!isDeep) { + return copyArray(value, result); + } + } else { + var tag = getTag(value), + isFunc = tag == funcTag || tag == genTag; + + if (isBuffer(value)) { + return cloneBuffer(value, isDeep); + } + if (tag == objectTag || tag == argsTag || (isFunc && !object)) { + if (isHostObject(value)) { + return object ? value : {}; + } + result = initCloneObject(isFunc ? {} : value); + if (!isDeep) { + return copySymbols(value, baseAssign(result, value)); + } + } else { + if (!cloneableTags[tag]) { + return object ? value : {}; + } + result = initCloneByTag(value, tag, baseClone, isDeep); + } + } + // Check for circular references and return its corresponding clone. + stack || (stack = new Stack); + var stacked = stack.get(value); + if (stacked) { + return stacked; + } + stack.set(value, result); + + if (!isArr) { + var props = isFull ? getAllKeys(value) : keys(value); + } + arrayEach(props || value, function (subValue, key) { + if (props) { + key = subValue; + subValue = value[key]; + } + // Recursively populate clone (susceptible to call stack limits). + assignValue(result, key, baseClone(subValue, isDeep, isFull, customizer, key, value, stack)); + }); + return result; +} + +/** + * The base implementation of `_.create` without support for assigning + * properties to the created object. + * + * @private + * @param {Object} prototype The object to inherit from. + * @returns {Object} Returns the new object. + */ +function baseCreate(proto) { + return isObject(proto) ? objectCreate(proto) : {}; +} + +/** + * The base implementation of `getAllKeys` and `getAllKeysIn` which uses + * `keysFunc` and `symbolsFunc` to get the enumerable property names and + * symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Function} keysFunc The function to get the keys of `object`. + * @param {Function} symbolsFunc The function to get the symbols of `object`. + * @returns {Array} Returns the array of property names and symbols. + */ +function baseGetAllKeys(object, keysFunc, symbolsFunc) { + var result = keysFunc(object); + return isArray(object) ? result : arrayPush(result, symbolsFunc(object)); +} + +/** + * The base implementation of `getTag`. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ +function baseGetTag(value) { + return objectToString.call(value); +} + +/** + * The base implementation of `_.isNative` without bad shim checks. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a native function, + * else `false`. + */ +function baseIsNative(value) { + if (!isObject(value) || isMasked(value)) { + return false; + } + var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor; + return pattern.test(toSource(value)); +} + +/** + * The base implementation of `_.isTypedArray` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. + */ +function baseIsTypedArray(value) { + return isObjectLike(value) && + isLength(value.length) && !!typedArrayTags[objectToString.call(value)]; +} + +/** + * The base implementation of `_.keys` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeys(object) { + if (!isPrototype(object)) { + return nativeKeys(object); + } + var result = []; + for (var key in Object(object)) { + if (hasOwnProperty.call(object, key) && key != 'constructor') { + result.push(key); + } + } + return result; +} + +/** + * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeysIn(object) { + if (!isObject(object)) { + return nativeKeysIn(object); + } + var isProto = isPrototype(object), + result = []; + + for (var key in object) { + if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { + result.push(key); + } + } + return result; +} + +/** + * The base implementation of `_.merge` without support for multiple sources. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. + * @param {Function} [customizer] The function to customize merged values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ +function baseMerge(object, source, srcIndex, customizer, stack) { + if (object === source) { + return; + } + if (!(isArray(source) || isTypedArray(source))) { + var props = baseKeysIn(source); + } + arrayEach(props || source, function (srcValue, key) { + if (props) { + key = srcValue; + srcValue = source[key]; + } + if (isObject(srcValue)) { + stack || (stack = new Stack); + baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack); + } + else { + var newValue = customizer + ? customizer(object[key], srcValue, (key + ''), object, source, stack) + : undefined; + + if (newValue === undefined) { + newValue = srcValue; + } + assignMergeValue(object, key, newValue); + } + }); +} + +/** + * A specialized version of `baseMerge` for arrays and objects which performs + * deep merges and tracks traversed objects enabling objects with circular + * references to be merged. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. + * @param {Function} mergeFunc The function to merge values. + * @param {Function} [customizer] The function to customize assigned values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ +function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) { + var objValue = object[key], + srcValue = source[key], + stacked = stack.get(srcValue); + + if (stacked) { + assignMergeValue(object, key, stacked); + return; + } + var newValue = customizer + ? customizer(objValue, srcValue, (key + ''), object, source, stack) + : undefined; + + var isCommon = newValue === undefined; + + if (isCommon) { + newValue = srcValue; + if (isArray(srcValue) || isTypedArray(srcValue)) { + if (isArray(objValue)) { + newValue = objValue; + } + else if (isArrayLikeObject(objValue)) { + newValue = copyArray(objValue); + } + else { + isCommon = false; + newValue = baseClone(srcValue, true); + } + } + else if (isPlainObject(srcValue) || isArguments(srcValue)) { + if (isArguments(objValue)) { + newValue = toPlainObject(objValue); + } + else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) { + isCommon = false; + newValue = baseClone(srcValue, true); + } + else { + newValue = objValue; + } + } + else { + isCommon = false; + } + } + if (isCommon) { + // Recursively merge objects and arrays (susceptible to call stack limits). + stack.set(srcValue, newValue); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); + stack['delete'](srcValue); + } + assignMergeValue(object, key, newValue); +} + +/** + * The base implementation of `_.rest` which doesn't validate or coerce arguments. + * + * @private + * @param {Function} func The function to apply a rest parameter to. + * @param {number} [start=func.length-1] The start position of the rest parameter. + * @returns {Function} Returns the new function. + */ +function baseRest(func, start) { + start = nativeMax(start === undefined ? (func.length - 1) : start, 0); + return function () { + var args = arguments, + index = -1, + length = nativeMax(args.length - start, 0), + array = Array(length); + + while (++index < length) { + array[index] = args[start + index]; + } + index = -1; + var otherArgs = Array(start + 1); + while (++index < start) { + otherArgs[index] = args[index]; + } + otherArgs[start] = array; + return apply(func, this, otherArgs); + }; +} + +/** + * Creates a clone of `buffer`. + * + * @private + * @param {Buffer} buffer The buffer to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Buffer} Returns the cloned buffer. + */ +function cloneBuffer(buffer, isDeep) { + if (isDeep) { + return buffer.slice(); + } + var result = new buffer.constructor(buffer.length); + buffer.copy(result); + return result; +} + +/** + * Creates a clone of `arrayBuffer`. + * + * @private + * @param {ArrayBuffer} arrayBuffer The array buffer to clone. + * @returns {ArrayBuffer} Returns the cloned array buffer. + */ +function cloneArrayBuffer(arrayBuffer) { + var result = new arrayBuffer.constructor(arrayBuffer.byteLength); + new Uint8Array(result).set(new Uint8Array(arrayBuffer)); + return result; +} + +/** + * Creates a clone of `dataView`. + * + * @private + * @param {Object} dataView The data view to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned data view. + */ +function cloneDataView(dataView, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer; + return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength); +} + +/** + * Creates a clone of `map`. + * + * @private + * @param {Object} map The map to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned map. + */ +function cloneMap(map, isDeep, cloneFunc) { + var array = isDeep ? cloneFunc(mapToArray(map), true) : mapToArray(map); + return arrayReduce(array, addMapEntry, new map.constructor); +} + +/** + * Creates a clone of `regexp`. + * + * @private + * @param {Object} regexp The regexp to clone. + * @returns {Object} Returns the cloned regexp. + */ +function cloneRegExp(regexp) { + var result = new regexp.constructor(regexp.source, reFlags.exec(regexp)); + result.lastIndex = regexp.lastIndex; + return result; +} + +/** + * Creates a clone of `set`. + * + * @private + * @param {Object} set The set to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned set. + */ +function cloneSet(set, isDeep, cloneFunc) { + var array = isDeep ? cloneFunc(setToArray(set), true) : setToArray(set); + return arrayReduce(array, addSetEntry, new set.constructor); +} + +/** + * Creates a clone of the `symbol` object. + * + * @private + * @param {Object} symbol The symbol object to clone. + * @returns {Object} Returns the cloned symbol object. + */ +function cloneSymbol(symbol) { + return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {}; +} + +/** + * Creates a clone of `typedArray`. + * + * @private + * @param {Object} typedArray The typed array to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned typed array. + */ +function cloneTypedArray(typedArray, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer; + return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length); +} + +/** + * Copies the values of `source` to `array`. + * + * @private + * @param {Array} source The array to copy values from. + * @param {Array} [array=[]] The array to copy values to. + * @returns {Array} Returns `array`. + */ +function copyArray(source, array) { + var index = -1, + length = source.length; + + array || (array = Array(length)); + while (++index < length) { + array[index] = source[index]; + } + return array; +} + +/** + * Copies properties of `source` to `object`. + * + * @private + * @param {Object} source The object to copy properties from. + * @param {Array} props The property identifiers to copy. + * @param {Object} [object={}] The object to copy properties to. + * @param {Function} [customizer] The function to customize copied values. + * @returns {Object} Returns `object`. + */ +function copyObject(source, props, object, customizer) { + object || (object = {}); + + var index = -1, + length = props.length; + + while (++index < length) { + var key = props[index]; + + var newValue = customizer + ? customizer(object[key], source[key], key, object, source) + : undefined; + + assignValue(object, key, newValue === undefined ? source[key] : newValue); + } + return object; +} + +/** + * Copies own symbol properties of `source` to `object`. + * + * @private + * @param {Object} source The object to copy symbols from. + * @param {Object} [object={}] The object to copy symbols to. + * @returns {Object} Returns `object`. + */ +function copySymbols(source, object) { + return copyObject(source, getSymbols(source), object); +} + +/** + * Creates a function like `_.assign`. + * + * @private + * @param {Function} assigner The function to assign values. + * @returns {Function} Returns the new assigner function. + */ +function createAssigner(assigner) { + return baseRest(function (object, sources) { + var index = -1, + length = sources.length, + customizer = length > 1 ? sources[length - 1] : undefined, + guard = length > 2 ? sources[2] : undefined; + + customizer = (assigner.length > 3 && typeof customizer == 'function') + ? (length--, customizer) + : undefined; + + if (guard && isIterateeCall(sources[0], sources[1], guard)) { + customizer = length < 3 ? undefined : customizer; + length = 1; + } + object = Object(object); + while (++index < length) { + var source = sources[index]; + if (source) { + assigner(object, source, index, customizer); + } + } + return object; + }); +} + +/** + * Creates an array of own enumerable property names and symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names and symbols. + */ +function getAllKeys(object) { + return baseGetAllKeys(object, keys, getSymbols); +} + +/** + * Gets the data for `map`. + * + * @private + * @param {Object} map The map to query. + * @param {string} key The reference key. + * @returns {*} Returns the map data. + */ +function getMapData(map, key) { + var data = map.__data__; + return isKeyable(key) + ? data[typeof key == 'string' ? 'string' : 'hash'] + : data.map; +} + +/** + * Gets the native function at `key` of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {string} key The key of the method to get. + * @returns {*} Returns the function if it's native, else `undefined`. + */ +function getNative(object, key) { + var value = getValue(object, key); + return baseIsNative(value) ? value : undefined; +} + +/** + * Creates an array of the own enumerable symbol properties of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of symbols. + */ +var getSymbols = nativeGetSymbols ? overArg(nativeGetSymbols, Object) : stubArray; + +/** + * Gets the `toStringTag` of `value`. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ +var getTag = baseGetTag; + +// Fallback for data views, maps, sets, and weak maps in IE 11, +// for data views in Edge < 14, and promises in Node.js. +if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) || + (Map && getTag(new Map) != mapTag) || + (Promise && getTag(Promise.resolve()) != promiseTag) || + (Set && getTag(new Set) != setTag) || + (WeakMap && getTag(new WeakMap) != weakMapTag)) { + getTag = function (value) { + var result = objectToString.call(value), + Ctor = result == objectTag ? value.constructor : undefined, + ctorString = Ctor ? toSource(Ctor) : undefined; + + if (ctorString) { + switch (ctorString) { + case dataViewCtorString: + return dataViewTag; + case mapCtorString: + return mapTag; + case promiseCtorString: + return promiseTag; + case setCtorString: + return setTag; + case weakMapCtorString: + return weakMapTag; + } + } + return result; + }; +} + +/** + * Initializes an array clone. + * + * @private + * @param {Array} array The array to clone. + * @returns {Array} Returns the initialized clone. + */ +function initCloneArray(array) { + var length = array.length, + result = array.constructor(length); + + // Add properties assigned by `RegExp#exec`. + if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) { + result.index = array.index; + result.input = array.input; + } + return result; +} + +/** + * Initializes an object clone. + * + * @private + * @param {Object} object The object to clone. + * @returns {Object} Returns the initialized clone. + */ +function initCloneObject(object) { + return (typeof object.constructor == 'function' && !isPrototype(object)) + ? baseCreate(getPrototype(object)) + : {}; +} + +/** + * Initializes an object clone based on its `toStringTag`. + * + * **Note:** This function only supports cloning values with tags of + * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`. + * + * @private + * @param {Object} object The object to clone. + * @param {string} tag The `toStringTag` of the object to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the initialized clone. + */ +function initCloneByTag(object, tag, cloneFunc, isDeep) { + var Ctor = object.constructor; + switch (tag) { + case arrayBufferTag: + return cloneArrayBuffer(object); + + case boolTag: + case dateTag: + return new Ctor(+object); + + case dataViewTag: + return cloneDataView(object, isDeep); + + case float32Tag: + case float64Tag: + case int8Tag: + case int16Tag: + case int32Tag: + case uint8Tag: + case uint8ClampedTag: + case uint16Tag: + case uint32Tag: + return cloneTypedArray(object, isDeep); + + case mapTag: + return cloneMap(object, isDeep, cloneFunc); + + case numberTag: + case stringTag: + return new Ctor(object); + + case regexpTag: + return cloneRegExp(object); + + case setTag: + return cloneSet(object, isDeep, cloneFunc); + + case symbolTag: + return cloneSymbol(object); + } +} + +/** + * Checks if `value` is a valid array-like index. + * + * @private + * @param {*} value The value to check. + * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. + * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. + */ +function isIndex(value, length) { + length = length == null ? MAX_SAFE_INTEGER : length; + return !!length && + (typeof value == 'number' || reIsUint.test(value)) && + (value > -1 && value % 1 == 0 && value < length); +} + +/** + * Checks if the given arguments are from an iteratee call. + * + * @private + * @param {*} value The potential iteratee value argument. + * @param {*} index The potential iteratee index or key argument. + * @param {*} object The potential iteratee object argument. + * @returns {boolean} Returns `true` if the arguments are from an iteratee call, + * else `false`. + */ +function isIterateeCall(value, index, object) { + if (!isObject(object)) { + return false; + } + var type = typeof index; + if (type == 'number' + ? (isArrayLike(object) && isIndex(index, object.length)) + : (type == 'string' && index in object) + ) { + return eq(object[index], value); + } + return false; +} + +/** + * Checks if `value` is suitable for use as unique object key. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is suitable, else `false`. + */ +function isKeyable(value) { + var type = typeof value; + return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean') + ? (value !== '__proto__') + : (value === null); +} + +/** + * Checks if `func` has its source masked. + * + * @private + * @param {Function} func The function to check. + * @returns {boolean} Returns `true` if `func` is masked, else `false`. + */ +function isMasked(func) { + return !!maskSrcKey && (maskSrcKey in func); +} + +/** + * Checks if `value` is likely a prototype object. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. + */ +function isPrototype(value) { + var Ctor = value && value.constructor, + proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; + + return value === proto; +} + +/** + * This function is like + * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * except that it includes inherited enumerable properties. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function nativeKeysIn(object) { + var result = []; + if (object != null) { + for (var key in Object(object)) { + result.push(key); + } + } + return result; +} + +/** + * Converts `func` to its source code. + * + * @private + * @param {Function} func The function to process. + * @returns {string} Returns the source code. + */ +function toSource(func) { + if (func != null) { + try { + return funcToString.call(func); + } catch (e) { + } + try { + return (func + ''); + } catch (e) { + } + } + return ''; +} + +/** + * Performs a + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * comparison between two values to determine if they are equivalent. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if the values are equivalent, else `false`. + * @example + * + * var object = { 'a': 1 }; + * var other = { 'a': 1 }; + * + * _.eq(object, object); + * // => true + * + * _.eq(object, other); + * // => false + * + * _.eq('a', 'a'); + * // => true + * + * _.eq('a', Object('a')); + * // => false + * + * _.eq(NaN, NaN); + * // => true + */ +function eq(value, other) { + return value === other || (value !== value && other !== other); +} + +/** + * Checks if `value` is likely an `arguments` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an `arguments` object, + * else `false`. + * @example + * + * _.isArguments(function() { return arguments; }()); + * // => true + * + * _.isArguments([1, 2, 3]); + * // => false + */ +function isArguments(value) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && + (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); +} + +/** + * Checks if `value` is classified as an `Array` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array, else `false`. + * @example + * + * _.isArray([1, 2, 3]); + * // => true + * + * _.isArray(document.body.children); + * // => false + * + * _.isArray('abc'); + * // => false + * + * _.isArray(_.noop); + * // => false + */ +var isArray = Array.isArray; + +/** + * Checks if `value` is array-like. A value is considered array-like if it's + * not a function and has a `value.length` that's an integer greater than or + * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is array-like, else `false`. + * @example + * + * _.isArrayLike([1, 2, 3]); + * // => true + * + * _.isArrayLike(document.body.children); + * // => true + * + * _.isArrayLike('abc'); + * // => true + * + * _.isArrayLike(_.noop); + * // => false + */ +function isArrayLike(value) { + return value != null && isLength(value.length) && !isFunction(value); +} + +/** + * This method is like `_.isArrayLike` except that it also checks if `value` + * is an object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array-like object, + * else `false`. + * @example + * + * _.isArrayLikeObject([1, 2, 3]); + * // => true + * + * _.isArrayLikeObject(document.body.children); + * // => true + * + * _.isArrayLikeObject('abc'); + * // => false + * + * _.isArrayLikeObject(_.noop); + * // => false + */ +function isArrayLikeObject(value) { + return isObjectLike(value) && isArrayLike(value); +} + +/** + * Checks if `value` is a buffer. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a buffer, else `false`. + * @example + * + * _.isBuffer(new Buffer(2)); + * // => true + * + * _.isBuffer(new Uint8Array(2)); + * // => false + */ +var isBuffer = nativeIsBuffer || stubFalse; + +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a function, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8-9 which returns 'object' for typed array and other constructors. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} + +/** + * Checks if `value` is a valid array-like length. + * + * **Note:** This method is loosely based on + * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. + * @example + * + * _.isLength(3); + * // => true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false + */ +function isLength(value) { + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is a plain object, that is, an object created by the + * `Object` constructor or one with a `[[Prototype]]` of `null`. + * + * @static + * @memberOf _ + * @since 0.8.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. + * @example + * + * function Foo() { + * this.a = 1; + * } + * + * _.isPlainObject(new Foo); + * // => false + * + * _.isPlainObject([1, 2, 3]); + * // => false + * + * _.isPlainObject({ 'x': 0, 'y': 0 }); + * // => true + * + * _.isPlainObject(Object.create(null)); + * // => true + */ +function isPlainObject(value) { + if (!isObjectLike(value) || + objectToString.call(value) != objectTag || isHostObject(value)) { + return false; + } + var proto = getPrototype(value); + if (proto === null) { + return true; + } + var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; + return (typeof Ctor == 'function' && + Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString); +} + +/** + * Checks if `value` is classified as a typed array. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. + * @example + * + * _.isTypedArray(new Uint8Array); + * // => true + * + * _.isTypedArray([]); + * // => false + */ +var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray; + +/** + * Converts `value` to a plain object flattening inherited enumerable string + * keyed properties of `value` to own properties of the plain object. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {Object} Returns the converted plain object. + * @example + * + * function Foo() { + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.assign({ 'a': 1 }, new Foo); + * // => { 'a': 1, 'b': 2 } + * + * _.assign({ 'a': 1 }, _.toPlainObject(new Foo)); + * // => { 'a': 1, 'b': 2, 'c': 3 } + */ +function toPlainObject(value) { + return copyObject(value, keysIn(value)); +} + +/** + * Creates an array of the own enumerable property names of `object`. + * + * **Note:** Non-object values are coerced to objects. See the + * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * for more details. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.keys(new Foo); + * // => ['a', 'b'] (iteration order is not guaranteed) + * + * _.keys('hi'); + * // => ['0', '1'] + */ +function keys(object) { + return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); +} + +/** + * Creates an array of the own and inherited enumerable property names of `object`. + * + * **Note:** Non-object values are coerced to objects. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.keysIn(new Foo); + * // => ['a', 'b', 'c'] (iteration order is not guaranteed) + */ +function keysIn(object) { + return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object); +} + +/** + * This method is like `_.assign` except that it recursively merges own and + * inherited enumerable string keyed properties of source objects into the + * destination object. Source properties that resolve to `undefined` are + * skipped if a destination value exists. Array and plain object properties + * are merged recursively. Other objects and value types are overridden by + * assignment. Source objects are applied from left to right. Subsequent + * sources overwrite property assignments of previous sources. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 0.5.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @example + * + * var object = { + * 'a': [{ 'b': 2 }, { 'd': 4 }] + * }; + * + * var other = { + * 'a': [{ 'c': 3 }, { 'e': 5 }] + * }; + * + * _.merge(object, other); + * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] } + */ +var merge = createAssigner(function (object, source, srcIndex) { + baseMerge(object, source, srcIndex); +}); + +/** + * This method returns a new empty array. + * + * @static + * @memberOf _ + * @since 4.13.0 + * @category Util + * @returns {Array} Returns the new empty array. + * @example + * + * var arrays = _.times(2, _.stubArray); + * + * console.log(arrays); + * // => [[], []] + * + * console.log(arrays[0] === arrays[1]); + * // => false + */ +function stubArray() { + return []; +} + +/** + * This method returns `false`. + * + * @static + * @memberOf _ + * @since 4.13.0 + * @category Util + * @returns {boolean} Returns `false`. + * @example + * + * _.times(2, _.stubFalse); + * // => [false, false] + */ +function stubFalse() { + return false; +} + +module.exports = merge; diff --git a/themes/next-5.1.4/scripts/tags/button.js b/themes/next-5.1.4/scripts/tags/button.js new file mode 100644 index 0000000..dfc0962 --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/button.js @@ -0,0 +1,31 @@ +/* global hexo */ +// Usage: {% button /path/to/url/, text, icon [class], title %} +// Alias: {% btn /path/to/url/, text, icon [class], title %} + +function postButton(args) { + args = args.join(' ').split(','); + var url = args[0]; + var text = args[1] || ''; + var icon = args[2] || ''; + var title = args[3] || ''; + + if (!url) { + hexo.log.warn('URL can NOT be empty'); + } + + text = text.trim(); + icon = icon.trim(); + title = title.trim(); + + var result = [' 0 && result.push(' title="' + title + '"'); + result.push('>'); + icon.length > 0 && result.push(''); + text.length > 0 && result.push(text); + result.push(''); + + return result.join(''); +} + +hexo.extend.tag.register('button', postButton); +hexo.extend.tag.register('btn', postButton); diff --git a/themes/next-5.1.4/scripts/tags/center-quote.js b/themes/next-5.1.4/scripts/tags/center-quote.js new file mode 100644 index 0000000..93c5258 --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/center-quote.js @@ -0,0 +1,12 @@ +/* global hexo */ +// Usage: {% centerquote %} Something {% endcenterquote %} +// Alias: {% cq %} Something {% endcq %} + +function centerQuote (args, content) { + return '
    ' + + hexo.render.renderSync({text: content, engine: 'markdown'}) + + '
    '; +} + +hexo.extend.tag.register('centerquote', centerQuote, {ends: true}); +hexo.extend.tag.register('cq', centerQuote, {ends: true}); diff --git a/themes/next-5.1.4/scripts/tags/exturl.js b/themes/next-5.1.4/scripts/tags/exturl.js new file mode 100644 index 0000000..901a9ce --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/exturl.js @@ -0,0 +1,59 @@ +/* global hexo */ +// Usage: {% exturl text url "title" %} +// Alias: {% extlink text url "title" %} + +'use strict'; + +/*jshint camelcase: false */ +var util = require('hexo-util'); +/*jshint camelcase: true */ +var htmlTag = util.htmlTag; + +var rUrl = /((([A-Za-z]{3,9}:(?:\/\/)?)(?:[-;:&=\+\$,\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\+\$,\w]+@)[A-Za-z0-9.-]+)((?:\/[\+~%\/.\w-_]*)?\??(?:[-\+=&;%@.\w_]*)#?(?:[.\!\/\\w]*))?)/; + +// Create Base64 Object +var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(e){var t="";var n,r,i,s,o,u,a;var f=0;e=Base64._utf8_encode(e);while(f>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+this._keyStr.charAt(s)+this._keyStr.charAt(o)+this._keyStr.charAt(u)+this._keyStr.charAt(a)}return t},decode:function(e){var t="";var n,r,i;var s,o,u,a;var f=0;e=e.replace(/[^A-Za-z0-9+/=]/g,"");while(f>4;r=(o&15)<<4|u>>2;i=(u&3)<<6|a;t=t+String.fromCharCode(n);if(u!=64){t=t+String.fromCharCode(r)}if(a!=64){t=t+String.fromCharCode(i)}}t=Base64._utf8_decode(t);return t},_utf8_encode:function(e){e=e.replace(/rn/g,"n");var t="";for(var n=0;n127&&r<2048){t+=String.fromCharCode(r>>6|192);t+=String.fromCharCode(r&63|128)}else{t+=String.fromCharCode(r>>12|224);t+=String.fromCharCode(r>>6&63|128);t+=String.fromCharCode(r&63|128)}}return t},_utf8_decode:function(e){var t="";var n=0;var r=c1=c2=0;while(n191&&r<224){c2=e.charCodeAt(n+1);t+=String.fromCharCode((r&31)<<6|c2&63);n+=2}else{c2=e.charCodeAt(n+1);c3=e.charCodeAt(n+2);t+=String.fromCharCode((r&15)<<12|(c2&63)<<6|c3&63);n+=3}}return t}}; + +function extURL(args, content) { + var exturl = 'exturl'; + var url = ''; + var text = ['']; + var title = ''; + var item = ''; + var i = 0; + var len = args.length; + + // Find link URL and text + for (; i < len; i++) { + item = args[i]; + + if (rUrl.test(item)) { + url = Base64.encode(item); + break; + } else { + text.push(item); + } + } + + // Delete link URL and text from arguments + args = args.slice(i + 1); + + // Check if the link should be open in a new window + // and collect the last text as the link title + if (args.length) { + var shift = args[0]; + title = args.join(' '); + } + + var attrs = { + class: exturl, + 'data-url': url, + title: title + }; + + //console.log(url); + return htmlTag('span', attrs, text.join(' ')); +} + +hexo.extend.tag.register('exturl', extURL, {ends: false}); +hexo.extend.tag.register('extlink', extURL, {ends: false}); diff --git a/themes/next-5.1.4/scripts/tags/full-image.js b/themes/next-5.1.4/scripts/tags/full-image.js new file mode 100644 index 0000000..d4e0e4f --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/full-image.js @@ -0,0 +1,26 @@ +/* global hexo */ +// Usage: {% fullimage /path/to/image, alt, title %} +// Alias: {% fi /path/to/image, alt, title %} + +function fullImage(args) { + args = args.join(' ').split(','); + var src = args[0]; + var alt = args[1] || ''; + var title = args[2] || ''; + + if (!src) { + hexo.log.warn('Image src can NOT be empty'); + } + alt = alt.trim(); + title = title.trim(); + + var image = [' 0 && image.push('alt="' + alt + '"'); + title.length > 0 && image.push('title="' + title + '"'); + image.push('/>'); + + return image.join(' '); +} + +hexo.extend.tag.register('fullimage', fullImage); +hexo.extend.tag.register('fi', fullImage); diff --git a/themes/next-5.1.4/scripts/tags/group-pictures.js b/themes/next-5.1.4/scripts/tags/group-pictures.js new file mode 100644 index 0000000..df7774b --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/group-pictures.js @@ -0,0 +1,833 @@ +/* global hexo */ +// Usage: {% grouppicture group-layout %}{% endgrouppicture %} +// Alias: {% gp group-layout %}{% endgp %} + +function groupPicture(args, content) { + args = args[0].split('-'); + var group = parseInt(args[0]); + var layout = parseInt(args[1]); + + content = hexo.render.renderSync({text: content, engine: 'markdown'}); + + var pictures = content.match(//g); + + return '
    ' + + templates.dispatch(pictures, group, layout) + + '
    '; +} + +var templates = { + + dispatch: function (pictures, group, layout) { + var fn = 'group' + group + 'Layout' + layout; + fn = templates[fn] || templates.defaults; + return fn.call(templates, pictures); + }, + + /** + * 2-1 + * + * □ + * □ + * + * @param pictures + * @returns {string} + */ + group2Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1) + ]); + }, + + /** + * 2-2 + * + * □ □ + * + * @param pictures + */ + group2Layout2: function (pictures) { + return this.getHTML(pictures); + }, + + /** + * 3-1 + * + * □ □ □ + * + * @param pictures + */ + group3Layout1: function (pictures) { + return this.getHTML(pictures); + }, + + /** + * 3-2 + * + * □ + * □ □ + * + * @param pictures + */ + group3Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1) + ]); + }, + + /** + * 3-3 + * + * □ □ + * □ + * + * @param pictures + */ + group3Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2) + ]); + }, + + /** + * 4-1 + * + * □ + * □ □ + * □ + * + * @param pictures + */ + group4Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3) + ]); + }, + + /** + * 4-2 + * + * □ + * □ □ □ + * + * @param pictures + */ + group4Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1) + ]); + }, + + /** + * 4-3 + * + * □ □ + * □ □ + * + * @param pictures + */ + group4Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2) + ]); + }, + + /** + * 4-4 + * + * □ □ □ + * □ + * + * @param pictures + */ + group4Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3) + ]); + }, + + /** + * 5-1 + * + * □ + * □ □ + * □ □ + * + * @param pictures + */ + group5Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3) + ]); + }, + + /** + * 5-2 + * + * □ □ + * □ + * □ □ + * + * @param pictures + */ + group5Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 3), + pictures.slice(3) + ]); + }, + + /** + * 5-3 + * + * □ □ + * □ □ □ + * + * @param pictures + */ + group5Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2) + ]); + }, + + /** + * 5-4 + * + * □ □ □ + * □ □ + * + * @param pictures + */ + group5Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3) + ]); + }, + + /** + * 6-1 + * + * □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group6Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3) + ]); + }, + + /** + * 6-2 + * + * □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group6Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 4), + pictures.slice(4) + ]); + }, + + /** + * 6-3 + * + * □ □ + * □ + * □ □ □ + * + * @param pictures + */ + group6Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 3), + pictures.slice(3) + ]); + }, + + /** + * 6-4 + * + * □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group6Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4) + ]); + }, + + /** + * 6-5 + * + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group6Layout5: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3) + ]); + }, + + /** + * 7-1 + * + * □ + * □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group7Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3, 5), + pictures.slice(5) + ]); + }, + + /** + * 7-2 + * + * □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group7Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 4), + pictures.slice(4) + ]); + }, + + /** + * 7-3 + * + * □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group7Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4) + ]); + }, + + /** + * 7-4 + * + * □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group7Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 5), + pictures.slice(5) + ]); + }, + + /** + * 7-5 + * + * □ □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group7Layout5: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 5), + pictures.slice(5) + ]); + }, + + /** + * 8-1 + * + * □ + * □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group8Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3, 5), + pictures.slice(5) + ]); + }, + + /** + * 8-2 + * + * □ + * □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group8Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3, 6), + pictures.slice(6) + ]); + }, + + /** + * 8-3 + * + * □ + * □ □ □ + * □ □ + * □ □ + * @param pictures + */ + group8Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 4), + pictures.slice(4, 6), + pictures.slice(6) + ]); + }, + + /** + * 8-4 + * + * □ □ + * □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group8Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4, 6), + pictures.slice(6) + ]); + }, + + /** + * 8-5 + * + * □ □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group8Layout5: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 5), + pictures.slice(5) + ]); + }, + + /** + * 8-6 + * + * □ □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group8Layout6: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 5), + pictures.slice(5) + ]); + }, + + /** + * 8-7 + * + * □ □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group8Layout7: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 6), + pictures.slice(6) + ]); + }, + + /** + * 9-1 + * + * □ + * □ □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group9Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 3), + pictures.slice(3, 6), + pictures.slice(6) + ]); + }, + + /** + * 9-2 + * + * □ + * □ □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group9Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 4), + pictures.slice(4, 6), + pictures.slice(6) + ]); + }, + + /** + * 9-3 + * + * □ □ + * □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group9Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4, 6), + pictures.slice(6) + ]); + }, + + /** + * 9-4 + * + * □ □ + * □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group9Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4, 7), + pictures.slice(7) + ]); + }, + + /** + * 9-5 + * + * □ □ + * □ □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group9Layout5: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 5), + pictures.slice(5, 7), + pictures.slice(7) + ]); + }, + + /** + * 9-6 + * + * □ □ □ + * □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group9Layout6: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 5), + pictures.slice(5, 7), + pictures.slice(7) + ]); + }, + + /** + * 9-7 + * + * □ □ □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group9Layout7: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 6), + pictures.slice(6) + ]); + }, + + /** + * 10-1 + * + * □ + * □ □ □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group10Layout1: function (pictures) { + return this.getHTML([ + pictures.slice(0, 1), + pictures.slice(1, 4), + pictures.slice(4, 7), + pictures.slice(7) + ]); + }, + + /** + * 10-2 + * + * □ □ + * □ □ + * □ □ □ + * □ □ □ + * + * @param pictures + */ + group10Layout2: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 4), + pictures.slice(4, 7), + pictures.slice(7) + ]); + }, + + /** + * 10-3 + * + * □ □ + * □ □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group10Layout3: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 5), + pictures.slice(5, 7), + pictures.slice(7) + ]); + }, + + /** + * 10-4 + * + * □ □ + * □ □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group10Layout4: function (pictures) { + return this.getHTML([ + pictures.slice(0, 2), + pictures.slice(2, 5), + pictures.slice(5, 8), + pictures.slice(8) + ]); + }, + + /** + * 10-5 + * + * □ □ □ + * □ □ + * □ □ + * □ □ □ + * + * @param pictures + */ + group10Layout5: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 5), + pictures.slice(5, 7), + pictures.slice(7) + ]); + }, + + /** + * 10-6 + * + * □ □ □ + * □ □ + * □ □ □ + * □ □ + * + * @param pictures + */ + group10Layout6: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 5), + pictures.slice(5, 8), + pictures.slice(8) + ]); + }, + + /** + * 10-7 + * + * □ □ □ + * □ □ □ + * □ □ + * □ □ + * + * @param pictures + */ + group10Layout7: function (pictures) { + return this.getHTML([ + pictures.slice(0, 3), + pictures.slice(3, 6), + pictures.slice(6, 8), + pictures.slice(8) + ]); + }, + + /** + * Defaults Layout + * + * □ □ □ + * □ □ □ + * ... + * + * @param pictures + */ + defaults: function (pictures) { + var ROW_SIZE = 3; + var rows = pictures.length / ROW_SIZE + 1; + var pictureArr = []; + + for (var i = 0; i < rows; i++) { + pictureArr.push(pictures.slice(i * ROW_SIZE, (i + 1) * ROW_SIZE)); + } + + return this.getHTML(pictureArr); + }, + + getHTML: function (rows) { + var rowHTML = ''; + + for (var i = 0; i < rows.length; i++) { + rowHTML += this.getRowHTML(rows[i]); + } + + return '
    ' + rowHTML + '
    '; + }, + + getRowHTML: function (pictures) { + return ( + '
    ' + + this.getColumnHTML(pictures) + + '
    ' + ); + }, + + getColumnHTML: function (pictures) { + var columns = []; + var columnWidth = 100 / pictures.length; + var columnStyle = ' style="width: ' + columnWidth + '%;"'; + + for (var i = 0; i < pictures.length; i++) { + columns.push('
    ' + pictures[i] + '
    '); + } + return columns.join(''); + } +}; + +hexo.extend.tag.register('grouppicture', groupPicture, {ends: true}); +hexo.extend.tag.register('gp', groupPicture, {ends: true}); diff --git a/themes/next-5.1.4/scripts/tags/label.js b/themes/next-5.1.4/scripts/tags/label.js new file mode 100644 index 0000000..57e54dd --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/label.js @@ -0,0 +1,23 @@ +/** + * label.js | global hexo script. + * + * Usage: + * + * {% label [class]@Text %} + * + * [class] : default | primary | success | info | warning | danger. + * If not defined, default class will be selected. + */ + +function postLabel (args) { + args = args.join(' ').split('@'); + var classes = args[0] || 'default'; + var text = args[1] || ''; + + classes = classes.trim(); + !text && hexo.log.warn('Label text must be defined!'); + + return '' + text + ''; +} + +hexo.extend.tag.register('label', postLabel, { ends: false }); diff --git a/themes/next-5.1.4/scripts/tags/lazy-image.js b/themes/next-5.1.4/scripts/tags/lazy-image.js new file mode 100644 index 0000000..650d57a --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/lazy-image.js @@ -0,0 +1,26 @@ +/* global hexo */ +// Usage: {% lazyimage /path/to/image, alt, title %} +// Alias: {% li /path/to/image, alt, title %} + +function lazyImage(args) { + args = args.join(' ').split(','); + var src = args[0]; + var alt = args[1] || ''; + var title = args[2] || ''; + + if (!src) { + hexo.log.warn('Image src can NOT be empty'); + } + alt = alt.trim(); + title = title.trim(); + + var image = [' 0 && image.push('alt="' + alt + '"'); + title.length > 0 && image.push('title="' + title + '"'); + image.push('/>'); + + return image.join(' '); +} + +hexo.extend.tag.register('lazyimage', lazyImage); +hexo.extend.tag.register('li', lazyImage); diff --git a/themes/next-5.1.4/scripts/tags/note.js b/themes/next-5.1.4/scripts/tags/note.js new file mode 100644 index 0000000..a5690a3 --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/note.js @@ -0,0 +1,20 @@ +/** + * note.js | global hexo script. + * + * ATTENTION! No need to write this tag in 1 line if u don't want see probally bugs. + * + * Usage: + * + * {% note [class] %} + * Any content (support inline tags too). + * {% endnote %} + * + * [class] : default | primary | success | info | warning | danger. + * May be not defined. + */ + +function bscallOut (args, content) { + return '
    ' + hexo.render.renderSync({text: content, engine: 'markdown'}).trim() + '
    '; +} + +hexo.extend.tag.register('note', bscallOut, {ends: true}); diff --git a/themes/next-5.1.4/scripts/tags/tabs.js b/themes/next-5.1.4/scripts/tags/tabs.js new file mode 100644 index 0000000..9af8f68 --- /dev/null +++ b/themes/next-5.1.4/scripts/tags/tabs.js @@ -0,0 +1,78 @@ +/** + * tabs.js | global hexo script. + * + * Usage: + * + * {% tabs [Unique name], [index] %} + * + * Any content (support inline tags too). + * + * {% endtabs %} + * + * [Unique name] : Unique name of tabs block tag without comma. + * Will be used in #id's as prefix for each tab with their index numbers. + * If there are whitespaces in name, for generate #id all whitespaces will replaced by dashes. + * Only for current url of post/page must be unique! + * [index] : Index number of active tab. + * If not defined, first tab (1) will be selected. + * If index is -1, no tab will be selected. It's will be something like spoiler. + * May be not defined. + * [Tab caption] : Caption of current tab. + * If not caption specified, unique name with tab index suffix will be used as caption of tab. + * If not caption specified, but specified icon, caption will empty. + * May be not defined. + * [icon] : Font awesome icon. + * May be not defined. + */ + +'use strict'; + + function postTabs (args, content) { + var tabBlock = /\n([\w\W\s\S]*?)/g; + + var args = args.join(' ').split(','); + var tabName = args[0]; + var tabActive = args[1] || ''; + + var matches = []; + var match; + var tabId = 0; + var tabNav = ''; + var tabContent = ''; + + !tabName && hexo.log.warn('Tabs block must have unique name!'); + + while (match = tabBlock.exec(content)) { + matches.push(match[1]); + matches.push(match[2]); + } + + for (var i = 0; i < matches.length; i += 2) { + var tabParameters = matches[i].split('@'); + var postContent = matches[i + 1]; + var tabCaption = tabParameters[0] || ''; + var tabIcon = tabParameters[1] || ''; + var tabHref = ''; + + postContent = hexo.render.renderSync({text: postContent, engine: 'markdown'}); + + tabId += 1; + tabHref = (tabName + ' ' + tabId).toLowerCase().split(' ').join('-'); + + ((tabCaption.length === 0) && (tabIcon.length === 0)) && (tabCaption = tabName + ' ' + tabId); + + var isOnlyicon = (tabIcon.length > 0 && tabCaption.length === 0) ? 'style="text-align: center;' : ''; + tabIcon.length > 0 && (tabIcon = ''); + + var isActive = ((tabActive.length > 0 && tabActive == tabId) || (tabActive.length === 0 && tabId == 1)) ? ' active' : ''; + tabNav += '
  • ' + tabIcon + tabCaption + '
  • '; + tabContent += '
    ' + postContent + '
    '; + } + + tabNav = ''; + tabContent = '
    ' + tabContent + '
    '; + + return '
    ' + tabNav + tabContent + '
    '; + } + + hexo.extend.tag.register('tabs', postTabs, {ends: true}); diff --git a/themes/next-5.1.4/source/css/_common/components/back-to-top-sidebar.styl b/themes/next-5.1.4/source/css/_common/components/back-to-top-sidebar.styl new file mode 100644 index 0000000..d23d35d --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/back-to-top-sidebar.styl @@ -0,0 +1,25 @@ +.back-to-top { + display: none; + margin: 20px -10px -20px; + background: $body-bg-color; + font-size: $b2t-font-size; + opacity: $b2t-opacity; + cursor: pointer; + text-align: center; + -webkit-transform: translateZ(0); + the-transition(); + &:hover { opacity: 0.8; } + + +tablet() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } + +mobile() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } + + &.back-to-top-on { + display: block; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/back-to-top.styl b/themes/next-5.1.4/source/css/_common/components/back-to-top.styl new file mode 100644 index 0000000..1ae463a --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/back-to-top.styl @@ -0,0 +1,31 @@ +.back-to-top { + box-sizing: border-box; + position: fixed; + bottom: $b2t-position-bottom; + right: $b2t-position-right; + z-index: $zindex-5; + padding: 0 6px; + width: hexo-config('sidebar.scrollpercent') ? initial : 24px; + background: $b2t-bg-color; + font-size: $b2t-font-size; + opacity: $b2t-opacity; + color: $b2t-color; + cursor: pointer; + text-align: center; + -webkit-transform: translateZ(0); + transition-property: bottom; + the-transition(); + + +tablet() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } + +mobile() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } + + &.back-to-top-on { + bottom: $b2t-position-bottom-on; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/buttons.styl b/themes/next-5.1.4/source/css/_common/components/buttons.styl new file mode 100644 index 0000000..7712646 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/buttons.styl @@ -0,0 +1,38 @@ +.btn { + display: inline-block; + padding: 0 20px; + font-size: $btn-default-font-size; + color: $btn-default-color; + background: $btn-default-bg; + border: $btn-default-border-width solid $btn-default-border-color; + text-decoration: none; + border-radius: $btn-default-radius; + transition-property: background-color; + the-transition(); + line-height: 2; + + &:hover { + border-color: $btn-default-hover-border-color; + color: $btn-default-hover-color; + background: $btn-default-hover-bg; + } + + +.btn { + margin: 0 0 8px 8px; + } + + .fa-fw { + width: (18em / 14); + text-align: left; + } +} + +.btn-bar { + display: block; + width: 22px; + height: 2px; + background: $text-color; + border-radius: 1px; + + &+.btn-bar { margin-top: 4px; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/comments.styl b/themes/next-5.1.4/source/css/_common/components/comments.styl new file mode 100644 index 0000000..bf3edb9 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/comments.styl @@ -0,0 +1 @@ +.comments { margin: 60px 20px 0; } diff --git a/themes/next-5.1.4/source/css/_common/components/components.styl b/themes/next-5.1.4/source/css/_common/components/components.styl new file mode 100644 index 0000000..fe4a160 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/components.styl @@ -0,0 +1,16 @@ +@import "highlight"; +@import "tags"; + +@import "buttons"; +@import "pagination"; +@import "comments"; +@import "tag-cloud"; +@import hexo-config('sidebar.b2t') ? "back-to-top-sidebar" : "back-to-top"; + +@import "header"; +@import "post"; +@import "sidebar"; +@import "footer"; +@import "third-party"; + +@import "pages"; diff --git a/themes/next-5.1.4/source/css/_common/components/footer/footer.styl b/themes/next-5.1.4/source/css/_common/components/footer/footer.styl new file mode 100644 index 0000000..af7ce8c --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/footer/footer.styl @@ -0,0 +1,30 @@ +.footer { + font-size: 14px; + color: $grey-dark; + + img { border: none; } +} + +.footer-inner { text-align: center; } + +.with-love { + display: inline-block; + margin: 0 5px; +} + +.powered-by, +.theme-info { display: inline-block; } + +.cc-license { + margin-top: 10px; + text-align: center; + + .cc-opacity { + opacity: 0.7; + border-bottom: none; + + &:hover { opacity: 0.9; } + } + + img { display: inline-block; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/header/header.styl b/themes/next-5.1.4/source/css/_common/components/header/header.styl new file mode 100644 index 0000000..01f7f8a --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/header/header.styl @@ -0,0 +1,9 @@ +.header { background: $head-bg; } + +.header-inner { position: relative; } + + +@import "headerband"; +@import "site-meta"; +@import "site-nav"; +@import "menu"; diff --git a/themes/next-5.1.4/source/css/_common/components/header/headerband.styl b/themes/next-5.1.4/source/css/_common/components/header/headerband.styl new file mode 100644 index 0000000..382dbd9 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/header/headerband.styl @@ -0,0 +1,4 @@ +.headband { + height: $headband-height; + background: $headband-bg; +} diff --git a/themes/next-5.1.4/source/css/_common/components/header/menu.styl b/themes/next-5.1.4/source/css/_common/components/header/menu.styl new file mode 100644 index 0000000..d2b0f05 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/header/menu.styl @@ -0,0 +1,32 @@ +// Menu +// -------------------------------------------------- +.menu { + margin-top: 20px; + padding-left: 0; + text-align: center; +} + +.menu .menu-item { + display: inline-block; + margin: 0 10px; + list-style: none; + + @media screen and (max-width: 767px) { + margin-top: 10px; + } + + a { + display: block; + font-size: 13px; + line-height: inherit; + border-bottom: 1px solid $menu-link-border; + transition-property: border-color; + the-transition(); + + &:hover { border-bottom-color: $menu-link-hover-border; } + } + + .fa { margin-right: 5px; } +} + +.use-motion .menu-item { opacity: 0; } diff --git a/themes/next-5.1.4/source/css/_common/components/header/site-meta.styl b/themes/next-5.1.4/source/css/_common/components/header/site-meta.styl new file mode 100644 index 0000000..efe31ec --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/header/site-meta.styl @@ -0,0 +1,48 @@ +.site-meta { + margin: 0; + text-align: $site-meta-text-align; + + +mobile() { text-align: center; } +} + +.brand { + position: relative; + display: inline-block; + padding: 0 40px; + color: $brand-color; + background: $brand-bg; + border-bottom: none; + &:hover { color: $brand-hover-color; } +} + +.logo { + display: inline-block; + margin-right: 5px; + line-height: 36px; + vertical-align: top; +} + +.site-title { + display: inline-block; + vertical-align: top; + line-height: 36px; + font-size: $logo-font-size; + font-weight: normal; + font-family: $font-family-logo; +} + +.site-subtitle { + margin-top: 10px; + font-size: $subtitle-font-size; + color: $subtitle-color; +} + +.use-motion { + .brand { opacity: 0; } + + .logo, .site-title, .site-subtitle { + opacity: 0; + position: relative; + top: -10px; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/header/site-nav.styl b/themes/next-5.1.4/source/css/_common/components/header/site-nav.styl new file mode 100644 index 0000000..c6446e7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/header/site-nav.styl @@ -0,0 +1,28 @@ +.site-nav-toggle { + display: none; + position: absolute; + top: 10px; + left: 10px; + +mobile() { + display: block; + } + + button { + margin-top: 2px; + padding: 9px 10px; + background: transparent; + border: none; + } +} + +.site-nav { + +mobile() { + display: none; + margin: 0 -10px; + padding: 0 10px; + clear: both; + border-top: 1px solid $gray-lighter; + } + +tablet() { display: block !important; } + +desktop() { display: block !important; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/highlight/diff.styl b/themes/next-5.1.4/source/css/_common/components/highlight/diff.styl new file mode 100644 index 0000000..f779499 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/highlight/diff.styl @@ -0,0 +1,8 @@ +$highlight_theme = hexo-config("highlight_theme") + +if $highlight_theme == "normal" + $highlight-deletion = #fdd + $highlight-addition = #dfd +else + $highlight-deletion = #008000 + $highlight-addition = #800000 diff --git a/themes/next-5.1.4/source/css/_common/components/highlight/highlight.styl b/themes/next-5.1.4/source/css/_common/components/highlight/highlight.styl new file mode 100644 index 0000000..6b540fd --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/highlight/highlight.styl @@ -0,0 +1,177 @@ +// https://github.com/chriskempson/tomorrow-theme + +@require "theme" +@require "diff" + +// Placeholder: $code-block +$code-block { + overflow: auto; + margin: 20px 0; + padding: 0; + font-size $code-font-size; + color: $highlight-foreground; + background: $highlight-background; + line-height: $line-height-code-block; +} + +pre, code { font-family: $code-font-family; } + +code { + padding: 2px 4px; + word-wrap: break-word; + color: $code-foreground; + background: $code-background; + border-radius: $code-border-radius; + font-size $code-font-size; +} + +pre { + @extend $code-block; + padding: 10px; + + code { + padding: 0; + color: $highlight-foreground; + background: none; + text-shadow: none; + } +} + +.highlight { + @extend $code-block; + border-radius: 1px + + pre { + border: none; + margin: 0; + padding: 10px 0; + } + + table { + margin: 0; + width: auto; + border: none; + } + + td { + border: none; + padding: 0; + } + + figcaption { + clearfix(); + font-size: 1em; + color: $highlight-foreground; + line-height: 1em; + margin-bottom: 1em; + + a { + float: right; + color: $highlight-foreground; + + &:hover { border-bottom-color: $highlight-foreground; } + } + } + + .gutter pre { + padding-left: 10px + padding-right: 10px + color: $highlight-gutter.color + text-align: right + background-color: $highlight-gutter.bg-color + } + + .code pre { + width: 100% + padding-left: 10px + padding-right: 10px + background-color: $highlight-background + } + + .line { height: 20px; } +} + + +.gutter { + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.gist table { + width: auto; + + td { border: none; } +} + +// For diff highlight +pre .deletion { background: $highlight-deletion; } +pre .addition { background: $highlight-addition; } +pre .meta { color: $highlight-purple; } + +pre { + + .comment { color: $highlight-comment; } + + .variable + .attribute + .tag + .regexp + .ruby .constant + .xml .tag .title + .xml .pi + .xml .doctype + .html .doctype + .css .id + .css .class + .css .pseudo { + color: $highlight-red; + } + + .number + .preprocessor + .built_in + .literal + .params + .constant + .command { + color: $highlight-orange; + } + + .ruby .class .title + .css .rules .attribute + .string + .value + .inheritance + .header + .ruby .symbol + .xml .cdata + .special + .number + .formula { + color: $highlight-green; + } + + .title + .css .hexcolor { + color: $highlight-aqua; + } + + .function + .python .decorator + .python .title + .ruby .function .title + .ruby .title .keyword + .perl .sub + .javascript .title + .coffeescript .title { + color: $highlight-blue; + } + + .keyword + .javascript .function { + color: $highlight-purple; + } + +} diff --git a/themes/next-5.1.4/source/css/_common/components/highlight/theme.styl b/themes/next-5.1.4/source/css/_common/components/highlight/theme.styl new file mode 100644 index 0000000..ff1f4be --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/highlight/theme.styl @@ -0,0 +1,92 @@ +$highlight_theme = hexo-config("highlight_theme") + + +if $highlight_theme == "normal" + $highlight-background = #f7f7f7 + $highlight-current-line = #efefef + $highlight-selection = #d6d6d6 + $highlight-foreground = #4d4d4c + $highlight-comment = #8e908c + $highlight-red = #c82829 + $highlight-orange = #f5871f + $highlight-yellow = #eab700 + $highlight-green = #718c00 + $highlight-aqua = #3e999f + $highlight-blue = #4271ae + $highlight-purple = #8959a8 + $highlight-gutter = { + color: #869194, + bg-color: #eff2f3 + } + +if $highlight_theme == "night" + $highlight-background = #1d1f21 + $highlight-current-line = #282a2e + $highlight-selection = #373b41 + $highlight-foreground = #c5c8c6 + $highlight-comment = #969896 + $highlight-red = #cc6666 + $highlight-orange = #de935f + $highlight-yellow = #f0c674 + $highlight-green = #b5bd68 + $highlight-aqua = #8abeb7 + $highlight-blue = #81a2be + $highlight-purple = #b294bb + $highlight-gutter = { + color: lighten($highlight-background, 50%), + bg-color: darken($highlight-background, 100%) + } + +if $highlight_theme == "night eighties" + $highlight-background = #2d2d2d + $highlight-current-line = #393939 + $highlight-selection = #515151 + $highlight-foreground = #cccccc + $highlight-comment = #999999 + $highlight-red = #f2777a + $highlight-orange = #f99157 + $highlight-yellow = #ffcc66 + $highlight-green = #99cc99 + $highlight-aqua = #66cccc + $highlight-blue = #6699cc + $highlight-purple = #cc99cc + $highlight-gutter = { + color: $highlight-comment, + bg-color: darken($highlight-background, 40%) + } + +if $highlight_theme == "night blue" + $highlight-background = #002451 + $highlight-current-line = #00346e + $highlight-selection = #003f8e + $highlight-foreground = #ffffff + $highlight-comment = #7285b7 + $highlight-red = #ff9da4 + $highlight-orange = #ffc58f + $highlight-yellow = #ffeead + $highlight-green = #d1f1a9 + $highlight-aqua = #99ffff + $highlight-blue = #bbdaff + $highlight-purple = #ebbbff + $highlight-gutter = { + color: $highlight-comment, + bg-color: darken($highlight-background, 60%) + } + +if $highlight_theme == "night bright" + $highlight-background = #000000 + $highlight-current-line = #2a2a2a + $highlight-selection = #424242 + $highlight-foreground = #eaeaea + $highlight-comment = #969896 + $highlight-red = #d54e53 + $highlight-orange = #e78c45 + $highlight-yellow = #e7c547 + $highlight-green = #b9ca4a + $highlight-aqua = #70c0b1 + $highlight-blue = #7aa6da + $highlight-purple = #c397d8 + $highlight-gutter = { + color: lighten($highlight-background, 40%), + bg-color: lighten($highlight-background, 16%) + } diff --git a/themes/next-5.1.4/source/css/_common/components/pages/archive.styl b/themes/next-5.1.4/source/css/_common/components/pages/archive.styl new file mode 100644 index 0000000..8a1363d --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pages/archive.styl @@ -0,0 +1,29 @@ +.page-archive { + + .archive-page-counter { + position: relative; + top: 3px; + left: 20px; + + +mobile() { + top: 5px; + } + } + + .posts-collapse { + + .archive-move-on { + position: absolute; + top: 11px; + left: 0; + margin-left: -6px; + width: 10px; + height: 10px; + opacity: 0.5; + background: $black-light; + border: 1px solid white; + + circle(); + } + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/pages/categories.styl b/themes/next-5.1.4/source/css/_common/components/pages/categories.styl new file mode 100644 index 0000000..db3bb10 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pages/categories.styl @@ -0,0 +1,27 @@ +.category-all-page { + .category-all-title { text-align: center; } + + .category-all { margin-top: 20px; } + + .category-list { + margin: 0; + padding: 0; + list-style: none; + } + + .category-list-item { margin: 5px 10px; } + + .category-list-count { + color: $grey; + &:before { + display: inline; + content: " (" + } + &:after { + display: inline; + content: ") " + } + } + + .category-list-child { padding-left: 10px; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/pages/pages.styl b/themes/next-5.1.4/source/css/_common/components/pages/pages.styl new file mode 100644 index 0000000..cb14d04 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pages/pages.styl @@ -0,0 +1,6 @@ +// Page specific styles + +@import "archive"; +@import "categories"; +@import "schedule"; +@import "post-detail"; diff --git a/themes/next-5.1.4/source/css/_common/components/pages/post-detail.styl b/themes/next-5.1.4/source/css/_common/components/pages/post-detail.styl new file mode 100644 index 0000000..3f26afd --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pages/post-detail.styl @@ -0,0 +1,6 @@ +.page-post-detail { + + .sidebar-toggle-line { background: $sidebar-highlight; } + + .comments { overflow: hidden; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/pages/schedule.styl b/themes/next-5.1.4/source/css/_common/components/pages/schedule.styl new file mode 100644 index 0000000..18ec933 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pages/schedule.styl @@ -0,0 +1,101 @@ +@keyframes dot-flash { + from {opacity: 1; transform:scale(1.1);} + to {opacity: 0; transform:scale(1);} +} + +#schedule { + ul#event-list { + padding-left: 30px + hr { + margin: 20px 0 45px 0!important + background: #222 + &:after { + display: inline-block + content: 'NOW' + background: #222 + color: #FFF + font-weight:bold + text-align: right + padding: 0 5px + } + } + li.event { + margin: 20px 0px + background: #F9F9F9 + padding-left: 10px + min-height: 40px + h2.event-summary { + margin: 0 + padding-bottom: 3px + &:before { + display: inline-block + font-family: FontAwesome + font-size: 8px + content: '\f111' + vertical-align: middle + margin-right: 25px + color: #bbb + } + } + span.event-relative-time { + display: inline-block + font-size: 12px + font-weight: 400 + padding-left: 12px + color: #bbb + } + span.event-details { + display: block + color: #bbb + margin-left: 56px + padding-top: 3px + padding-bottom: 6px + text-indent: -24px + line-height: 18px + &:before { + text-indent: 0 + display: inline-block + width: 14px + font-family: FontAwesome + text-align: center + margin-right: 9px + color: #bbb + } + &.event-location:before { + content: '\f041' + } + &.event-duration:before { + content: '\f017' + } + } + } + li.event-past { + background: #FCFCFC + & > * { + opacity: .6 + } + h2.event-summary { + color: #bbb + &:before { + color: #DFDFDF + } + } + } + li.event-now { + background: #222 + color: #FFF + padding: 15px 0 15px 10px + h2.event-summary { + &:before { + transform: scale(1.2) + color: #FFF + animation: dot-flash 1s alternate infinite ease-in-out; + } + } + * { + color: #FFF!important + } + } + } +} + diff --git a/themes/next-5.1.4/source/css/_common/components/pagination.styl b/themes/next-5.1.4/source/css/_common/components/pagination.styl new file mode 100644 index 0000000..a054ef0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/pagination.styl @@ -0,0 +1,56 @@ +.pagination { + margin: 120px 0 40px; + text-align: center; + border-top: 1px solid $pagination-border; +} + +.page-number-basic { + display: inline-block; + position: relative; + top: -1px; + margin: 0 10px; + padding: 0 11px; + + +mobile() { margin: 0 5px; } +} + +.pagination { + .prev, .next, .page-number { + @extend .page-number-basic; + border-bottom: 0; + border-top: 1px solid $pagination-link-border; + transition-property: border-color; + the-transition(); + + &:hover { border-top-color: $pagination-link-hover-border; } + } + + .space { + @extend .page-number-basic; + padding: 0; + margin: 0; + } + + .prev { margin-left: 0; } + .next { margin-right: 0; } + + .page-number.current { + color: $pagination-active-color; + background: $pagination-active-bg; + border-top-color: $pagination-active-border; + } +} + +@media (max-width: 767px) + .pagination { border-top: none; } + + .pagination { + .prev, .next, .page-number { + margin-bottom: 10px; + border-top: 0; + border-bottom: 1px solid $pagination-link-border; + padding: 0 10px; + + &:hover { border-bottom-color: $pagination-link-hover-border; } + } + } diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-button.styl b/themes/next-5.1.4/source/css/_common/components/post/post-button.styl new file mode 100644 index 0000000..fd0809f --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-button.styl @@ -0,0 +1,3 @@ +.post-button { + margin-top: 40px; +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-collapse.styl b/themes/next-5.1.4/source/css/_common/components/post/post-collapse.styl new file mode 100644 index 0000000..6633a45 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-collapse.styl @@ -0,0 +1,111 @@ +// TODO: Refactor. + +@media (max-width: 767px) { + .posts-collapse { + margin: 0 20px; + + .post-title, .post-meta { + display: block; + width: auto; + text-align: left; + } + } +} + +.posts-collapse { + position: relative; + z-index: $zindex-1; + + &::after { + content: " "; + position: absolute; + top: 20px; + left: 0; + margin-left: -2px; + width: 4px; + height: 100%; + background: $whitesmoke; + z-index: $zindex-bottom; + } + + margin-left: $posts-collapse-left; + +mobile() { margin: 0 20px; } + + .collection-title { + position: relative; + margin: 60px 0; + + h1, h2 { margin-left: 20px; } + + small { color: $grey; margin-left: 5px; } + + &::before { + content: " "; + position: absolute; + left: 0; + top: 50%; + margin-left: -4px; + margin-top: -4px; + width: 8px; + height: 8px; + background: $grey; + circle(); + } + } + + .post { margin: 30px 0; } + + .post-header { + position: relative; + the-transition(); + transition-property: border; + border-bottom: 1px dashed $grey-light; + + &::before { + content: " "; + position: absolute; + left: 0; + top: 12px; + width: 6px; + height: 6px; + margin-left: -4px; + background: $grey; + circle(); + border: 1px solid white; + the-transition(); + transition-property: background; + } + } + + .post-header:hover { + border-bottom-color: $grey-dim; + + &::before { background: $black-deep; } + } + + .post-meta { + position: absolute; + font-size: 12px; + left: 20px; + top: 5px; + } + + .post-comments-count { display: none; } + + .post-title { + margin-left: 60px; + font-size: 16px; + font-weight: normal; + line-height: inherit; + + &::after { + margin-left: 3px; + opacity: 0.6; + } + + a { + color: $grey-dim; + border-bottom: none; + } + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-copyright.styl b/themes/next-5.1.4/source/css/_common/components/post/post-copyright.styl new file mode 100644 index 0000000..f1cc7cb --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-copyright.styl @@ -0,0 +1,7 @@ +.post-copyright { + margin: $post-copyright.margin; + padding: $post-copyright.padding; + border-left: $post-copyright.border.width $post-copyright.border.style $post-copyright.border.color; + background-color: $post-copyright.bg; + list-style: none; +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-eof.styl b/themes/next-5.1.4/source/css/_common/components/post/post-eof.styl new file mode 100644 index 0000000..e430325 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-eof.styl @@ -0,0 +1,17 @@ +.posts-expand { + .post-eof { + display: block; + margin: $post-eof-margin-top auto $post-eof-margin-bottom; + width: 8%; + height: 1px; + background: $grey-light; + text-align: center; + } +} + + +.post:last-child { + .post-eof.post-eof.post-eof { + display: none; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-expand.styl b/themes/next-5.1.4/source/css/_common/components/post/post-expand.styl new file mode 100644 index 0000000..8c6d8a5 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-expand.styl @@ -0,0 +1,64 @@ +// TODO: Refactor. + +.posts-expand { + padding-top: 40px; +} + +@media (max-width: 767px) { + .posts-expand { + margin: 0 20px; + } + + .post-body { + pre { + .gutter pre { + padding-right: 10px; + } + } + + .highlight { + margin-left: 0px; + margin-right: 0px; + padding: 0; + .gutter pre { + padding-right: 10px; + } + } + } +} + +.posts-expand .post-body { + +desktop() { text-align: justify; } + + + h2, h3, h4, h5, h6 { + padding-top: 10px; + + .header-anchor{ + float: right; + margin-left: 10px; + color: $grey-light; + border-bottom-style: none; + visibility: hidden; + + &:hover{ + color: inherit; + } + } + + &:hover .header-anchor{ + visibility: visible; + } + } + + ul li { list-style: circle; } + + img { + box-sizing: border-box; + margin: auto; + padding: 3px; + border: 1px solid $gray-lighter; + } +} + +.posts-expand .post-body .fancybox img { margin: 0 auto 25px; } diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-gallery.styl b/themes/next-5.1.4/source/css/_common/components/post/post-gallery.styl new file mode 100644 index 0000000..b2385ae --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-gallery.styl @@ -0,0 +1,23 @@ +.post-gallery { + display: table; + table-layout: fixed; + width: 100%; + border-collapse: separate; +} + +.post-gallery-row { display: table-row; } + +.post-gallery .post-gallery-img { + display: table-cell; + text-align: center; + vertical-align: middle; + border: none; +} + +.post-gallery .post-gallery-img img { + max-width: 100%; + max-height: 100%; + border: none; +} + +.fancybox-close, .fancybox-close:hover { border: none; } diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-meta.styl b/themes/next-5.1.4/source/css/_common/components/post/post-meta.styl new file mode 100644 index 0000000..d715203 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-meta.styl @@ -0,0 +1,49 @@ +.posts-expand .post-meta { + margin: 3px 0 60px 0; + color: $grey-dark; + font-family: $font-family-posts; + font-size: 12px; + text-align: center; + + .post-category-list { + display: inline-block; + margin: 0; + padding: 3px; + } + .post-category-list-link { color: $grey-dark; } + + .post-description { + font-size: 14px; + margin-top: 2px; + } +} + +.post-wordcount { + if !hexo-config('post_wordcount.separated_meta') { display: inline-block; } +} + +.post-meta-divider { + margin: 0 .5em; +} + +.post-meta-item-icon { + margin-right: 3px; + +tablet() { + display: inline-block; + } + +mobile() { + display: inline-block; + } +} +.post-meta-item-text { + +tablet() { + display: none; + } + +mobile() { + display: none; + } +} + +.posts-expand .post-comments-count { + +mobile() { display: none; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-nav.styl b/themes/next-5.1.4/source/css/_common/components/post/post-nav.styl new file mode 100644 index 0000000..fa85838 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-nav.styl @@ -0,0 +1,57 @@ +.post-nav { + display: table; + margin-top: 15px; + width: 100%; + border-top: 1px solid $gainsboro; +} + +.post-nav-divider { + display: table-cell; + width: 10%; +} + +.post-nav-item { + display: table-cell; + padding: 10px 0 0 0; + width: 45%; + vertical-align: top; + + a { + position: relative; + display: block; + line-height: 25px; + font-size: 14px; + color: $link-color; + border-bottom: none; + + &:hover { + color: $link-hover-color; + border-bottom: none; + } + + &:active { top: 2px; } + } + + .fa { + position: absolute; + top: 8px; + left: 0; + font-size: 12px; + } + +} + +.post-nav-next { + a { padding-left: 15px; } +} + +.post-nav-prev { + text-align: right; + + a { padding-right: 15px; } + + .fa { + right: 0; + left: auto; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-reward.styl b/themes/next-5.1.4/source/css/_common/components/post/post-reward.styl new file mode 100644 index 0000000..450a104 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-reward.styl @@ -0,0 +1,64 @@ +#rewardButton { + cursor: pointer; + border: 0; + outline: 0; + border-radius: 5px; + padding: 0; + margin: 0; + letter-spacing: normal; + text-transform: none; + text-indent: 0px; + text-shadow: none; +} +#rewardButton span { + display: inline-block; + width: 80px; + height: 35px; + border-radius: 5px; + color: #fff; + font-weight: 400; + font-style: normal; + font-variant: normal; + font-stretch: normal; + font-size: 18px; + font-family: "Microsoft Yahei"; + background: #F44336; +} +#rewardButton span:hover{ + background: #F7877F; +} +#QR{ + padding-top:20px; +} +#QR a{ + border:0; +} +#QR img{ + width: 180px; + max-width: 100%; + display: inline-block; + margin: 0.8em 2em 0 2em; +} +#wechat:hover p{ + animation: roll 0.1s infinite linear; + -webkit-animation: roll 0.1s infinite linear; + -moz-animation: roll 0.1s infinite linear; +} +#alipay:hover p{ + animation: roll 0.1s infinite linear; + -webkit-animation: roll 0.1s infinite linear; + -moz-animation: roll 0.1s infinite linear; +} +#bitcoin:hover p { + animation: roll 0.1s infinite linear; + -webkit-animation: roll 0.1s infinite linear; + -moz-animation: roll 0.1s infinite linear; +} +@keyframes roll { + from { + transform(rotateZ(30deg)); + } + to { + transform(rotateZ(-30deg)); + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-rtl.styl b/themes/next-5.1.4/source/css/_common/components/post/post-rtl.styl new file mode 100644 index 0000000..ea048b9 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-rtl.styl @@ -0,0 +1,11 @@ +.rtl { + &.post-body { + p, a, h1, h2, h3, h4, h5, h6, li, ul, ol { + direction: rtl; + font-family: UKIJ Ekran; + } + } + &.post-title { + font-family: UKIJ Ekran; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-tags.styl b/themes/next-5.1.4/source/css/_common/components/post/post-tags.styl new file mode 100644 index 0000000..8c04ec7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-tags.styl @@ -0,0 +1,10 @@ +.posts-expand .post-tags { + margin-top: 40px; + text-align: center; + + a { + display: inline-block; + margin-right: 10px; + font-size: 13px; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-title.styl b/themes/next-5.1.4/source/css/_common/components/post/post-title.styl new file mode 100644 index 0000000..dcd1c06 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-title.styl @@ -0,0 +1,33 @@ +.posts-expand .post-title { + text-align: center; + word-break: break-word; + font-weight: $posts-expand-title-font-weight +} +.posts-expand .post-title-link { + display: inline-block; + position: relative; + color: $black-light; + border-bottom: none; + line-height: 1.2; + vertical-align: top; + + &::before { + content: ""; + position: absolute; + width: 100%; + height: 2px; + bottom: 0; + left: 0; + background-color: #000; + visibility: hidden; + transform: scaleX(0); + the-transition(); + } + + &:hover::before { + visibility: visible; + transform: scaleX(1); + } + + .fa { font-size: 16px; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-type.styl b/themes/next-5.1.4/source/css/_common/components/post/post-type.styl new file mode 100644 index 0000000..c3d2510 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-type.styl @@ -0,0 +1,14 @@ +// TODO: Refactor. + +.page-home, .page-post-detail { + .post-type-quote { + .post-header, + .post-tags { + display: none; + } + + blockquote { + @extend .blockquote-center + } + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post-widgets.styl b/themes/next-5.1.4/source/css/_common/components/post/post-widgets.styl new file mode 100644 index 0000000..4914c5a --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post-widgets.styl @@ -0,0 +1,41 @@ +.post-widgets { + border-top: 1px solid #eee; + padding-top: 9px; + margin-top: 45px; + display: flex; + justify-content: center; + flex-wrap: wrap; + align-items: center; + + .post-meta-divider { + height: 28px; + color: $grey-dark; + } +} + +.wp_rating { + height: 20px; + margin-right: 10px; + text-align: center; + line-height: 20px; + padding-top: 6px; +} + +.social-like { + font-size: 14px; + text-align: center; + display: flex; + justify-content: center; +} + +.vk_like { + width: 85px; + height: 21px; + padding-top: 7px; + align-self: center; +} + +.fb_like { + height: 30px; + align-self: center; +} diff --git a/themes/next-5.1.4/source/css/_common/components/post/post.styl b/themes/next-5.1.4/source/css/_common/components/post/post.styl new file mode 100644 index 0000000..f8a05f7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/post/post.styl @@ -0,0 +1,60 @@ +.post-body { + font-family: $font-family-posts; + +mobile() { + word-break: break-word; + } +} + +.post-body .fancybox img { + display: block !important; + margin: 0 auto; + cursor: pointer; + cursor: zoom-in; + cursor: -webkit-zoom-in; +} + +.post-body .image-caption { + margin: -20px auto 15px; + text-align: center; + font-size: $font-size-base; + color: $grey-dark; + font-weight: bold; + line-height: 1; +} + +.post-body .figure .caption { + @extend .post-body .image-caption; +} + +.post-sticky-flag { + display: inline-block; + font-size: 16px; + -ms-transform: rotate(30deg); + transform: rotate(30deg); +} + +.use-motion { + if hexo-config('motion.transition.post_block') { + .post-block, + .pagination, + .comments { opacity: 0; } + } + if hexo-config('motion.transition.post_header') { .post-header { opacity: 0; } } + if hexo-config('motion.transition.post_body') { .post-body { opacity: 0; } } + if hexo-config('motion.transition.coll_header') { .collection-title { opacity: 0; } } +} + +@import "post-expand"; +@import "post-collapse"; +@import "post-type"; +@import "post-title"; +@import "post-meta"; +@import "post-button"; +@import "post-tags"; +@import "post-nav"; +@import "post-eof"; +@import "post-gallery"; +@import "post-reward" if hexo-config('alipay') or hexo-config('wechatpay') or hexo-config('bitcoin'); +@import "post-copyright" if hexo-config('post_copyright.enable'); +@import "post-widgets" if (hexo-config('facebook_sdk.enable') and hexo-config('facebook_sdk.like_button')) or (hexo-config('vkontakte_api.enable') and hexo-config('vkontakte_api.like')) or hexo-config('rating.enable') or (hexo-config('needmoreshare2.enable') and hexo-config('needmoreshare2.postbottom.enable')); +@import "post-rtl"; diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author-links.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author-links.styl new file mode 100644 index 0000000..227e839 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author-links.styl @@ -0,0 +1,23 @@ +.links-of-author { + margin-top: 20px; +} + +.links-of-author a { + display: inline-block; + vertical-align: middle; + margin-right: 10px; + margin-bottom: 10px; + border-bottom-color: $black-light; + font-size: 13px; + + &:before { + display: inline-block; + vertical-align: middle; + margin-right: 3px; + content: " "; + width: 4px; + height: 4px; + border-radius: 50%; + background: rgb(random-color(0, 255) - 50%, random-color(0, 255) - 50%, random-color(0, 255) - 50%); + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author.styl new file mode 100644 index 0000000..14ac717 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-author.styl @@ -0,0 +1,22 @@ +.site-author-image { + display: block; + margin: 0 auto; + padding: $site-author-image-padding; + max-width: $site-author-image-width; + height: $site-author-image-height; + border: $site-author-image-border-width solid $site-author-image-border-color; +} + +.site-author-name { + margin: $site-author-name-margin; + text-align: $site-author-name-align; + color: $site-author-name-color; + font-weight: $site-author-name-weight; +} + +.site-description { + margin-top: $site-description-margin-top; + text-align: $site-description-align; + font-size: $site-description-font-size; + color: $site-description-color; +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-blogroll.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-blogroll.styl new file mode 100644 index 0000000..b677e68 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-blogroll.styl @@ -0,0 +1,25 @@ +.links-of-blogroll { font-size: 13px; } + +.links-of-blogroll-title { + margin-top: 20px; + font-size: 14px; + font-weight: $font-weight-bold; +} +.links-of-blogroll-list { + margin: 0; + padding: 0; + list-style: none; +} + +.links-of-blogroll-item { + padding: 2px 10px; + + a { + max-width: 280px; + box-sizing: border-box; + display: inline-block; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-dimmer.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-dimmer.styl new file mode 100644 index 0000000..b2da3ce --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-dimmer.styl @@ -0,0 +1,21 @@ +.sidebar-active #sidebar-dimmer { + opacity: .7; + -webkit-transform: translateX(-150%); + transform: translateX(-150%); + transition: opacity .2s; +} + +#sidebar-dimmer { + display: none; + position: absolute; + top: 0; + left: 100%; + width: 200%; + height: 100%; + background: #000; + opacity: 0; + transition: opacity .2s,transform 0s .2s; + +mobile() { + display: block; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-feed-link.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-feed-link.styl new file mode 100644 index 0000000..b3868a8 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-feed-link.styl @@ -0,0 +1,23 @@ +.feed-link { + margin-top: 20px; + + a { + display: inline-block; + padding: 0 15px; + color: rgb(252, 100, 35); + border: 1px solid rgb(252, 100, 35); + border-radius: 4px; + + i { + color: rgb(252, 100, 35); + font-size: 14px; + } + + &:hover { + color:white; + background: rgb(252, 100, 35); + + i { color: white; } + } + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-nav.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-nav.styl new file mode 100644 index 0000000..973eda7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-nav.styl @@ -0,0 +1,29 @@ +// Sidebar Navigation + +.sidebar-nav { + margin: 0 0 20px; + padding-left: 0; +} +.sidebar-nav li { + display: inline-block; + cursor: pointer; + border-bottom: 1px solid transparent; + font-size: 14px; + color: $sidebar-nav-color; + + &:hover { color: $sidebar-nav-hover-color; } +} + +.page-post-detail .sidebar-nav-toc { padding: 0 5px; } + +.page-post-detail .sidebar-nav-overview { margin-left: 10px; } + +.sidebar-nav .sidebar-nav-active { + color: $sidebar-highlight; + border-bottom-color: $sidebar-highlight; + + &:hover { color: $sidebar-highlight; } +} + +.sidebar-panel { display: none; } +.sidebar-panel-active { display: block; } diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toc.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toc.styl new file mode 100644 index 0000000..27e15f0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toc.styl @@ -0,0 +1,60 @@ + +.post-toc-empty { + font-size: 14px; + color: $grey-dim; +} + +.post-toc-wrap { overflow: hidden; } + +.post-toc { overflow: auto; } + +.post-toc ol { + margin: 0; + padding: 0 2px 5px 10px; + text-align: left; + list-style: none; + font-size: 14px; + + & > ol { padding-left: 0; } + + a { + the-transition(); + transition-property: all; + color: $toc-link-color; + border-bottom-color: $toc-link-border-color; + + &:hover { + color: $toc-link-hover-color; + border-bottom-color: $toc-link-hover-border-color; + } + } +} + +.post-toc .nav-item { + overflow: hidden; + text-overflow: ellipsis; + text-align: justify; + white-space: nowrap if !hexo-config('toc.wrap'); + line-height: 1.8; +} + +.post-toc .nav .nav-child { display: none; } + +.post-toc .nav .active > .nav-child { display: block; } + +.post-toc .nav .active-current > .nav-child { + display: block; + & > .nav-item { display: block; } +} + +.post-toc .nav .active > a { + color: $toc-link-active-color; + border-bottom-color: $toc-link-active-border-color; +} + +.post-toc .nav .active-current > a { + color: $toc-link-active-current-color; + &:hover { + color: $toc-link-active-current-border-color; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toggle.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toggle.styl new file mode 100644 index 0000000..c4b6a06 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar-toggle.styl @@ -0,0 +1,36 @@ +.sidebar-toggle { + position: fixed; + right: $b2t-position-right; + bottom: 45px; + width: 14px; + height: 14px; + padding: 5px; + background: $black-deep; + line-height: 0; + z-index: $zindex-5; + cursor: pointer; + -webkit-transform: translateZ(0); + + +tablet() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } + +mobile() { + fixbutton() if hexo-config('sidebar.onmobile'); + hide() if not hexo-config('sidebar.onmobile'); + } +} + + + +.sidebar-toggle-line { + position: relative; + display: inline-block; + vertical-align: top; + height: 2px; + width: 100%; + background: white; + margin-top: 3px; + + &:first-child { margin-top: 0; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar.styl new file mode 100644 index 0000000..635cc94 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/sidebar.styl @@ -0,0 +1,52 @@ +.sidebar { + position: fixed; + right: 0; + top: 0; + bottom: 0; + + width: 0; + z-index: $zindex-4; + box-shadow: inset 0 2px 6px black; + background: $black-deep; + -webkit-transform: translateZ(0); // http://stackoverflow.com/questions/17079857/position-fixed-broken-in-chrome-with-flash-behind + + a { + color: $grey-dark; + border-bottom-color: $black-light; + &:hover { color: $gainsboro; } + } + + +tablet() { + hide() if not hexo-config('sidebar.onmobile'); + } + +mobile() { + hide() if not hexo-config('sidebar.onmobile'); + } + +} + +.sidebar-inner { + position: relative; + padding: 20px 10px; + color: $grey-dark; + text-align: center; +} + +.site-overview-wrap { + overflow: hidden; +} + +.site-overview { + overflow-y: auto; + overflow-x: hidden; +} + +@import "sidebar-toggle"; +@import "sidebar-author"; +@import "site-state"; +@import "sidebar-feed-link"; +@import "sidebar-author-links"; +@import "sidebar-blogroll"; +@import "sidebar-nav"; +@import "sidebar-toc"; +@import "sidebar-dimmer" if hexo-config('sidebar.onmobile'); diff --git a/themes/next-5.1.4/source/css/_common/components/sidebar/site-state.styl b/themes/next-5.1.4/source/css/_common/components/sidebar/site-state.styl new file mode 100644 index 0000000..c05b0ea --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/sidebar/site-state.styl @@ -0,0 +1,28 @@ +.site-state { + overflow: hidden; + line-height: 1.4; + white-space: nowrap; + text-align: $site-state-align; +} + +.site-state-item { + display: inline-block; + padding: 0 15px; + border-left: 1px solid $site-state-item-border-color; + + &:first-child { border-left: none; } + + a { border-bottom: none; } +} +.site-state-item-count { + display: block; + text-align: center; + color: $site-state-item-count-color; + font-weight: $font-weight-bold; + font-size: $site-state-item-count-font-size; +} + +.site-state-item-name { + font-size: $site-state-item-name-font-size; + color: $site-state-item-name-color; +} diff --git a/themes/next-5.1.4/source/css/_common/components/tag-cloud.styl b/themes/next-5.1.4/source/css/_common/components/tag-cloud.styl new file mode 100644 index 0000000..30b01c6 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tag-cloud.styl @@ -0,0 +1,8 @@ +.tag-cloud { + text-align: center; + + a { + display: inline-block; + margin: 10px; + } +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_common/components/tags/blockquote-center.styl b/themes/next-5.1.4/source/css/_common/components/tags/blockquote-center.styl new file mode 100644 index 0000000..b0f3bcc --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/blockquote-center.styl @@ -0,0 +1,33 @@ +// Blockquote with all children centered. +.blockquote-center { + position: relative; + margin: 40px 0; + padding: 0; + border-left: none; + text-align: center; + + &::before, &::after { + position: absolute; + content: ' '; + display: block; + width: 100%; + height: 24px; + opacity: 0.2; + background-repeat: no-repeat; + background-position: 0 -6px; + background-size: 22px 22px; + } + &::before { + top: -20px; + background-image: url($center-quote-left); + border-top: 1px solid $grey-light; + } + &::after { + bottom: -20px; + background-image: url($center-quote-right); + border-bottom: 1px solid $grey-light; + background-position: 100% 8px; + } + + p, div { text-align: center; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/exturl.styl b/themes/next-5.1.4/source/css/_common/components/tags/exturl.styl new file mode 100644 index 0000000..49a1684 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/exturl.styl @@ -0,0 +1,18 @@ +.exturl { + // Remove the gray background color from active links in IE 10. + background-color: transparent; + + cursor: pointer; + border-bottom: 1px solid #999; + + .fa { + font-size: 14px; + } +} + +// Improve readability when focused and also mouse hovered in all browsers. +.exturl:active, .exturl:hover { + outline: 0; + color: $black-deep; + border-bottom-color: $black-deep; +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/full-image.styl b/themes/next-5.1.4/source/css/_common/components/tags/full-image.styl new file mode 100644 index 0000000..11ae578 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/full-image.styl @@ -0,0 +1,12 @@ +// Expand image to 126% with nagative margin-left/right on Desktop. +.full-image.full-image.full-image.full-image { + border: none; + max-width: 100%; + width: auto; + margin: 20px auto 25px; + +desktop() { + max-width: none; + width: $full-image-width; + margin: $full-image-margin-vertical $full-image-margin-horizontal; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/group-pictures.styl b/themes/next-5.1.4/source/css/_common/components/tags/group-pictures.styl new file mode 100644 index 0000000..ce1461d --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/group-pictures.styl @@ -0,0 +1,35 @@ +.post .post-body .group-picture { + img { + box-sizing: border-box; + padding: 0 3px; + border: none; + } +} + +.post .group-picture-row { + overflow: hidden; + margin-top: 6px; + &:first-child { margin-top: 0; } +} + +.post .group-picture-column { float: left; } + +.page-post-detail .post-body .group-picture-column { + float: none; + margin-top: 10px; + width: auto !important; + img { margin: 0 auto; } +} + +.page-archive { + .group-picture-container { overflow: hidden; } + .group-picture-row { + float: left; + &:first-child { margin-top: 6px; } + } + + .group-picture-column { + max-width: 150px; + max-height: 150px; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/label.styl b/themes/next-5.1.4/source/css/_common/components/tags/label.styl new file mode 100644 index 0000000..541dd2d --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/label.styl @@ -0,0 +1,12 @@ +.post-body .label { + display: inline; + padding: 0 2px; + white-space: nowrap; + + &.default { background-color: $label-default; } + &.primary { background-color: $label-primary; } + &.info { background-color: $label-info; } + &.success { background-color: $label-success; } + &.warning { background-color: $label-warning; } + &.danger { background-color: $label-danger; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/note-modern.styl b/themes/next-5.1.4/source/css/_common/components/tags/note-modern.styl new file mode 100644 index 0000000..cf7659e --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/note-modern.styl @@ -0,0 +1,183 @@ +.post-body .note { + note_icons = hexo-config('note.icons'); + + position: relative; + padding: 15px; + margin-bottom: 20px; + + border: 1px solid transparent; + background-color: $whitesmoke; + border-radius: unit(hexo-config('note.border_radius'), px) if hexo-config('note.border_radius') is a 'unit'; + + h2, h3, h4, h5, h6 { + if note_icons { + margin-top: 3px; + } else { + margin-top: 0; + } + margin-bottom: 0; + border-bottom: initial; + padding-top: 0 !important; + } + + p, ul, ol, table, pre, blockquote { + &:first-child { + margin-top: 0; + } + &:last-child { + margin-bottom: 0; + } + } + + if note_icons { + &:not(.no-icon) { + padding-left: 45px; + &:before { + position: absolute; + font-family: 'FontAwesome'; + font-size: larger; + top: 13px; + left: 15px; + } + } + } + + &.default { + background-color: $note-modern-default-bg; + border-color: $note-modern-default-border; + color: $note-modern-default-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-default-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-default-text; + border-bottom: 1px solid $note-modern-default-text; + &:hover { + color: $note-modern-default-hover; + border-bottom: 1px solid $note-modern-default-hover; + } + } + } + } + + &.primary { + background-color: $note-modern-primary-bg; + border-color: $note-modern-primary-border; + color: $note-modern-primary-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-primary-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-primary-text; + border-bottom: 1px solid $note-modern-primary-text; + &:hover { + color: $note-modern-primary-hover; + border-bottom: 1px solid $note-modern-primary-hover; + } + } + } + } + + &.info { + background-color: $note-modern-info-bg; + border-color: $note-modern-info-border; + color: $note-modern-info-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-info-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-info-text; + border-bottom: 1px solid $note-modern-info-text; + &:hover { + color: $note-modern-info-hover; + border-bottom: 1px solid $note-modern-info-hover; + } + } + } + } + + &.success { + background-color: $note-modern-success-bg; + border-color: $note-modern-success-border; + color: $note-modern-success-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-success-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-success-text; + border-bottom: 1px solid $note-modern-success-text; + &:hover { + color: $note-modern-success-hover; + border-bottom: 1px solid $note-modern-success-hover; + } + } + } + } + + &.warning { + background-color: $note-modern-warning-bg; + border-color: $note-modern-warning-border; + color: $note-modern-warning-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-warning-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-warning-text; + border-bottom: 1px solid $note-modern-warning-text; + &:hover { + color: $note-modern-warning-hover; + border-bottom: 1px solid $note-modern-warning-hover; + } + } + } + } + + &.danger { + background-color: $note-modern-danger-bg; + border-color: $note-modern-danger-border; + color: $note-modern-danger-text; + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-danger-icon; + } + } + } + a { + &:not(.btn) { + color: $note-modern-danger-text; + border-bottom: 1px solid $note-modern-danger-text; + &:hover { + color: $note-modern-danger-hover; + border-bottom: 1px solid $note-modern-danger-hover; + } + } + } + } + +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/note.styl b/themes/next-5.1.4/source/css/_common/components/tags/note.styl new file mode 100644 index 0000000..4b234b0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/note.styl @@ -0,0 +1,161 @@ +.post-body .note { + note_style = hexo-config('note.style'); + note_icons = hexo-config('note.icons'); + + position: relative; + padding: 15px; + margin-bottom: 20px; + + if note_style == 'simple' { + border: 1px solid $gainsboro; + border-left-width: 5px; + } + if note_style == 'flat' { + border: initial; + border-left: 3px solid $gainsboro; + background-color: lighten($gainsboro, 65%); + } + border-radius: unit(hexo-config('note.border_radius'), px) if hexo-config('note.border_radius') is a 'unit'; + + h2, h3, h4, h5, h6 { + if note_icons { + margin-top: 3px; + } else { + margin-top: 0; + } + margin-bottom: 0; + border-bottom: initial; + padding-top: 0 !important; + } + + p, ul, ol, table, pre, blockquote { + &:first-child { + margin-top: 0; + } + &:last-child { + margin-bottom: 0; + } + } + + if note_icons { + &:not(.no-icon) { + padding-left: 45px; + &:before { + position: absolute; + font-family: 'FontAwesome'; + font-size: larger; + top: 13px; + left: 15px; + } + } + } + + &.default { + if note_style == 'flat' { + background-color: $note-default-bg; + } + border-left-color: $note-default-border; + h2, h3, h4, h5, h6 { + color: $note-default-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-default-icon; + color : $note-default-text; + } + } + } + } + + &.primary { + if note_style == 'flat' { + background-color: $note-primary-bg; + } + border-left-color: $note-primary-border; + h2, h3, h4, h5, h6 { + color: $note-primary-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-primary-icon; + color : $note-primary-text; + } + } + } + } + + &.info { + if note_style == 'flat' { + background-color: $note-info-bg; + } + border-left-color: $note-info-border; + h2, h3, h4, h5, h6 { + color: $note-info-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-info-icon; + color : $note-info-text; + } + } + } + } + + &.success { + if note_style == 'flat' { + background-color: $note-success-bg; + } + border-left-color: $note-success-border; + h2, h3, h4, h5, h6 { + color: $note-success-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-success-icon; + color : $note-success-text; + } + } + } + } + + &.warning { + if note_style == 'flat' { + background-color: $note-warning-bg; + } + border-left-color: $note-warning-border; + h2, h3, h4, h5, h6 { + color: $note-warning-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-warning-icon; + color : $note-warning-text; + } + } + } + } + + &.danger { + if note_style == 'flat' { + background-color: $note-danger-bg; + } + border-left-color: $note-danger-border; + h2, h3, h4, h5, h6 { + color: $note-danger-text; + } + if note_icons { + &:not(.no-icon) { + &:before { + content: $note-danger-icon; + color : $note-danger-text; + } + } + } + } + +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/tabs.styl b/themes/next-5.1.4/source/css/_common/components/tags/tabs.styl new file mode 100644 index 0000000..c3c27c4 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/tabs.styl @@ -0,0 +1,99 @@ +.post-body .tabs { + position: relative; + display: block; + margin-bottom: 20px; + padding-top: 10px; + + // Read tabs border_radius from NexT config and set in "tbr px" to use it as string variable in this CSS section. + hexo-config('tabs.border_radius') is a 'unit' ? (tbr = unit(hexo-config('tabs.border_radius'), px)) : (tbr = 0) + + ul.nav-tabs { + margin: 0; + padding: 0; + display: flex; + margin-bottom: -1px; + + +mobile-smallest() { + display: block; + margin-bottom: 5px; + } + + li.tab { + list-style-type: none !important; + margin: 0 .25em 0 0; + border-top: 3px solid transparent; + border-left: 1px solid transparent; + border-right: 1px solid transparent; + + +mobile-smallest() { + margin: initial; + border-top: 1px solid transparent; + border-left: 3px solid transparent; + border-right: 1px solid transparent; + border-bottom: 1px solid transparent; + } + + if tbr > 0 { + border-radius: tbr tbr 0 0; + +mobile-smallest() { border-radius: tbr; } + } + if hexo-config('tabs.transition.tabs') { the-transition-ease-out(); } + + & a { + outline: 0; + border-bottom: initial; + display: block; + line-height: 1.8em; + padding: .25em .75em; + & i { width: (18em / 14); } + if hexo-config('tabs.transition.labels') { the-transition-ease-out(); } + } + + &.active { + border-top: 3px solid $orange; + border-left: 1px solid $table-border-color; + border-right: 1px solid $table-border-color; + background-color: #fff; + + +mobile-smallest() { + border-top: 1px solid $table-border-color; + border-left: 3px solid $orange; + border-right: 1px solid $table-border-color; + border-bottom: 1px solid $table-border-color; + } + + & a { + cursor: default; + color: $link-color; + } + } + } + + } + + .tab-content { + background-color: #fff; + + .tab-pane { + border: 1px solid $table-border-color; + padding: 20px 20px 0 20px; + if tbr > 0 { border-radius: tbr; } + + &:not(.active) { + hide(); + } + &.active { + show(); + if tbr > 0 { + &:nth-of-type(1) { + border-radius: 0 tbr tbr tbr; + +mobile-smallest() { border-radius: tbr; } + } + } + } + + } + + } + +} diff --git a/themes/next-5.1.4/source/css/_common/components/tags/tags.styl b/themes/next-5.1.4/source/css/_common/components/tags/tags.styl new file mode 100644 index 0000000..e7e027a --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/tags/tags.styl @@ -0,0 +1,8 @@ +@import "full-image"; +@import "blockquote-center"; +@import "group-pictures"; +@import "exturl" if hexo-config('exturl'); +@import "note" if hexo-config('note.style') == 'simple' || hexo-config('note.style') == 'flat'; +@import "note-modern" if hexo-config('note.style') == 'modern'; +@import "label" if hexo-config('label'); +@import "tabs" if hexo-config('tabs.enable'); diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/algolia-search.styl b/themes/next-5.1.4/source/css/_common/components/third-party/algolia-search.styl new file mode 100644 index 0000000..e2e9828 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/algolia-search.styl @@ -0,0 +1,125 @@ +.algolia-pop-overlay + position: fixed + width: 100% + height: 100% + top: 0 + left: 0 + z-index: 2080 + background-color: rgba(0, 0, 0, 0.3) + +.algolia-popup + overflow: hidden + padding: 0 + display: none + position: fixed + top: 10% + left: 50% + width: 700px + height: 80% + margin-left: -350px + background: #fff + color: #333 + z-index: 9999 + border-radius: 5px + +mobile() + padding: 0 + top: 0 + left: 0 + margin: 0 + width: 100% + height: 100% + border-radius: 0 + + .popup-btn-close + position: absolute + right: 14px + color: #4EBD79 + font-size: 14px + font-weight: bold + text-transform: uppercase + cursor: pointer + padding-left: 15px + border-left: 1px solid #eee + top: 10px + .fa + color: $grey-dark + font-size: 18px + &:hover .fa + color: $black-deep + +.algolia-search + padding: 10px 15px 5px + max-height: 50px + border-bottom: 1px solid #ccc + background: $whitesmoke + border-top-left-radius: 5px + border-top-right-radius: 5px + +.algolia-search-input-icon + display: inline-block + width: 20px + .fa + font-size: 18px + +.algolia-search-input + display: inline-block + width: calc(90% - 20px) + input + padding: 5px 0 + width: 100% + outline: none + border: none + background: transparent + +.algolia-powered + float: right + img + display: inline-block + height: 18px + vertical-align: middle + +.algolia-results + position: relative + overflow: auto + padding: 10px 30px + height: calc(100% - 50px) + + hr + margin: 10px 0 + + .highlight + font-style: normal + margin: 0 + padding: 0 2px + font-size: inherit + color: red + +.algolia-hits + margin-top: 20px + +.algolia-hit-item + margin: 15px 0 + +.algolia-hit-item-link + display: block + border-bottom: 1px dashed #ccc + the-transition() + +.algolia-pagination + .pagination + margin-top: 40px + border-top: none + padding: 0 + .pagination-item + display: inline-block + .page-number + border-top: none + &:hover + border-bottom: 1px solid $black-deep + + .current .page-number + @extend .pagination .page-number.current + + .disabled-item + visibility: hidden + diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/baidushare.styl b/themes/next-5.1.4/source/css/_common/components/third-party/baidushare.styl new file mode 100644 index 0000000..fc42b71 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/baidushare.styl @@ -0,0 +1,12 @@ +.post-spread { + margin-top: 20px; + text-align: center; +} + +.bdshare-slide-button-box a { border: none; } + +.bdsharebuttonbox { + display: inline-block; + + a { border: none; } +} diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/busuanzi-counter.styl b/themes/next-5.1.4/source/css/_common/components/third-party/busuanzi-counter.styl new file mode 100644 index 0000000..960fef6 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/busuanzi-counter.styl @@ -0,0 +1,30 @@ +if hexo-config("scheme") == Pisces + .busuanzi-count { + +tablet() { + width: auto; + } + +mobile() { + width: auto; + } + } + +.site-uv, +.site-pv, +.page-pv { + display: inline-block; + + .busuanzi-value { + margin: 0 5px; + } +} + +if hexo-config("busuanzi_count.site_pv") and hexo-config("busuanzi_count.site_uv") + .site-uv + { + margin-right: 10px; + + &::after { + content: "|"; + padding-left: 10px; + } + } diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/duoshuo.styl b/themes/next-5.1.4/source/css/_common/components/third-party/duoshuo.styl new file mode 100644 index 0000000..3359518 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/duoshuo.styl @@ -0,0 +1,290 @@ + +.theme-next { + $duoshuoBaseBorderColor = #c7d4e1; + $duoshuoBaseBgColor = #f6f8fa; + + #ds-thread #ds-reset { + color: #555; + } + + #ds-thread #ds-reset .ds-replybox { + margin-bottom: 30px; + } + + #ds-thread #ds-reset .ds-replybox .ds-avatar, #ds-reset .ds-avatar img { + box-shadow: none; + } + + #ds-thread #ds-reset .ds-textarea-wrapper { + border-color: $duoshuoBaseBorderColor; + background: none; + border-top-right-radius: 3px; + border-top-left-radius: 3px; + } + + + #ds-thread #ds-reset .ds-textarea-wrapper textarea { + height: 60px; + } + + #ds-reset .ds-rounded-top { + border-radius: 0; + } + + #ds-thread #ds-reset .ds-post-toolbar { + box-sizing: border-box; + border: 1px solid $duoshuoBaseBorderColor; + background: $duoshuoBaseBgColor; + } + + #ds-thread #ds-reset .ds-post-options { + height: 40px; + border: none; + background: none; + } + + #ds-thread #ds-reset .ds-toolbar-buttons { + top: 11px; + } + + #ds-thread #ds-reset .ds-sync { + top: 5px; + } + + #ds-thread #ds-reset .ds-post-button { + top: 4px; + right: 5px; + width: 90px; + height: 30px; + border: 1px solid #c5ced7; + border-radius: 3px; + background-image: linear-gradient(#fbfbfc, #f5f7f9); + color: #60676d; + } + + #ds-thread #ds-reset .ds-post-button:hover { + background-position: 0 -30px; + color: #60676d; + } + + #ds-thread #ds-reset .ds-comments-info { + padding: 10px 0; + } + + #ds-thread #ds-reset .ds-sort { + display: none; + } + + #ds-thread #ds-reset li.ds-tab a.ds-current { + border: none; + background: $duoshuoBaseBgColor; + color: #60676d; + + &:hover { + background-color: #e9f0f7; + color: #60676d; + } + } + + #ds-thread #ds-reset li.ds-tab a { + border-radius: 2px; + padding: 5px; + } + + #ds-thread #ds-reset .ds-login-buttons p { + color: #999; + line-height: 36px; + } + + #ds-thread #ds-reset .ds-login-buttons .ds-service-list li { + height: 28px; + } + + #ds-thread #ds-reset .ds-service-list a { + background: none; + padding: 5px; + border: 1px solid; + border-radius: 3px; + text-align: center; + + &:hover { + color: #fff; + background: #666; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-weibo { + color: #fc9b00; + border-color: #fc9b00; + + &:hover { + background: #fc9b00; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-qq { + color: #60a3ec; + border-color: #60a3ec; + + &:hover { + background: #60a3ec; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-renren { + color: #2e7ac4; + border-color: #2e7ac4; + + &:hover { + background: #2e7ac4; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-douban { + color: #37994c; + border-color: #37994c; + + &:hover { + background: #37994c; + } + } + #ds-thread #ds-reset .ds-service-list .ds-kaixin { + color: #fef20d; + border-color: #fef20d; + + &:hover { + background: #fef20d; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-netease { + color: #f00; + border-color: #f00; + + &:hover { + background: #f00; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-sohu { + color: #ffcb05; + border-color: #ffcb05; + + &:hover { + background: #ffcb05; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-baidu { + color: #2831e0; + border-color: #2831e0; + + &:hover { + background: #2831e0; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-google { + color: #166bec; + border-color: #166bec; + + &:hover { + background: #166bec; + } + } + + #ds-thread #ds-reset .ds-service-list .ds-weixin { + color: #00CE0D; + border-color: #00CE0D; + + &:hover { + background: #00CE0D; + } + } + #ds-thread #ds-reset .ds-service-list .ds-more-services { + border: none; + &:hover { + background: none; + } + } + +/*duoshuo UA style begin*/ + + #ds-reset .duoshuo-ua-admin { + display: inline-block; + color: red; + } + + #ds-reset .duoshuo-ua-platform, + #ds-reset .duoshuo-ua-browser { + color: #ccc; + + .fa { + display: inline-block; + margin-right: 3px; + } + } + + #ds-reset .duoshuo-ua-separator { + display: inline-block; + margin-left: 5px; + } + + .this_ua { + background-color: #ccc !important; + border-radius: 4px; + padding: 0 5px !important; + margin: 1px 1px !important; + border: 1px solid #BBB !important; + color: #fff; + display: inline-block !important; + } + + .this_ua.admin { + background-color: #d9534f !important; + border-color: #d9534f !important; + } + + .this_ua.platform.iOS, .this_ua.platform.Mac, .this_ua.platform.Windows { + background-color: #39b3d7 !important; + border-color: #46b8da !important; + } + + .this_ua.platform.Linux { + background-color: #3A3A3A !important; + border-color: #1F1F1F !important; + } + + .this_ua.platform.Android { + background-color: #00C47D !important; + border-color: #01B171 !important; + } + + .this_ua.browser.Mobile, .this_ua.browser.Chrome { + background-color: #5cb85c !important; + border-color: #4cae4c !important; + } + + .this_ua.browser.Firefox { + background-color: #f0ad4e !important; + border-color: #eea236 !important; + } + + .this_ua.browser.Maxthon, .this_ua.browser.IE { + background-color: #428bca !important; + border-color: #357ebd !important; + } + + .this_ua.browser.baidu, .this_ua.browser.UCBrowser, .this_ua.browser.Opera { + background-color: #d9534f !important; + border-color: #d43f3a !important; + } + + .this_ua.browser.Android, .this_ua.browser.QQBrowser { + background-color: #78ACE9 !important; + border-color: #4cae4c !important; + } + +/*duoshuo UA style end*/ + +} diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/gitment.styl b/themes/next-5.1.4/source/css/_common/components/third-party/gitment.styl new file mode 100644 index 0000000..52babf0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/gitment.styl @@ -0,0 +1,13 @@ +#gitment-display-button{ + display: inline-block; + padding: 0 15px; + color: #0a9caf; + cursor: pointer; + font-size: 14px; + border: 1px solid #0a9caf; + border-radius: 4px; +} +#gitment-display-button:hover{ + color: #fff; + background: #0a9caf; +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/han.styl b/themes/next-5.1.4/source/css/_common/components/third-party/han.styl new file mode 100644 index 0000000..d02c969 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/han.styl @@ -0,0 +1,3 @@ +.fa { + font-family: FontAwesome!important; +} diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/jiathis.styl b/themes/next-5.1.4/source/css/_common/components/third-party/jiathis.styl new file mode 100644 index 0000000..d501fb5 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/jiathis.styl @@ -0,0 +1,10 @@ +.post-spread { + margin-top: 20px; + text-align: center; +} + +.jiathis_style { + display: inline-block; + + a { border: none; } +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/localsearch.styl b/themes/next-5.1.4/source/css/_common/components/third-party/localsearch.styl new file mode 100644 index 0000000..85f43cf --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/localsearch.styl @@ -0,0 +1,102 @@ +.local-search-pop-overlay + position: fixed + width: 100% + height: 100% + top: 0 + left: 0 + z-index: 2080 + background-color: rgba(0, 0, 0, 0.3) + +.local-search-popup + display: none + position: fixed + top: 10% + left: 50% + margin-left: -350px + width: 700px + height: 80% + padding: 0 + background: #fff + color: #333 + z-index: 9999 + border-radius: 5px + +mobile() + padding: 0 + top: 0 + left: 0 + margin: 0 + width: 100% + height: 100% + border-radius: 0 + + ul.search-result-list + padding: 0 + margin: 0 5px + + p.search-result + border-bottom: 1px dashed #ccc + padding: 5px 0 + + a.search-result-title + font-weight: bold + font-size: 16px + + .search-keyword + border-bottom: 1px dashed #f00 + font-weight: bold + color: #f00 + + .local-search-header + padding: 5px + height: 36px + background: #f5f5f5 + border-top-left-radius: 5px + border-top-right-radius: 5px + + #local-search-result + overflow: auto + position: relative + padding: 5px 25px + height: calc(100% - 55px) + + .local-search-input-wrapper + display: inline-block + width: calc(100% - 90px) + height: 36px + line-height: 36px + padding: 0 5px + + .local-search-input-wrapper input + padding: 8px 0 + height: 20px + display: block + width: 100% + outline: none + border: none + background: transparent + vertical-align: middle + + .search-icon, .popup-btn-close + display: inline-block + font-size: 18px + color: #999 + height: 36px + width: 18px + padding-left: 10px + padding-right: 10px + + .search-icon + float: left + + .popup-btn-close + border-left: 1px solid #eee + float: right + cursor: pointer + + #no-result + position: absolute + left: 50% + top: 50% + -webkit-transform: translate(-50%, -50%) + transform: translate(-50%, -50%) + color: #ccc diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/needsharebutton.styl b/themes/next-5.1.4/source/css/_common/components/third-party/needsharebutton.styl new file mode 100644 index 0000000..2caae44 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/needsharebutton.styl @@ -0,0 +1,27 @@ +#needsharebutton-postbottom { + position: relative; + cursor: pointer; + height: 26px; + + .btn { + display: initial; + padding: 1px 4px; + border: 1px solid $btn-default-border-color; + border-radius: 3px; + } +} + +#needsharebutton-float { + position: fixed; + bottom: 38px; + left: -8px; + z-index: 9999; + cursor: pointer; + + .btn { + //display: initial; + padding: 0 10px 0 14px + border: 1px solid $btn-default-border-color; + border-radius: 4px; + } +} diff --git a/themes/next-5.1.4/source/css/_common/components/third-party/third-party.styl b/themes/next-5.1.4/source/css/_common/components/third-party/third-party.styl new file mode 100644 index 0000000..c2298d0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/components/third-party/third-party.styl @@ -0,0 +1,9 @@ +@import "duoshuo"; +@import "gitment" if hexo-config('gitment.enable'); +@import "jiathis"; +@import "han"; +@import "baidushare"; +@import "localsearch"; +@import "busuanzi-counter"; +@import "algolia-search" if hexo-config('algolia_search.enable'); +@import "needsharebutton" if hexo-config('needmoreshare2.enable'); diff --git a/themes/next-5.1.4/source/css/_common/outline/outline.styl b/themes/next-5.1.4/source/css/_common/outline/outline.styl new file mode 100644 index 0000000..7337e18 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/outline/outline.styl @@ -0,0 +1,58 @@ +// +// Layout +// Note: Must name this file "outline" instead of "layout" +// Or Hexo will use it as template layout. +// ================================================= + + +html, body { height: 100%; } + +.container { + position: relative; + min-height: 100%; +} + + +// Header Section +// -------------------------------------------------- +.header-inner { + margin: 0 auto; + padding: 100px 0 70px; + width: $content-desktop; + + +desktop-large() { + .container & { width: $content-desktop-large; } + } +} + +// Main Section +// -------------------------------------------------- +.main { padding-bottom: $footer-height + $gap-between-main-and-footer; } +.main-inner { + margin: 0 auto; + width: $content-desktop; + + +desktop-large() { + .container & { width: $content-desktop-large; } + } +} + + +// Footer Section +// -------------------------------------------------- +.footer { + position: absolute; + left: 0; + bottom: 0; + width: 100%; + min-height: $footer-height; +} +.footer-inner { + box-sizing: border-box; + margin: 20px auto; + width: $content-desktop; + + +desktop-large() { + .container & { width: $content-desktop-large; } + } +} diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/base.styl b/themes/next-5.1.4/source/css/_common/scaffolding/base.styl new file mode 100644 index 0000000..74c77e3 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/base.styl @@ -0,0 +1,111 @@ + +::selection { + background: $selection-bg; + color: $selection-color; +} + +body { + position: relative; // Required by scrollspy + font-family: $font-family-base; + font-size: $font-size-base; + line-height: $line-height-base; + color: $text-color; + background: $body-bg-color; + + +mobile() { padding-right: 0 !important; } + +tablet() { padding-right: 0 !important; } + +desktop-large() { font-size: $font-size-large; } +} + +h1, h2, h3, h4, h5, h6 { + margin: 0; + padding: 0; + font-weight: bold; + line-height: 1.5; + font-family: $font-family-headings; +} + +h2, h3, h4, h5, h6 { margin: 20px 0 15px; } + +for headline in (1..6) { + h{headline} { + font-size: $font-size-headings-base - $font-size-headings-step * headline; + } + + +mobile() { + h{headline} { + font-size: $font-size-headings-base - $font-size-headings-step * headline - 4px; + } + } +} + +p { margin: 0 0 20px 0; } + +a { + color: $link-color; + text-decoration: none; + outline: none; + border-bottom: 1px solid $grey-dark; + word-wrap: break-word; + + &:hover { + color: $link-hover-color; + border-bottom-color: $link-decoration-hover-color; + } +} + +blockquote { + margin: 0; + padding: 0; +} + +img { + display: block; + margin: auto; + max-width: 100%; + height: auto; +} + + +hr { + margin: 40px 0; + height: 3px; + border: none; + background-color: $gray-lighter; + background-image: repeating-linear-gradient( + -45deg, + white, + white 4px, + transparent 4px, + transparent 8px + ); +} + +blockquote { + padding: 0 15px; + color: $grey-dim; + border-left: 4px solid $gray-lighter; + + cite::before { + content: "-"; + padding: 0 5px; + } +} + +dt { font-weight: $font-weight-bolder; } + +dd { + margin: 0; + padding: 0; +} + +kbd { + border: 1px solid $grey-light; + border-radius: 0.2em; + box-shadow: 0.1em 0.1em 0.2em rgba(0,0,0,0.1); + background-color: #f9f9f9; + font-family: inherit; + background-image: -webkit-linear-gradient(top, #eee, white, #eee); + padding: 0.1em 0.3em; + white-space: nowrap; +} diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/helpers.styl b/themes/next-5.1.4/source/css/_common/scaffolding/helpers.styl new file mode 100644 index 0000000..a00d0bb --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/helpers.styl @@ -0,0 +1,67 @@ +// +// Helpers +// ================================================= + + + +// Alignment +.text-left { text-align: left; } +.text-center { text-align: center; } +.text-right { text-align: right; } +.text-justify { text-align: justify; } +.text-nowrap { white-space: nowrap; } + + +// Transformation +.text-lowercase { text-transform: lowercase; } +.text-uppercase { text-transform: uppercase; } +.text-capitalize { text-transform: capitalize; } + + +// Center-align a block level element. +.center-block { + display: block; + margin-left: auto; + margin-right: auto; +} + + +// Clearfix. http://nicolasgallagher.com/micro-clearfix-hack/ +.clearfix { + clearfix(); +} + +.pullquote { + width: 45%; + + &.left { + float: left; + margin-left: 5px; + margin-right: 10px; + } + + &.right { + float: right; + margin-left: 10px; + margin-right: 5px; + } +} + +.affix.affix.affix { position: fixed; } + +.translation { + margin-top: -20px; + font-size: 14px; + color: $grey-dark; +} + +// https://davidwalsh.name/detect-scrollbar-width +.scrollbar-measure { + width: 100px; + height: 100px; + overflow: scroll; + position: absolute; + top: -9999px; +} + +.use-motion .motion-element { opacity: 0; } diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/mobile.styl b/themes/next-5.1.4/source/css/_common/scaffolding/mobile.styl new file mode 100644 index 0000000..191fbfd --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/mobile.styl @@ -0,0 +1,121 @@ +/* +// > 1600px ++desktop-large() { + +} + +// > 992px ++desktop() { + +} + +// > 768px & < 991px ++tablet() { + +} + + +// < 767px ++mobile() { + +} +*/ + +// < 567px ++mobile-small() { + + // For Muse & Mist schemes only vertical economy. + .header-inner { + margin-bottom: initial !important; + } + .main-inner { + margin-top: initial !important; + } + + // For Pisces & Gemini schemes only wider width (remove main blocks in Gemini). + .content-wrap { + padding: initial !important; + } + + // For all schemes wider width. + .posts-expand { + padding-top: $content-mobile-padding !important; + // For Muse & Mist & Pisces schemes only wider width. + margin: initial !important; + + .post-header { + padding: 0 18px; + } + + .post-meta { + margin: 3px 0 10px 0 !important; + } + + } + + .post-block { + // Inside posts blocks content padding (default 40px). + padding: $content-mobile-padding 0 !important; + } + + .post-body { + // For headers narrow width. + h2, h3, h4, h5, h6 { + margin: 10px 18px 8px; + } + // Rewrite paddings & margins inside tags. + .note, .tabs .tab-content .tab-pane { + h2, h3, h4, h5, h6 { + margin: 0 5px; + } + } + + // For paragraphs narrow width. + p { + margin: 0 0 10px 0; + padding: 0 18px; + } + + // Rewrite paddings & margins inside tags. + .note > p, .tabs .tab-content .tab-pane > p { + padding: 0 5px; + } + + .video-container .fluid-vids { + margin-bottom: 10px !important; + } + + .note { + padding: 10px !important; + margin-bottom: 10px !important; + + if hexo-config('note.icons') { + &:not(.no-icon) { + padding-left: 35px !important; + &:before { + top: 8px !important; + left: 12px !important; + } + } + } + } + + .tabs .tab-content .tab-pane { + padding: 10px 10px 0 10px !important; + } + } + + // Need to refactor into flex. + .post-nav { + padding-bottom: 2px; + //padding: 2px 8px; + } + +} + +/* +// < 413px ++mobile-smallest() { + +} +*/ diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/normalize.styl b/themes/next-5.1.4/source/css/_common/scaffolding/normalize.styl new file mode 100644 index 0000000..81c6f31 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/normalize.styl @@ -0,0 +1,427 @@ +/*! normalize.css v3.0.2 | MIT License | git.io/normalize */ + +/** + * 1. Set default font family to sans-serif. + * 2. Prevent iOS text size adjust after orientation change, without disabling + * user zoom. + */ + +html { + font-family: sans-serif; /* 1 */ + -ms-text-size-adjust: 100%; /* 2 */ + -webkit-text-size-adjust: 100%; /* 2 */ +} + +/** + * Remove default margin. + */ + +body { + margin: 0; +} + +/* HTML5 display definitions + ========================================================================== */ + +/** + * Correct `block` display not defined for any HTML5 element in IE 8/9. + * Correct `block` display not defined for `details` or `summary` in IE 10/11 + * and Firefox. + * Correct `block` display not defined for `main` in IE 11. + */ + +article, +aside, +details, +figcaption, +figure, +footer, +header, +hgroup, +main, +menu, +nav, +section, +summary { + display: block; +} + +/** + * 1. Correct `inline-block` display not defined in IE 8/9. + * 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera. + */ + +audio, +canvas, +progress, +video { + display: inline-block; /* 1 */ + vertical-align: baseline; /* 2 */ +} + +/** + * Prevent modern browsers from displaying `audio` without controls. + * Remove excess height in iOS 5 devices. + */ + +audio:not([controls]) { + display: none; + height: 0; +} + +/** + * Address `[hidden]` styling not present in IE 8/9/10. + * Hide the `template` element in IE 8/9/11, Safari, and Firefox < 22. + */ + +[hidden], +template { + display: none; +} + +/* Links + ========================================================================== */ + +/** + * Remove the gray background color from active links in IE 10. + */ + +a { + background-color: transparent; +} + +/** + * Improve readability when focused and also mouse hovered in all browsers. + */ + +a:active, +a:hover { + outline: 0; +} + +/* Text-level semantics + ========================================================================== */ + +/** + * Address styling not present in IE 8/9/10/11, Safari, and Chrome. + */ + +abbr[title] { + border-bottom: 1px dotted; +} + +/** + * Address style set to `bolder` in Firefox 4+, Safari, and Chrome. + */ + +b, +strong { + font-weight: bold; +} + +/** + * Address styling not present in Safari and Chrome. + */ + +dfn { + font-style: italic; +} + +/** + * Address variable `h1` font-size and margin within `section` and `article` + * contexts in Firefox 4+, Safari, and Chrome. + */ + +h1 { + font-size: 2em; + margin: 0.67em 0; +} + +/** + * Address styling not present in IE 8/9. + */ + +mark { + background: #ff0; + color: #000; +} + +/** + * Address inconsistent and variable font size in all browsers. + */ + +small { + font-size: 80%; +} + +/** + * Prevent `sub` and `sup` affecting `line-height` in all browsers. + */ + +sub, +sup { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; +} + +sup { + top: -0.5em; +} + +sub { + bottom: -0.25em; +} + +/* Embedded content + ========================================================================== */ + +/** + * Remove border when inside `a` element in IE 8/9/10. + */ + +img { + border: 0; +} + +/** + * Correct overflow not hidden in IE 9/10/11. + */ + +svg:not(:root) { + overflow: hidden; +} + +/* Grouping content + ========================================================================== */ + +/** + * Address margin not present in IE 8/9 and Safari. + */ + +figure { + margin: 1em 40px; +} + +/** + * Address differences between Firefox and other browsers. + */ + +hr { + -moz-box-sizing: content-box; + box-sizing: content-box; + height: 0; +} + +/** + * Contain overflow in all browsers. + */ + +pre { + overflow: auto; +} + +/** + * Address odd `em`-unit font size rendering in all browsers. + */ + +code, +kbd, +pre, +samp { + font-family: monospace, monospace; + font-size: 1em; +} + +/* Forms + ========================================================================== */ + +/** + * Known limitation: by default, Chrome and Safari on OS X allow very limited + * styling of `select`, unless a `border` property is set. + */ + +/** + * 1. Correct color not being inherited. + * Known issue: affects color of disabled elements. + * 2. Correct font properties not being inherited. + * 3. Address margins set differently in Firefox 4+, Safari, and Chrome. + */ + +button, +input, +optgroup, +select, +textarea { + color: inherit; /* 1 */ + font: inherit; /* 2 */ + margin: 0; /* 3 */ +} + +/** + * Address `overflow` set to `hidden` in IE 8/9/10/11. + */ + +button { + overflow: visible; +} + +/** + * Address inconsistent `text-transform` inheritance for `button` and `select`. + * All other form control elements do not inherit `text-transform` values. + * Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera. + * Correct `select` style inheritance in Firefox. + */ + +button, +select { + text-transform: none; +} + +/** + * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio` + * and `video` controls. + * 2. Correct inability to style clickable `input` types in iOS. + * 3. Improve usability and consistency of cursor style between image-type + * `input` and others. + */ + +button, +html input[type="button"], /* 1 */ +input[type="reset"], +input[type="submit"] { + -webkit-appearance: button; /* 2 */ + cursor: pointer; /* 3 */ +} + +/** + * Re-set default cursor for disabled elements. + */ + +button[disabled], +html input[disabled] { + cursor: default; +} + +/** + * Remove inner padding and border in Firefox 4+. + */ + +button::-moz-focus-inner, +input::-moz-focus-inner { + border: 0; + padding: 0; +} + +/** + * Address Firefox 4+ setting `line-height` on `input` using `!important` in + * the UA stylesheet. + */ + +input { + line-height: normal; +} + +/** + * It's recommended that you don't attempt to style these elements. + * Firefox's implementation doesn't respect box-sizing, padding, or width. + * + * 1. Address box sizing set to `content-box` in IE 8/9/10. + * 2. Remove excess padding in IE 8/9/10. + */ + +input[type="checkbox"], +input[type="radio"] { + box-sizing: border-box; /* 1 */ + padding: 0; /* 2 */ +} + +/** + * Fix the cursor style for Chrome's increment/decrement buttons. For certain + * `font-size` values of the `input`, it causes the cursor style of the + * decrement button to change from `default` to `text`. + */ + +input[type="number"]::-webkit-inner-spin-button, +input[type="number"]::-webkit-outer-spin-button { + height: auto; +} + +/** + * 1. Address `appearance` set to `searchfield` in Safari and Chrome. + * 2. Address `box-sizing` set to `border-box` in Safari and Chrome + * (include `-moz` to future-proof). + */ + +input[type="search"] { + -webkit-appearance: textfield; /* 1 */ + -moz-box-sizing: content-box; + -webkit-box-sizing: content-box; /* 2 */ + box-sizing: content-box; +} + +/** + * Remove inner padding and search cancel button in Safari and Chrome on OS X. + * Safari (but not Chrome) clips the cancel button when the search input has + * padding (and `textfield` appearance). + */ + +input[type="search"]::-webkit-search-cancel-button, +input[type="search"]::-webkit-search-decoration { + -webkit-appearance: none; +} + +/** + * Define consistent border, margin, and padding. + */ + +fieldset { + border: 1px solid #c0c0c0; + margin: 0 2px; + padding: 0.35em 0.625em 0.75em; +} + +/** + * 1. Correct `color` not being inherited in IE 8/9/10/11. + * 2. Remove padding so people aren't caught out if they zero out fieldsets. + */ + +legend { + border: 0; /* 1 */ + padding: 0; /* 2 */ +} + +/** + * Remove default vertical scrollbar in IE 8/9/10/11. + */ + +textarea { + overflow: auto; +} + +/** + * Don't inherit the `font-weight` (applied by a rule above). + * NOTE: the default cannot safely be changed in Chrome and Safari on OS X. + */ + +optgroup { + font-weight: bold; +} + +/* Tables + ========================================================================== */ + +/** + * Remove most spacing between table cells. + */ + +table { + border-collapse: collapse; + border-spacing: 0; +} + +td, +th { + padding: 0; +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/scaffolding.styl b/themes/next-5.1.4/source/css/_common/scaffolding/scaffolding.styl new file mode 100644 index 0000000..b5d3500 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/scaffolding.styl @@ -0,0 +1,9 @@ +// +// Scaffolding +// ================================================= + +@import "normalize"; +@import "base"; +@import "helpers"; +@import "tables"; +@import "mobile" if hexo-config('mobile_layout_economy'); diff --git a/themes/next-5.1.4/source/css/_common/scaffolding/tables.styl b/themes/next-5.1.4/source/css/_common/scaffolding/tables.styl new file mode 100644 index 0000000..c653b81 --- /dev/null +++ b/themes/next-5.1.4/source/css/_common/scaffolding/tables.styl @@ -0,0 +1,33 @@ +table { + margin: 20px 0; + width: $table-width; + border-collapse: collapse; + border-spacing: 0; + border: 1px solid $table-border-color; + font-size: $table-font-size; + table-layout: fixed; + word-wrap: break-all; +} +table>tbody>tr { + &:nth-of-type(odd) { background-color: $table-row-odd-bg-color; } + &:hover { background-color: $table-row-hover-bg-color; } +} + +caption, th, td { + padding: $table-cell-padding; + text-align: $table-content-alignment; + vertical-align: $table-content-vertical; + font-weight: normal; +} + +th, td { + border-bottom: 3px solid $table-cell-border-bottom-color; + border-right: 1px solid $table-cell-border-right-color; +} + +th { + padding-bottom: 10px; + font-weight: $table-th-font-weight; +} + +td { border-bottom-width: 1px; } diff --git a/themes/next-5.1.4/source/css/_custom/custom.styl b/themes/next-5.1.4/source/css/_custom/custom.styl new file mode 100644 index 0000000..63937f7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_custom/custom.styl @@ -0,0 +1 @@ +// Custom styles. diff --git a/themes/next-5.1.4/source/css/_mixins/Gemini.styl b/themes/next-5.1.4/source/css/_mixins/Gemini.styl new file mode 100644 index 0000000..eb4102e --- /dev/null +++ b/themes/next-5.1.4/source/css/_mixins/Gemini.styl @@ -0,0 +1 @@ +@import "Pisces.styl"; diff --git a/themes/next-5.1.4/source/css/_mixins/Mist.styl b/themes/next-5.1.4/source/css/_mixins/Mist.styl new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/source/css/_mixins/Muse.styl b/themes/next-5.1.4/source/css/_mixins/Muse.styl new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/source/css/_mixins/Pisces.styl b/themes/next-5.1.4/source/css/_mixins/Pisces.styl new file mode 100644 index 0000000..34543b1 --- /dev/null +++ b/themes/next-5.1.4/source/css/_mixins/Pisces.styl @@ -0,0 +1,17 @@ +sidebar-inline-links-item() { + margin: 5px 0 0; + if !hexo-config('social_icons.icons_only') { width: 50%; } + + & a { + max-width: 216px; + box-sizing: border-box; + display: inline-block; + margin-right: 0; + margin-bottom: 0; + padding: 0 5px; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; + if hexo-config('social_icons.transition') { the-transition(); } + } +} diff --git a/themes/next-5.1.4/source/css/_mixins/base.styl b/themes/next-5.1.4/source/css/_mixins/base.styl new file mode 100644 index 0000000..0e787f7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_mixins/base.styl @@ -0,0 +1,92 @@ +the-transition() { + transition-duration: 0.2s; + transition-timing-function: ease-in-out; + transition-delay: 0s; +} + +the-transition-ease-in() { + transition-duration: 0.2s; + transition-timing-function: ease-in; + transition-delay: 0s; +} + +the-transition-ease-out() { + transition-duration: 0.2s; + transition-timing-function: ease-out; + transition-delay: 0s; +} + +mobile-smallest() { + @media (max-width: 413px) { + {block} + } +} + +mobile-small() { + @media (max-width: 567px) { + {block} + } +} + +mobile() { + @media (max-width: 767px) { + {block} + } +} + +tablet() { + @media (min-width: 768px) and (max-width: 991px) { + {block} + } +} + +desktop() { + @media (min-width: 992px) { + {block} + } +} + +desktop-large() { + @media (min-width: 1600px) { + {block} + } +} + +circle() { + border-radius: 50%; +} + +transform() { + -webkit-transform: arguments + -moz-transform: arguments + -ms-transform: arguments + -o-transform: arguments + transform: arguments +} + +hide() { + display: none !important; +} + +show() { + display: block !important; +} + +fixbutton() { + right: 20px; + opacity: 0.8; +} + +random-color($min, $max) { + return floor(math(0, 'random') * ($max - $min + 1) + $min); +} + +// Clearfix. http://nicolasgallagher.com/micro-clearfix-hack/ +clearfix() { + &:before, + &:after { + content: " "; + display: table; + } + &:after { clear: both; } +} diff --git a/themes/next-5.1.4/source/css/_mixins/custom.styl b/themes/next-5.1.4/source/css/_mixins/custom.styl new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/source/css/_schemes/Gemini/index.styl b/themes/next-5.1.4/source/css/_schemes/Gemini/index.styl new file mode 100644 index 0000000..95dd34d --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Gemini/index.styl @@ -0,0 +1,243 @@ +@import "../Pisces/_layout"; +@import "../Pisces/_brand"; +@import "../Pisces/_menu"; +@import "../Pisces/_sidebar"; +// Import _posts if want to justify text-align on mobile. +//@import "../Pisces/_posts"; + +// ================================================= +// Rewrite _layout.styl +// ================================================= +// Sidebar padding used as main desktop content padding for sidebar padding and post blocks padding too. + +// In main NexT config set `sidebar: offset: 12` option as main padding. +// In `source/css/_variables/Gemini.styl` there are variables for other resolutions: +// $content-tablet-paddin = 10px; +// $content-mobile-padding = 8px; +// P.S. If u want to change this paddings u may set this variables into `source/css/_variables/custom.styl`. + +// So, it will 12px in Desktop, 10px in Tablets and 8px in Mobiles for all possible paddings. +// ================================================= +// Read values from NexT config and set they as local variables to use as string variables (in any CSS section). +hexo-config('sidebar.offset') is a 'unit' ? (sboffset = unit(hexo-config('sidebar.offset'), px)) : (sboffset = 0) +use_seo = hexo-config('seo'); + +// ================================================= +// Desktop layout styles. +// ================================================= +// Post blocks. +.content-wrap { + padding: initial; + background: initial; + box-shadow: initial; + border-radius: initial; +} + +// Post & Comments blocks. +.post-block { + padding: $content-desktop-padding; + background: white; + box-shadow: $box-shadow-inner; + border-radius: $border-radius-inner; +} + +// When blocks are siblings (homepage). +#posts > article + article { + .post-block { + margin-top: sboffset; + // Rewrite shadows & borders because all blocks have offsets. + box-shadow: $box-shadow; + border-radius: $border-radius; + } +} + +// Comments blocks. +.comments { + padding: $content-desktop-padding; + margin: initial; + margin-top: sboffset; + background: white; + box-shadow: $box-shadow; + border-radius: $border-radius; +} + +// Top main padding from header to posts (default 40px). +.posts-expand { + padding-top: initial; +} + +// Post navigation items. +.post-nav-divider { + width: 4%; +} +.post-nav-item { + width: 48%; +} + +// Post delimiters. +.post-eof, +.post-spread { + hide(); +} + +// Pagination. +.pagination { + .prev, .next, .page-number { + margin-bottom: initial; + top: initial; + } + margin: sboffset 0 0; + border-top: initial; + background: white; + box-shadow: $box-shadow; + border-radius: $border-radius; + padding: 10px 0 10px; +} + +// Footer alignment. +.main { + padding-bottom: initial; +} +.footer { + bottom: auto; +} + +// ================================================= +// Headers. +// ================================================= +// No need anymore? +.post-header { + h1, h2 { + margin: initial; + } +} +.posts-expand .post-title-link { + line-height: inherit; +} +.posts-expand .post-title { + font-size: 1.7em; +} +.post-body { + h1 { + font-size: 1.6em; + border-bottom: 1px solid $body-bg-color; + } + h2 { + font-size: 1.45em; + border-bottom: 1px solid $body-bg-color; + } + h3 { + font-size: 1.3em; + if use_seo { + border-bottom: 1px solid $body-bg-color; + } else { + border-bottom: 1px dotted $body-bg-color; + } + } + h4 { + font-size: 1.2em; + if use_seo { + border-bottom: 1px dotted $body-bg-color; + } + } + h5 { + font-size: 1.07em; + } + h6 { + font-size: 1.03em; + } +} + +// ================================================= +// > 768px & < 991px +// ================================================= ++tablet() { + + // Posts in blocks. + .content-wrap { + padding: $content-tablet-padding; + } + .posts-expand { + margin: initial; + + // Components inside Posts. + .post-button { + margin-top: ($content-tablet-padding * 2); + } + } + + .post-block { + // Inside posts blocks content padding (default 40px). + padding: ($content-tablet-padding * 2); + // Rewrite shadows & borders because all blocks have offsets. + box-shadow: $box-shadow; + border-radius: $border-radius; + } + + // Only if blocks are siblings need bottom margin (homepage). + #posts > article + article { + .post-block { + margin-top: $content-tablet-padding; + } + } + + .comments { + margin-top: $content-tablet-padding; + padding: $content-tablet-padding ($content-tablet-padding * 2); + //padding: initial; + //padding-top: $content-tablet-padding; + } + + .pagination { + margin: $content-tablet-padding 0 0; + } + +} +// ================================================= +// < 767px +// ================================================= ++mobile() { + + // Posts in blocks. + .content-wrap { + padding: $content-mobile-padding; + } + .posts-expand { + margin: initial; + + // Components inside Posts. + .post-button { + margin-top: sboffset; + //padding-bottom : 15px; + } + img { + padding: initial !important; + } + } + + .post-block { + // Inside posts blocks content padding (default 40px). + padding: sboffset; + min-height: auto; + // Rewrite shadows & borders because all blocks have offsets. + box-shadow: $box-shadow; + border-radius: $border-radius; + } + + // Only if blocks are siblings need bottom margin (homepage). + #posts > article + article { + .post-block { + margin-top: $content-mobile-padding; + } + } + + .comments { + margin-top: $content-mobile-padding; + padding: 0 sboffset; + } + + .pagination { + margin: $content-mobile-padding 0 0; + } + +} diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_base.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_base.styl new file mode 100644 index 0000000..97dc4cb --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_base.styl @@ -0,0 +1,12 @@ +// Tags +// -------------------------------------------------- +h1, h2, h3, h4, h5, h6 { margin: 20px 0 10px; } + +p { margin: 0 0 25px 0; } + +a { border-bottom-color: $grey-light; } + +hr { + margin: 20px 0; + height: 2px; +} diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_header.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_header.styl new file mode 100644 index 0000000..a191649 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_header.styl @@ -0,0 +1,63 @@ +// Header +// -------------------------------------------------- +.header { background: $whitesmoke; } +.header-inner { + padding: 25px 0 20px; + clearfix(); + + +mobile() { + width: auto; + margin-bottom: 50px; + padding: 10px; + } +} + +.site-meta { + float: left; + margin-left: -20px; + line-height: normal; + + +mobile() { + margin-left: 10px; + } + + .brand { + padding: 2px 1px; + background: none; + + +mobile() { display: block; } + } + + .logo { display: none; } + + .site-title { + font-size: 22px; + font-weight: bolder; + + +mobile() { line-height: 34px; } + } +} + + +.logo-line-before, +.logo-line-after { + display: block; + overflow: hidden; + margin: 0 auto; + width: 75%; + + +mobile() { display: none; } + + i { + position: relative; + display: block; + height: 2px; + background: $black-deep; + +mobile() { height: 3px; } + } +} + +.use-motion { + .logo-line-before i { left: -100%; } + .logo-line-after i { right: -100%; } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_logo.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_logo.styl new file mode 100644 index 0000000..571b407 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_logo.styl @@ -0,0 +1 @@ +.site-subtitle { display: none; } diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_menu.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_menu.styl new file mode 100644 index 0000000..fa0cd4e --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_menu.styl @@ -0,0 +1,46 @@ +// Menu +// -------------------------------------------------- +.site-nav-toggle { + position: static; + float: right; +} + + +.menu { + float: right; + margin: 8px 0 0 0; + + +mobile() { + margin: 20px 0 0 0; + padding: 0; + } + + br { display: none; } + + .menu-item { + margin: 0; + +mobile() { display: block; } + } + + .menu-item a { + padding: 0 10px; + background: none; + border: none; + border-radius: 2px; + transition-property: background; + + +mobile() { + text-align: left; + } + + &:hover { background: #e1e1e1; } + } + + a::before { + display: none; + + +mobile() { display: block; } + } + + +mobile() { float: none; } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_posts-expanded.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_posts-expanded.styl new file mode 100644 index 0000000..4ca1b29 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_posts-expanded.styl @@ -0,0 +1,67 @@ +// Post Expanded +// -------------------------------------------------- +.posts-expand { + padding-top: 0; + + .post-title, + .post-meta { + text-align: $site-meta-text-align; + +mobile() { text-align: center; } + } + .post-eof { display: none; } + + .post { margin-top: 120px; } + .post:first-child { margin-top: 0; } + + .post-meta { + margin-top: 5px; + margin-bottom: 20px; + } + + .post-title { + position: relative; + font-size: $font-size-headings-base; + font-weight: 400; + +mobile() { font-size: $font-size-headings-small; } + +desktop-large() { font-size: $font-size-headings-large; } + } + .post-title:hover:before { background: $black-deep; } + + .post-body { + +mobile() { font-size: $font-size-small; } + } + + .post-body img { margin: 0; } + + .post-tags { + text-align: left; + a { + padding: 1px 5px; + background: $whitesmoke; + border-bottom: none; + } + a:hover { background: $grey-light; } + } + .post-nav { margin-top: 40px; } +} + +.post-button { + margin-top: 20px; + text-align: left; + + a { + padding: 0; + font-size: $font-size-base; + //color: $grey-dim; + background: none; + border: none; + border-bottom: 2px solid $grey-dim; + transition-property: border; + + +mobile() { font-size: $font-size-small; } + +desktop-large() { font-size: $font-size-large; } + + + &:hover { border-bottom-color: $black-deep; } + } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/_search.styl b/themes/next-5.1.4/source/css/_schemes/Mist/_search.styl new file mode 100644 index 0000000..6cd7b2c --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/_search.styl @@ -0,0 +1,5 @@ +// Search +// -------------------------------------------------- +.site-search form { + display: none; +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/index.styl b/themes/next-5.1.4/source/css/_schemes/Mist/index.styl new file mode 100644 index 0000000..7d047f4 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/index.styl @@ -0,0 +1,91 @@ +// +// Mist scheme +// ================================================= + +@import "_base"; +@import "outline/outline"; +@import "_header"; +@import "_logo"; +@import "_menu"; +@import "_search.styl"; +@import "_posts-expanded"; +@import "sidebar/sidebar-blogroll"; + + +// Components +// -------------------------------------------------- +.btn { + padding: 0 10px; + border-width: 2px; + border-radius: 0; +} + +.headband { display: none; } + + +// Search +// -------------------------------------------------- +.site-search { + position: relative; + float: right; + margin-top: 5px; + padding-top: 3px; + + +mobile() { + float: none; + padding: 0 10px; + } +} + + +// Page - Container +// -------------------------------------------------- +.container .main-inner { + +mobile() { width: auto; } +} + + +// Page - Post details +// -------------------------------------------------- +.page-post-detail { + .post-title, + .post-meta { text-align: center; } + + .post-title:before { display: none; } + + .post-meta { margin-bottom: 60px; } +} + + +// Pagination +// -------------------------------------------------- +.pagination { + margin: 120px 0 0; + text-align: left; + + +mobile() { + margin: 80px 10px 0; + text-align: center; + } +} + +// Footer +// -------------------------------------------------- +.footer { + margin-top: 80px; + padding: 10px 0; + background: $whitesmoke; + color: $grey-dim; +} +.footer-inner { + margin: 0 auto; + text-align: left; + + +mobile() { + width: auto; + text-align: center; + } +} + +// Helpers +// -------------------------------------------------- diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/outline/outline.styl b/themes/next-5.1.4/source/css/_schemes/Mist/outline/outline.styl new file mode 100644 index 0000000..12c0bae --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/outline/outline.styl @@ -0,0 +1 @@ +.main-inner { margin-top: 80px; } diff --git a/themes/next-5.1.4/source/css/_schemes/Mist/sidebar/sidebar-blogroll.styl b/themes/next-5.1.4/source/css/_schemes/Mist/sidebar/sidebar-blogroll.styl new file mode 100644 index 0000000..6db1ed7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Mist/sidebar/sidebar-blogroll.styl @@ -0,0 +1 @@ +.links-of-blogroll-inline .links-of-blogroll-item { display: inline-block; } diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/_layout.styl b/themes/next-5.1.4/source/css/_schemes/Muse/_layout.styl new file mode 100644 index 0000000..0107472 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/_layout.styl @@ -0,0 +1,9 @@ +.header-inner, .container .main-inner, .footer-inner { + +mobile() { width: auto; } +} + +// embed tag +embed { + display: block; + margin: 0px auto 25px auto; +} diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/_logo.styl b/themes/next-5.1.4/source/css/_schemes/Muse/_logo.styl new file mode 100644 index 0000000..1d0437a --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/_logo.styl @@ -0,0 +1,21 @@ +.custom-logo { + .site-meta-headline { text-align: center; } + + .brand { background: none; } + + .site-title { + margin: 10px auto 0; + font-size: 24px; + color: $black-deep; + a { border: none; } + } + + +} + +.custom-logo-image { + margin: 0 auto; + padding: 5px; + max-width: 150px; + background: white; +} diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/_menu.styl b/themes/next-5.1.4/source/css/_schemes/Muse/_menu.styl new file mode 100644 index 0000000..b18fed9 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/_menu.styl @@ -0,0 +1,33 @@ +.site-nav { + +mobile() { + position: absolute; + left: 0; + top: 52px; + margin: 0; + width: 100%; + padding: 0; + background: white; + border-bottom: 1px solid $gray-lighter; + z-index: $zindex-5; + } +} + +.menu { + +mobile() { text-align: left; } +} +.menu .menu-item { + +mobile() { + display: block; + margin: 0 10px; + vertical-align: top; + } + + br { + +mobile() { display: none; } + } + + a { + +mobile() { padding: 5px 10px; } + } + .fa { margin-right: 0; } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/_search.styl b/themes/next-5.1.4/source/css/_schemes/Muse/_search.styl new file mode 100644 index 0000000..6cd7b2c --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/_search.styl @@ -0,0 +1,5 @@ +// Search +// -------------------------------------------------- +.site-search form { + display: none; +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/index.styl b/themes/next-5.1.4/source/css/_schemes/Muse/index.styl new file mode 100644 index 0000000..35effe8 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/index.styl @@ -0,0 +1,5 @@ +@import "_layout.styl"; +@import "_logo.styl"; +@import "_menu.styl"; +@import "_search.styl"; +@import "sidebar/sidebar-blogroll"; diff --git a/themes/next-5.1.4/source/css/_schemes/Muse/sidebar/sidebar-blogroll.styl b/themes/next-5.1.4/source/css/_schemes/Muse/sidebar/sidebar-blogroll.styl new file mode 100644 index 0000000..6db1ed7 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Muse/sidebar/sidebar-blogroll.styl @@ -0,0 +1 @@ +.links-of-blogroll-inline .links-of-blogroll-item { display: inline-block; } diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/_brand.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/_brand.styl new file mode 100644 index 0000000..c85ee8f --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/_brand.styl @@ -0,0 +1,30 @@ +.site-brand-wrapper { + position: relative; +} + +.site-meta { + padding: 20px 0; + color: white; + background: $black-deep; + + +tablet() { + box-shadow: 0 0 16px rgba(0,0,0,0.5); + } + +mobile() { + box-shadow: 0 0 16px rgba(0,0,0,0.5); + } +} + +.brand { + padding: 0; + background: none; + + &:hover { color: white; } +} + +.site-subtitle { + margin: 10px 10px 0; + font-weight: initial; +} + +.site-search form { display: none; } diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/_layout.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/_layout.styl new file mode 100644 index 0000000..f7e5e0d --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/_layout.styl @@ -0,0 +1,130 @@ +.header { + position: relative; + margin: 0 auto; + width: $main-desktop; + + +tablet() { + width: auto; + } + +mobile() { + width: auto; + } +} + +.header-inner { + position: absolute; + top: 0; + overflow: hidden; + padding: 0; + width: 240px; + background: white; + box-shadow: $box-shadow-inner; + border-radius: $border-radius-inner; + + +desktop-large() { + .container & { width: 240px; } + } + +tablet() { + position: relative; + width: auto; + border-radius: initial; + } + +mobile() { + position: relative; + width: auto; + border-radius: initial; + } +} + +.main { + clearfix(); + +tablet() { + padding-bottom: 100px; + } + +mobile() { + padding-bottom: 100px; + } +} + +.container .main-inner { + width: $main-desktop; + + +tablet() { + width: auto; + } + +mobile() { + width: auto; + } +} + +.content-wrap { + float: right; + box-sizing: border-box; + padding: $content-desktop-padding; + width: $content-desktop; + background: white; + min-height: 700px; + box-shadow: $box-shadow-inner; + border-radius: $border-radius-inner; + + +tablet() { + width: 100%; + padding: 20px; + border-radius: initial; + } + +mobile() { + width: 100%; + padding: 20px; + min-height: auto; + border-radius: initial; + } +} + +.sidebar { + position: static; + float: left; + margin-top: 300px; + width: $sidebar-desktop; + background: $body-bg-color; + box-shadow: none; + + +tablet() { + display: none; + } + +mobile() { + display: none; + } +} + +.sidebar-toggle { display: none; } + + +.footer-inner { + width: $main-desktop; + padding-left: 260px; + + +tablet() { + width: auto; + padding-left: 0 !important; + padding-right: 0 !important; + } + +mobile() { + width: auto; + padding-left: 0 !important; + padding-right: 0 !important; + } +} + + + +.sidebar-position-right { + .header-inner { right: 0; } + .content-wrap { float: left; } + .sidebar { float: right; } + + .footer-inner { + padding-left: 0; + padding-right: 260px; + } +} + diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/_menu.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/_menu.styl new file mode 100644 index 0000000..21986ac --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/_menu.styl @@ -0,0 +1,67 @@ +.site-nav { + border-top: none; + + +tablet() { + display: none !important; + } +} + +.site-nav-on { + +tablet() { + display: block !important; + } +} + +.menu .menu-item { + display: block; + margin: 0; + + a { + position: relative; + box-sizing: border-box; + padding: 5px 20px; + text-align: left; + line-height: inherit; + transition-property: background-color; + the-transition(); + + &:hover { + background: #f9f9f9; + border-bottom-color: white; + } + } + + br { display: none; } +} + +.menu-item-active a { + @extend .menu .menu-item a:hover; + + &:after { + content: " "; + position: absolute; + top: 50%; + margin-top: -3px; + right: 15px; + width: 6px; + height: 6px; + border-radius: 50%; + background-color: $grey; + } +} + +.btn-bar { + background-color: white; +} + +.site-nav-toggle { + left: 20px; + top: 50%; + + -webkit-transform: translateY(-50%); + transform: translateY(-50%); + + +tablet() { + display: block; + } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/_posts.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/_posts.styl new file mode 100644 index 0000000..498409d --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/_posts.styl @@ -0,0 +1,5 @@ +.post-body { + +mobile() { + text-align: justify; + } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/_sidebar.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/_sidebar.styl new file mode 100644 index 0000000..9adfb55 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/_sidebar.styl @@ -0,0 +1,124 @@ +.use-motion .sidebar .motion-element { opacity: 1; } + +.sidebar { + margin-left: -100%; + right: auto; + bottom: auto; + + // Do NOT delete this line + // or Affix (position: fixed) will not work in Google Chrome. + -webkit-transform: none; +} + + +.sidebar-inner { +//padding: 20px 10px 0; + box-sizing: border-box; + width: 240px; + color: $text-color; + background: white; + box-shadow: $box-shadow; + border-radius: $border-radius; + if (hexo-config('motion.enable') and hexo-config('motion.transition.sidebar')) { opacity: 0; } + + &.affix { + position: fixed; + top: $sidebar-offset; + } + + &.affix-bottom { + position: absolute; + } + +} + +.site-overview { + //margin: 0 2px; + text-align: left; +} + +.site-author { + clearfix(); +} + +.sidebar a { + color: $black-light; + + &:hover { color: $black-deep; } +} + +.site-state-item { + padding: 0 10px; +} + +.links-of-author-item { + a:before { display: none; } + a { + border-bottom: none; + text-decoration: underline; + } +} + +.feed-link { + border-top: 1px dotted $grey-light; + border-bottom: 1px dotted $grey-light; + text-align: center; +} + +.feed-link a { + display: block; + color: $orange; + border: none; + + &:hover { + background: none; + color: darken($orange, 20%); + + i { color: darken($orange, 20%); } + } +} + +.links-of-author { + //clearfix(); + display: flex; + flex-wrap: wrap; + justify-content: center; +} +.links-of-author-item { + sidebar-inline-links-item(); + + a { + display: block; + text-decoration: none; + + &:hover { + border-radius: 4px; + background: $gainsboro; + } + } + + .fa { + margin-right: 2px; + font-size: 16px; + } + .fa-globe { font-size: 15px; } +} + + +.links-of-blogroll { + text-align: center; + margin-top: 20px; + padding: 3px 0 0; + border-top: 1px dotted $grey-light; +} +.links-of-blogroll-title { margin-top: 0; } +.links-of-blogroll-item { padding: 0; } +.links-of-blogroll-inline { + clearfix(); + + .links-of-blogroll-item { + sidebar-inline-links-item(); + display: inline-block; + if !hexo-config('social_icons.icons_only') { width: unset; } + } +} diff --git a/themes/next-5.1.4/source/css/_schemes/Pisces/index.styl b/themes/next-5.1.4/source/css/_schemes/Pisces/index.styl new file mode 100644 index 0000000..cda4936 --- /dev/null +++ b/themes/next-5.1.4/source/css/_schemes/Pisces/index.styl @@ -0,0 +1,5 @@ +@import "_layout"; +@import "_brand"; +@import "_menu"; +@import "_sidebar"; +@import "_posts"; diff --git a/themes/next-5.1.4/source/css/_variables/Gemini.styl b/themes/next-5.1.4/source/css/_variables/Gemini.styl new file mode 100644 index 0000000..4d6e7e0 --- /dev/null +++ b/themes/next-5.1.4/source/css/_variables/Gemini.styl @@ -0,0 +1,21 @@ +// Variables of Gemini scheme +// ================================================= + +@import "Pisces.styl"; + +// Settings for some of the most global styles. +// -------------------------------------------------- +$body-bg-color = #eee +$main-desktop = 75% +$sidebar-desktop = 240px +$content-desktop = calc(100% - 252px) + +// Borders. +// -------------------------------------------------- +$box-shadow-inner = 0 2px 2px 0 rgba(0,0,0,.12), 0 3px 1px -2px rgba(0,0,0,.06), 0 1px 5px 0 rgba(0,0,0,.12) +$box-shadow = 0 2px 2px 0 rgba(0,0,0,.12), 0 3px 1px -2px rgba(0,0,0,.06), 0 1px 5px 0 rgba(0,0,0,.12), 0 -1px .5px 0 rgba(0,0,0,.09) + +$border-radius-inner = initial +$border-radius = initial +//$border-radius-inner = 0 0 3px 3px; +//$border-radius = 3px; diff --git a/themes/next-5.1.4/source/css/_variables/Mist.styl b/themes/next-5.1.4/source/css/_variables/Mist.styl new file mode 100644 index 0000000..8ead36e --- /dev/null +++ b/themes/next-5.1.4/source/css/_variables/Mist.styl @@ -0,0 +1,13 @@ +// Variables of Mist scheme +// ================================================= + +$font-size-headings-base = 26px + +$brand-color = $black-deep +$brand-hover-color = $brand-color + +$site-meta-text-align = left +$posts-collapse-left = 0 + +$btn-default-color = $link-color +$btn-default-bg = transparent diff --git a/themes/next-5.1.4/source/css/_variables/Muse.styl b/themes/next-5.1.4/source/css/_variables/Muse.styl new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/source/css/_variables/Pisces.styl b/themes/next-5.1.4/source/css/_variables/Pisces.styl new file mode 100644 index 0000000..320aeb1 --- /dev/null +++ b/themes/next-5.1.4/source/css/_variables/Pisces.styl @@ -0,0 +1,77 @@ +// Variables of Pisces scheme +// ================================================= + +// Settings for some of the most global styles. +// -------------------------------------------------- +$body-bg-color = #f5f7f9 + + +// Borders +// -------------------------------------------------- +$box-shadow-inner = initial; +$box-shadow = initial; + +$border-radius-inner = initial; +$border-radius = initial; + + +// Header +// -------------------------------------------------- +$subtitle-color = $gray-lighter + +// Sidebar +// -------------------------------------------------- +$sidebar-offset = unit(hexo-config('sidebar.offset'), px) if hexo-config('sidebar.offset') is a 'unit' + +$sidebar-nav-hover-color = $orange +$sidebar-highlight = $orange + +$site-author-image-width = 120px +$site-author-image-border-width = 1px +$site-author-image-border-color = $gainsboro + +$site-author-name-margin = 0 +$site-author-name-color = $black-deep +$site-author-name-align = center +$site-author-name-weight = $font-weight-bold + +$site-description-font-size = 13px +$site-description-color = $grey-dark +$site-description-margin-top = 0 +$site-description-align = center + +$site-state-item-count-font-size = 16px +$site-state-item-name-font-size = 13px +$site-state-item-name-color = $grey-dark +$site-state-item-border-color = $gainsboro + +$toc-link-color = $grey-dim +$toc-link-border-color = $grey-light +$toc-link-hover-color = black +$toc-link-hover-border-color = black +$toc-link-active-color = $sidebar-highlight +$toc-link-active-border-color = $sidebar-highlight +$toc-link-active-current-color = $sidebar-highlight +$toc-link-active-current-border-color = $sidebar-highlight + + +// Components +// -------------------------------------------------- + +// Button +$btn-default-radius = 2px +$btn-default-bg = white +$btn-default-color = $text-color +$btn-default-border-color = $text-color +$btn-default-hover-color = white +$btn-default-hover-bg = $black-deep + +// Full Image Tag +$full-image-width = 118% +$full-image-margin-horizontal = -9% +$full-image-margin-vertical = 0 + +// Back to top +$b2t-opacity = .6 +$b2t-position-bottom = -100px +$b2t-position-bottom-on = 30px diff --git a/themes/next-5.1.4/source/css/_variables/base.styl b/themes/next-5.1.4/source/css/_variables/base.styl new file mode 100644 index 0000000..fcd7830 --- /dev/null +++ b/themes/next-5.1.4/source/css/_variables/base.styl @@ -0,0 +1,416 @@ +// +// Variables +// ================================================= + + + +// Colors +// colors for use across theme. +// -------------------------------------------------- + +$whitesmoke = #f5f5f5 +$gainsboro = #eee +$gray-lighter = #ddd +$grey-light = #ccc +$grey = #bbb +$grey-dark = #999 +$grey-dim = #666 +$black-light = #555 +$black-dim = #333 +$black-deep = #222 +$red = #ff2a2a +$blue-bright = #87daff +$blue = #0684bd +$blue-deep = #262a30 +$orange = #fc6423 + + + +// Scaffolding +// Settings for some of the most global styles. +// -------------------------------------------------- + +// Global text color on +$text-color = $black-light + +// Global link color. +$link-color = $black-light +$link-hover-color = $black-deep +$link-decoration-color = $grey-light +$link-decoration-hover-color = $black-deep + +// Global border color. +$border-color = $grey-light + +// Background color for +$body-bg-color = white + +// Selection +$selection-bg = $blue-deep +$selection-color = white + + + +// Typography +// Font, line-height, and elements colors. +// -------------------------------------------------- + + +get_font_family(config) { + custom_family = hexo-config('font.' + config + '.family') + return custom_family is a 'string' ? custom_family : null +} + +// Font families. +$font-family-chinese = "PingFang SC", "Microsoft YaHei" + +$font-family-base = $font-family-chinese, sans-serif +$font-family-base = get_font_family('global'), $font-family-chinese, sans-serif if get_font_family('global') + +$font-family-logo = $font-family-base +$font-family-logo = get_font_family('logo'), $font-family-base if get_font_family('logo') + +$font-family-headings = $font-family-base +$font-family-headings = get_font_family('headings'), $font-family-base if get_font_family('headings') + +$font-family-posts = $font-family-base +$font-family-posts = get_font_family('posts'), $font-family-base if get_font_family('posts') + +$font-family-monospace = consolas, Menlo, $font-family-chinese, monospace +$font-family-monospace = get_font_family('codes'), consolas, Menlo, $font-family-chinese, monospace if get_font_family('codes') + +$font-family-icons = 'FontAwesome' + + +// Font Weight +$font-weight-lighter = 200 +$font-weight-light = 300 +$font-weight-normal = 400 +$font-weight-bold = 600 +$font-weight-bolder = 700 + + +// Font size +$font-size-base = 14px +$font-size-base = unit(hexo-config('font.global.size'), px) if hexo-config('font.global.size') is a 'unit' +$font-size-small = $font-size-base - 2px +$font-size-smaller = $font-size-base - 4px +$font-size-large = $font-size-base + 2px +$font-size-larger = $font-size-base + 4px + + +// Headings font size +$font-size-headings-step = 2px +$font-size-headings-base = 24px +$font-size-headings-base = unit(hexo-config('font.headings.size'), px) if hexo-config('font.headings.size') is a 'unit' +$font-size-headings-small = $font-size-headings-base - $font-size-headings-step +$font-size-headings-smaller = $font-size-headings-small - $font-size-headings-step +$font-size-headings-large = $font-size-headings-base + $font-size-headings-step +$font-size-headings-larger = $font-size-headings-large + $font-size-headings-step + +// Global line height +$line-height-base = 2 +$line-height-code-block = 1.6 // Can't be less than 1.3 + + + +// Z-index master list +// -------------------------------------------------- +$zindex-bottom = -1 +$zindex-1 = 1010 +$zindex-2 = 1020 +$zindex-3 = 1030 +$zindex-4 = 1040 +$zindex-5 = 1050 + + + +// Table +// -------------------------------------------------- +$table-width = 100% +$table-border-color = $gray-lighter +$table-font-size = 14px +$table-content-alignment = left +$table-content-vertical = middle +$table-th-font-weight = 700 +$table-cell-padding = 8px +$table-cell-border-right-color = $gainsboro +$table-cell-border-bottom-color = $gray-lighter +$table-row-odd-bg-color = #f9f9f9 +$table-row-hover-bg-color = $whitesmoke + + + +// Code & Code Blocks +// -------------------------------------------------- +$code-font-family = $font-family-monospace +$code-font-size = 13px +$code-font-size = unit(hexo-config('font.codes.size'), px) if hexo-config('font.codes.size') is a 'unit' +$code-border-radius = 3px +$code-foreground = $black-light +$code-background = $gainsboro + + + +// Buttons +// -------------------------------------------------- + +$btn-font-weight = normal + +$btn-default-radius = 0 +$btn-default-bg = $black-deep +$btn-default-color = white +$btn-default-font-size = 14px +$btn-default-border-width = 2px +$btn-default-border-color = $black-deep +$btn-default-hover-bg = white +$btn-default-hover-color = $black-deep +$btn-default-hover-border-color = $black-deep + + + +// Pagination +// -------------------------------------------------- + +$pagination-border = $gainsboro + +$pagination-link-bg = transparent +$pagination-link-color = $link-color +$pagination-link-border = $gainsboro + +$pagination-link-hover-bg = transparent +$pagination-link-hover-color = $link-color +$pagination-link-hover-border = $black-deep + +$pagination-active-bg = $grey-light +$pagination-active-color = white +$pagination-active-border = $grey-light + + + +// Layout sizes +// -------------------------------------------------- + +$main-desktop = 960px +$main-desktop-large = 1200px + +$content-desktop = 700px +$content-desktop-large = 900px + +$content-desktop-padding = 40px +$content-tablet-padding = 10px +$content-mobile-padding = 8px + +$sidebar-desktop = 240px + +$footer-height = 50px + +$gap-between-main-and-footer = 100px + + + +// Headband +// -------------------------------------------------- +$headband-height = 3px +$headband-bg = $black-deep + + + +// Section Header +// Variables for header section elements. +// -------------------------------------------------- + +$head-bg = transparent + +// Site Meta +$site-meta-text-align = center +$brand-color = white +$brand-hover-color = white +$brand-bg = $black-deep + +$logo-font-size = 20px +$logo-font-size = unit(hexo-config('font.logo.size'), px) if hexo-config('font.logo.size') is a 'unit' + +$site-subtitle-color = $grey-dark +$subtitle-font-size = 13px +$subtitle-color = $grey-dark + +// Menu +$menu-link-border = transparent +$menu-link-hover-border = $black-deep + + + +// Posts Expand +// -------------------------------------------------- +$posts-expand-title-font-weight = $font-weight-normal +$post-copyright = { + margin: 2em 0 0, + padding: .5em 1em, + bg: #f9f9f9, + border: { + width: 3px, + style: solid, + color: #ff1700 + } +} + + +// Posts Collpase +// -------------------------------------------------- +$posts-collapse-left = 55px +$posts-collapse-left-mobile = 5px + + +// Sidebar +// Variables for sidebar section elements. +// -------------------------------------------------- +$sidebar-nav-color = $black-light +$sidebar-nav-hover-color = $whitesmoke +$sidebar-highlight = $blue-bright + +$site-author-image-padding = 2px +$site-author-image-width = 96px +$site-author-image-height = auto +$site-author-image-border-width = 2px +$site-author-image-border-color = $black-dim + +$site-author-name-margin = 5px 0 0 +$site-author-name-color = $whitesmoke +$site-author-name-align = center +$site-author-name-weight = normal + +$site-description-font-size = 14px +$site-description-color = $grey-dark +$site-description-margin-top = 5px +$site-description-align = center + +$site-state-align = center +$site-state-item-count-font-size = 18px +$site-state-item-count-color = inherit +$site-state-item-name-font-size = 13px +$site-state-item-name-color = inherit +$site-state-item-border-color = $black-dim + +$toc-link-color = $grey-dark +$toc-link-border-color = $black-light +$toc-link-hover-color = $grey-light +$toc-link-hover-border-color = $grey-light +$toc-link-active-color = $sidebar-highlight +$toc-link-active-border-color = $sidebar-highlight +$toc-link-active-current-color = $sidebar-highlight +$toc-link-active-current-border-color = $sidebar-highlight + + +// Components +// -------------------------------------------------- + +// Back to top +$b2t-opacity = 1 +$b2t-position-bottom = -100px +$b2t-position-bottom-on = 19px +$b2t-position-right = 30px +$b2t-font-size = 12px +$b2t-color = white +$b2t-bg-color = $black-deep + +// full-image +$full-image-width = 110% +$full-image-margin-horizontal = -5% +$full-image-margin-vertical = 25px + +// .post-expand .post-eof +// In Muse scheme, margin above and below the post separator +$post-eof-margin-top = 80px // or 160px for more white space +$post-eof-margin-bottom = 60px // or 120px for less white space + + +// Iconography +// Icons SVG Base64 +// -------------------------------------------------- + +// blockquote-center icon +$center-quote-left = '../images/quote-l.svg' +$center-quote-right = '../images/quote-r.svg' + + +// Note colors +// -------------------------------------------------- +// Read note light_bg_offset from NexT config and set in "lbg%" to use it as string variable. +hexo-config('note.light_bg_offset') is a 'unit' ? (lbg = unit(hexo-config('note.light_bg_offset'),"%")) : (lbg = 0) + +// Default +$note-default-border = #777 +$note-default-bg = lighten(spin($note-default-border, 0), 94% + lbg) +$note-default-text = $note-default-border +$note-default-icon = "\f0a9" + +$note-modern-default-border = #e1e1e1 +$note-modern-default-bg = lighten(spin($note-modern-default-border, 10), 60% + (lbg * 4)) +$note-modern-default-text = $grey-dim +$note-modern-default-hover = darken(spin($note-modern-default-text, -10), 32%) + +// Primary +$note-primary-border = #6f42c1 +$note-primary-bg = lighten(spin($note-primary-border, 10), 92% + lbg) +$note-primary-text = $note-primary-border +$note-primary-icon = "\f055" + +$note-modern-primary-border = #e1c2ff +$note-modern-primary-bg = lighten(spin($note-modern-primary-border, 10), 40% + (lbg * 4)) +$note-modern-primary-text = #6f42c1 +$note-modern-primary-hover = darken(spin($note-modern-primary-text, -10), 22%) + +// Info +$note-info-border = #428bca +$note-info-bg = lighten(spin($note-info-border, -10), 91% + lbg) +$note-info-text = $note-info-border +$note-info-icon = "\f05a" + +$note-modern-info-border = #b3e5ef +$note-modern-info-bg = lighten(spin($note-modern-info-border, 10), 50% + (lbg * 4)) +$note-modern-info-text = #31708f +$note-modern-info-hover = darken(spin($note-modern-info-text, -10), 32%) + +// Success +$note-success-border = #5cb85c +$note-success-bg = lighten(spin($note-success-border, 10), 90% + lbg) +$note-success-text = $note-success-border +$note-success-icon = "\f058" + +$note-modern-success-border = #d0e6be +$note-modern-success-bg = lighten(spin($note-modern-success-border, 10), 40% + (lbg * 4)) +$note-modern-success-text = #3c763d +$note-modern-success-hover = darken(spin($note-modern-success-text, -10), 27%) + +// Warning +$note-warning-border = #f0ad4e +$note-warning-bg = lighten(spin($note-warning-border, 10), 88% + lbg) +$note-warning-text = $note-warning-border +$note-warning-icon = "\f06a" + +$note-modern-warning-border = #fae4cd +$note-modern-warning-bg = lighten(spin($note-modern-warning-border, 10), 43% + (lbg * 4)) +$note-modern-warning-text = #8a6d3b +$note-modern-warning-hover = darken(spin($note-modern-warning-text, -10), 18%) + +// Danger +$note-danger-border = #d9534f +$note-danger-bg = lighten(spin($note-danger-border, -10), 92% + lbg) +$note-danger-text = $note-danger-border +$note-danger-icon = "\f056" + +$note-modern-danger-border = #ebcdd2 +$note-modern-danger-bg = lighten(spin($note-modern-danger-border, 10), 35% + (lbg * 4)) +$note-modern-danger-text = #a94442 +$note-modern-danger-hover = darken(spin($note-modern-danger-text, -10), 22%) + + +// Label colors +// -------------------------------------------------- +$label-default = lighten(spin($note-default-border, 0), 89% + lbg) +$label-primary = lighten(spin($note-primary-border, 10), 87% + lbg) +$label-info = lighten(spin($note-info-border, -10), 86% + lbg) +$label-success = lighten(spin($note-success-border, 10), 85% + lbg) +$label-warning = lighten(spin($note-warning-border, 10), 83% + lbg) +$label-danger = lighten(spin($note-danger-border, -10), 87% + lbg) diff --git a/themes/next-5.1.4/source/css/_variables/custom.styl b/themes/next-5.1.4/source/css/_variables/custom.styl new file mode 100644 index 0000000..e69de29 diff --git a/themes/next-5.1.4/source/css/main.styl b/themes/next-5.1.4/source/css/main.styl new file mode 100644 index 0000000..d46298d --- /dev/null +++ b/themes/next-5.1.4/source/css/main.styl @@ -0,0 +1,45 @@ +// CSS Style Guide: http://codeguide.co/#css + + + +$scheme = hexo-config('scheme') ? hexo-config('scheme') : 'Muse'; +$variables = base $scheme custom; +$mixins = base $scheme custom; + + + +// Variables Layer +// -------------------------------------------------- +for $variable in $variables + @import "_variables/" + $variable + + +// Mixins Layer +// -------------------------------------------------- +for $mixin in $mixins + @import "_mixins/" + $mixin; + + + +// Common Layer +// -------------------------------------------------- + +// Scaffolding +@import "_common/scaffolding"; + +// Layout +@import "_common/outline"; + +// Components +@import "_common/components"; + + +// Schemes Layer +// -------------------------------------------------- +@import "_schemes/" + $scheme; + + + +// Custom Layer +// -------------------------------------------------- +@import "_custom/custom"; diff --git a/themes/next-5.1.4/source/fonts/.gitkeep b/themes/next-5.1.4/source/fonts/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/images/algolia_logo.svg b/themes/next-5.1.4/source/images/algolia_logo.svg similarity index 100% rename from images/algolia_logo.svg rename to themes/next-5.1.4/source/images/algolia_logo.svg diff --git a/images/apple-touch-icon-next.png b/themes/next-5.1.4/source/images/apple-touch-icon-next.png similarity index 100% rename from images/apple-touch-icon-next.png rename to themes/next-5.1.4/source/images/apple-touch-icon-next.png diff --git a/images/avatar.gif b/themes/next-5.1.4/source/images/avatar.gif similarity index 100% rename from images/avatar.gif rename to themes/next-5.1.4/source/images/avatar.gif diff --git a/images/cc-by-nc-nd.svg b/themes/next-5.1.4/source/images/cc-by-nc-nd.svg similarity index 100% rename from images/cc-by-nc-nd.svg rename to themes/next-5.1.4/source/images/cc-by-nc-nd.svg diff --git a/images/cc-by-nc-sa.svg b/themes/next-5.1.4/source/images/cc-by-nc-sa.svg similarity index 100% rename from images/cc-by-nc-sa.svg rename to themes/next-5.1.4/source/images/cc-by-nc-sa.svg diff --git a/images/cc-by-nc.svg b/themes/next-5.1.4/source/images/cc-by-nc.svg similarity index 100% rename from images/cc-by-nc.svg rename to themes/next-5.1.4/source/images/cc-by-nc.svg diff --git a/images/cc-by-nd.svg b/themes/next-5.1.4/source/images/cc-by-nd.svg similarity index 100% rename from images/cc-by-nd.svg rename to themes/next-5.1.4/source/images/cc-by-nd.svg diff --git a/images/cc-by-sa.svg b/themes/next-5.1.4/source/images/cc-by-sa.svg similarity index 100% rename from images/cc-by-sa.svg rename to themes/next-5.1.4/source/images/cc-by-sa.svg diff --git a/images/cc-by.svg b/themes/next-5.1.4/source/images/cc-by.svg similarity index 100% rename from images/cc-by.svg rename to themes/next-5.1.4/source/images/cc-by.svg diff --git a/images/cc-zero.svg b/themes/next-5.1.4/source/images/cc-zero.svg similarity index 100% rename from images/cc-zero.svg rename to themes/next-5.1.4/source/images/cc-zero.svg diff --git a/images/favicon-16x16-next.png b/themes/next-5.1.4/source/images/favicon-16x16-next.png similarity index 100% rename from images/favicon-16x16-next.png rename to themes/next-5.1.4/source/images/favicon-16x16-next.png diff --git a/images/favicon-32x32-next.png b/themes/next-5.1.4/source/images/favicon-32x32-next.png similarity index 100% rename from images/favicon-32x32-next.png rename to themes/next-5.1.4/source/images/favicon-32x32-next.png diff --git a/images/loading.gif b/themes/next-5.1.4/source/images/loading.gif similarity index 100% rename from images/loading.gif rename to themes/next-5.1.4/source/images/loading.gif diff --git a/images/logo.svg b/themes/next-5.1.4/source/images/logo.svg similarity index 100% rename from images/logo.svg rename to themes/next-5.1.4/source/images/logo.svg diff --git a/images/placeholder.gif b/themes/next-5.1.4/source/images/placeholder.gif similarity index 100% rename from images/placeholder.gif rename to themes/next-5.1.4/source/images/placeholder.gif diff --git a/images/quote-l.svg b/themes/next-5.1.4/source/images/quote-l.svg similarity index 100% rename from images/quote-l.svg rename to themes/next-5.1.4/source/images/quote-l.svg diff --git a/images/quote-r.svg b/themes/next-5.1.4/source/images/quote-r.svg similarity index 100% rename from images/quote-r.svg rename to themes/next-5.1.4/source/images/quote-r.svg diff --git a/images/searchicon.png b/themes/next-5.1.4/source/images/searchicon.png similarity index 100% rename from images/searchicon.png rename to themes/next-5.1.4/source/images/searchicon.png diff --git a/js/src/affix.js b/themes/next-5.1.4/source/js/src/affix.js similarity index 100% rename from js/src/affix.js rename to themes/next-5.1.4/source/js/src/affix.js diff --git a/js/src/algolia-search.js b/themes/next-5.1.4/source/js/src/algolia-search.js similarity index 100% rename from js/src/algolia-search.js rename to themes/next-5.1.4/source/js/src/algolia-search.js diff --git a/js/src/bootstrap.js b/themes/next-5.1.4/source/js/src/bootstrap.js similarity index 100% rename from js/src/bootstrap.js rename to themes/next-5.1.4/source/js/src/bootstrap.js diff --git a/js/src/exturl.js b/themes/next-5.1.4/source/js/src/exturl.js similarity index 100% rename from js/src/exturl.js rename to themes/next-5.1.4/source/js/src/exturl.js diff --git a/js/src/hook-duoshuo.js b/themes/next-5.1.4/source/js/src/hook-duoshuo.js similarity index 100% rename from js/src/hook-duoshuo.js rename to themes/next-5.1.4/source/js/src/hook-duoshuo.js diff --git a/js/src/js.cookie.js b/themes/next-5.1.4/source/js/src/js.cookie.js similarity index 100% rename from js/src/js.cookie.js rename to themes/next-5.1.4/source/js/src/js.cookie.js diff --git a/js/src/motion.js b/themes/next-5.1.4/source/js/src/motion.js similarity index 100% rename from js/src/motion.js rename to themes/next-5.1.4/source/js/src/motion.js diff --git a/js/src/post-details.js b/themes/next-5.1.4/source/js/src/post-details.js similarity index 100% rename from js/src/post-details.js rename to themes/next-5.1.4/source/js/src/post-details.js diff --git a/js/src/schemes/pisces.js b/themes/next-5.1.4/source/js/src/schemes/pisces.js similarity index 100% rename from js/src/schemes/pisces.js rename to themes/next-5.1.4/source/js/src/schemes/pisces.js diff --git a/js/src/scroll-cookie.js b/themes/next-5.1.4/source/js/src/scroll-cookie.js similarity index 100% rename from js/src/scroll-cookie.js rename to themes/next-5.1.4/source/js/src/scroll-cookie.js diff --git a/js/src/scrollspy.js b/themes/next-5.1.4/source/js/src/scrollspy.js similarity index 100% rename from js/src/scrollspy.js rename to themes/next-5.1.4/source/js/src/scrollspy.js diff --git a/js/src/utils.js b/themes/next-5.1.4/source/js/src/utils.js similarity index 100% rename from js/src/utils.js rename to themes/next-5.1.4/source/js/src/utils.js diff --git a/lib/Han/dist/font/han-space.otf b/themes/next-5.1.4/source/lib/Han/dist/font/han-space.otf similarity index 100% rename from lib/Han/dist/font/han-space.otf rename to themes/next-5.1.4/source/lib/Han/dist/font/han-space.otf diff --git a/lib/Han/dist/font/han-space.woff b/themes/next-5.1.4/source/lib/Han/dist/font/han-space.woff similarity index 100% rename from lib/Han/dist/font/han-space.woff rename to themes/next-5.1.4/source/lib/Han/dist/font/han-space.woff diff --git a/lib/Han/dist/font/han.otf b/themes/next-5.1.4/source/lib/Han/dist/font/han.otf similarity index 100% rename from lib/Han/dist/font/han.otf rename to themes/next-5.1.4/source/lib/Han/dist/font/han.otf diff --git a/lib/Han/dist/font/han.woff b/themes/next-5.1.4/source/lib/Han/dist/font/han.woff similarity index 100% rename from lib/Han/dist/font/han.woff rename to themes/next-5.1.4/source/lib/Han/dist/font/han.woff diff --git a/lib/Han/dist/font/han.woff2 b/themes/next-5.1.4/source/lib/Han/dist/font/han.woff2 similarity index 100% rename from lib/Han/dist/font/han.woff2 rename to themes/next-5.1.4/source/lib/Han/dist/font/han.woff2 diff --git a/lib/Han/dist/han.css b/themes/next-5.1.4/source/lib/Han/dist/han.css similarity index 100% rename from lib/Han/dist/han.css rename to themes/next-5.1.4/source/lib/Han/dist/han.css diff --git a/lib/Han/dist/han.js b/themes/next-5.1.4/source/lib/Han/dist/han.js similarity index 100% rename from lib/Han/dist/han.js rename to themes/next-5.1.4/source/lib/Han/dist/han.js diff --git a/lib/Han/dist/han.min.css b/themes/next-5.1.4/source/lib/Han/dist/han.min.css similarity index 100% rename from lib/Han/dist/han.min.css rename to themes/next-5.1.4/source/lib/Han/dist/han.min.css diff --git a/lib/Han/dist/han.min.js b/themes/next-5.1.4/source/lib/Han/dist/han.min.js similarity index 100% rename from lib/Han/dist/han.min.js rename to themes/next-5.1.4/source/lib/Han/dist/han.min.js diff --git a/lib/algolia-instant-search/instantsearch.min.css b/themes/next-5.1.4/source/lib/algolia-instant-search/instantsearch.min.css similarity index 100% rename from lib/algolia-instant-search/instantsearch.min.css rename to themes/next-5.1.4/source/lib/algolia-instant-search/instantsearch.min.css diff --git a/lib/algolia-instant-search/instantsearch.min.js b/themes/next-5.1.4/source/lib/algolia-instant-search/instantsearch.min.js similarity index 100% rename from lib/algolia-instant-search/instantsearch.min.js rename to themes/next-5.1.4/source/lib/algolia-instant-search/instantsearch.min.js diff --git a/lib/canvas-nest/canvas-nest.min.js b/themes/next-5.1.4/source/lib/canvas-nest/canvas-nest.min.js similarity index 100% rename from lib/canvas-nest/canvas-nest.min.js rename to themes/next-5.1.4/source/lib/canvas-nest/canvas-nest.min.js diff --git a/lib/canvas-ribbon/canvas-ribbon.js b/themes/next-5.1.4/source/lib/canvas-ribbon/canvas-ribbon.js similarity index 100% rename from lib/canvas-ribbon/canvas-ribbon.js rename to themes/next-5.1.4/source/lib/canvas-ribbon/canvas-ribbon.js diff --git a/themes/next-5.1.4/source/lib/fancybox/.bower.json b/themes/next-5.1.4/source/lib/fancybox/.bower.json new file mode 100644 index 0000000..fe9e086 --- /dev/null +++ b/themes/next-5.1.4/source/lib/fancybox/.bower.json @@ -0,0 +1,15 @@ +{ + "name": "fancybox", + "homepage": "https://github.com/fancyapps/fancyBox", + "version": "2.1.5", + "_release": "2.1.5", + "_resolution": { + "type": "version", + "tag": "v2.1.5", + "commit": "18d171278d21ca59067aace6d52a1adeb6462219" + }, + "_source": "git://github.com/fancyapps/fancyBox.git", + "_target": "~2.1.5", + "_originalSource": "fancybox", + "_direct": true +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/lib/fancybox/.gitattributes b/themes/next-5.1.4/source/lib/fancybox/.gitattributes new file mode 100644 index 0000000..f6bb280 --- /dev/null +++ b/themes/next-5.1.4/source/lib/fancybox/.gitattributes @@ -0,0 +1,7 @@ +# Auto detect text files and perform LF normalization +* text=auto + +# Denote all files that are truly binary and should not be modified. +*.png binary +*.jpg binary +*.gif binary \ No newline at end of file diff --git a/themes/next-5.1.4/source/lib/fancybox/source/blank.gif b/themes/next-5.1.4/source/lib/fancybox/source/blank.gif new file mode 100644 index 0000000..35d42e8 Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/blank.gif differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading.gif b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading.gif new file mode 100644 index 0000000..a03a40c Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading.gif differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading@2x.gif b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading@2x.gif new file mode 100644 index 0000000..9205aeb Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_loading@2x.gif differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/fancybox_overlay.png b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_overlay.png new file mode 100644 index 0000000..a439139 Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_overlay.png differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite.png b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite.png new file mode 100644 index 0000000..fd8d5ca Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite.png differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite@2x.png b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite@2x.png new file mode 100644 index 0000000..d0e4779 Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/fancybox_sprite@2x.png differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/helpers/fancybox_buttons.png b/themes/next-5.1.4/source/lib/fancybox/source/helpers/fancybox_buttons.png new file mode 100644 index 0000000..0787207 Binary files /dev/null and b/themes/next-5.1.4/source/lib/fancybox/source/helpers/fancybox_buttons.png differ diff --git a/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-buttons.css b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-buttons.css new file mode 100644 index 0000000..a26273a --- /dev/null +++ b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-buttons.css @@ -0,0 +1,97 @@ +#fancybox-buttons { + position: fixed; + left: 0; + width: 100%; + z-index: 8050; +} + +#fancybox-buttons.top { + top: 10px; +} + +#fancybox-buttons.bottom { + bottom: 10px; +} + +#fancybox-buttons ul { + display: block; + width: 166px; + height: 30px; + margin: 0 auto; + padding: 0; + list-style: none; + border: 1px solid #111; + border-radius: 3px; + -webkit-box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); + -moz-box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); + box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); + background: rgb(50,50,50); + background: -moz-linear-gradient(top, rgb(68,68,68) 0%, rgb(52,52,52) 50%, rgb(41,41,41) 50%, rgb(51,51,51) 100%); + background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgb(68,68,68)), color-stop(50%,rgb(52,52,52)), color-stop(50%,rgb(41,41,41)), color-stop(100%,rgb(51,51,51))); + background: -webkit-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); + background: -o-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); + background: -ms-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); + background: linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#444444', endColorstr='#222222',GradientType=0 ); +} + +#fancybox-buttons ul li { + float: left; + margin: 0; + padding: 0; +} + +#fancybox-buttons a { + display: block; + width: 30px; + height: 30px; + text-indent: -9999px; + background-color: transparent; + background-image: url('fancybox_buttons.png'); + background-repeat: no-repeat; + outline: none; + opacity: 0.8; +} + +#fancybox-buttons a:hover { + opacity: 1; +} + +#fancybox-buttons a.btnPrev { + background-position: 5px 0; +} + +#fancybox-buttons a.btnNext { + background-position: -33px 0; + border-right: 1px solid #3e3e3e; +} + +#fancybox-buttons a.btnPlay { + background-position: 0 -30px; +} + +#fancybox-buttons a.btnPlayOn { + background-position: -30px -30px; +} + +#fancybox-buttons a.btnToggle { + background-position: 3px -60px; + border-left: 1px solid #111; + border-right: 1px solid #3e3e3e; + width: 35px +} + +#fancybox-buttons a.btnToggleOn { + background-position: -27px -60px; +} + +#fancybox-buttons a.btnClose { + border-left: 1px solid #111; + width: 35px; + background-position: -56px 0px; +} + +#fancybox-buttons a.btnDisabled { + opacity : 0.4; + cursor: default; +} \ No newline at end of file diff --git a/lib/fancybox/source/helpers/jquery.fancybox-buttons.js b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-buttons.js similarity index 100% rename from lib/fancybox/source/helpers/jquery.fancybox-buttons.js rename to themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-buttons.js diff --git a/lib/fancybox/source/helpers/jquery.fancybox-media.js b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-media.js similarity index 100% rename from lib/fancybox/source/helpers/jquery.fancybox-media.js rename to themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-media.js diff --git a/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-thumbs.css b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-thumbs.css new file mode 100644 index 0000000..63d2943 --- /dev/null +++ b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-thumbs.css @@ -0,0 +1,55 @@ +#fancybox-thumbs { + position: fixed; + left: 0; + width: 100%; + overflow: hidden; + z-index: 8050; +} + +#fancybox-thumbs.bottom { + bottom: 2px; +} + +#fancybox-thumbs.top { + top: 2px; +} + +#fancybox-thumbs ul { + position: relative; + list-style: none; + margin: 0; + padding: 0; +} + +#fancybox-thumbs ul li { + float: left; + padding: 1px; + opacity: 0.5; +} + +#fancybox-thumbs ul li.active { + opacity: 0.75; + padding: 0; + border: 1px solid #fff; +} + +#fancybox-thumbs ul li:hover { + opacity: 1; +} + +#fancybox-thumbs ul li a { + display: block; + position: relative; + overflow: hidden; + border: 1px solid #222; + background: #111; + outline: none; +} + +#fancybox-thumbs ul li img { + display: block; + position: relative; + border: 0; + padding: 0; + max-width: none; +} \ No newline at end of file diff --git a/lib/fancybox/source/helpers/jquery.fancybox-thumbs.js b/themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-thumbs.js similarity index 100% rename from lib/fancybox/source/helpers/jquery.fancybox-thumbs.js rename to themes/next-5.1.4/source/lib/fancybox/source/helpers/jquery.fancybox-thumbs.js diff --git a/lib/fancybox/source/jquery.fancybox.css b/themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.css similarity index 100% rename from lib/fancybox/source/jquery.fancybox.css rename to themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.css diff --git a/lib/fancybox/source/jquery.fancybox.js b/themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.js similarity index 100% rename from lib/fancybox/source/jquery.fancybox.js rename to themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.js diff --git a/lib/fancybox/source/jquery.fancybox.pack.js b/themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.pack.js similarity index 100% rename from lib/fancybox/source/jquery.fancybox.pack.js rename to themes/next-5.1.4/source/lib/fancybox/source/jquery.fancybox.pack.js diff --git a/themes/next-5.1.4/source/lib/fastclick/.bower.json b/themes/next-5.1.4/source/lib/fastclick/.bower.json new file mode 100644 index 0000000..cfabed7 --- /dev/null +++ b/themes/next-5.1.4/source/lib/fastclick/.bower.json @@ -0,0 +1,24 @@ +{ + "name": "fastclick", + "main": "lib/fastclick.js", + "ignore": [ + "**/.*", + "component.json", + "package.json", + "Makefile", + "tests", + "examples" + ], + "homepage": "https://github.com/ftlabs/fastclick", + "version": "1.0.6", + "_release": "1.0.6", + "_resolution": { + "type": "version", + "tag": "v1.0.6", + "commit": "2ac7258407619398005ca720596f0d36ce66a6c8" + }, + "_source": "git://github.com/ftlabs/fastclick.git", + "_target": "~1.0.6", + "_originalSource": "fastclick", + "_direct": true +} \ No newline at end of file diff --git a/lib/fastclick/LICENSE b/themes/next-5.1.4/source/lib/fastclick/LICENSE similarity index 100% rename from lib/fastclick/LICENSE rename to themes/next-5.1.4/source/lib/fastclick/LICENSE diff --git a/themes/next-5.1.4/source/lib/fastclick/README.md b/themes/next-5.1.4/source/lib/fastclick/README.md new file mode 100644 index 0000000..074895d --- /dev/null +++ b/themes/next-5.1.4/source/lib/fastclick/README.md @@ -0,0 +1,140 @@ +# FastClick # + +FastClick is a simple, easy-to-use library for eliminating the 300ms delay between a physical tap and the firing of a `click` event on mobile browsers. The aim is to make your application feel less laggy and more responsive while avoiding any interference with your current logic. + +FastClick is developed by [FT Labs](http://labs.ft.com/), part of the Financial Times. + +[Explication en français](http://maxime.sh/2013/02/supprimer-le-lag-des-clics-sur-mobile-avec-fastclick/). + +[日本語で説明](https://developer.mozilla.org/ja/docs/Mozilla/Firefox_OS/Apps/Tips_and_techniques#Make_events_immediate)。 + +## Why does the delay exist? ## + +According to [Google](https://developers.google.com/mobile/articles/fast_buttons): + +> ...mobile browsers will wait approximately 300ms from the time that you tap the button to fire the click event. The reason for this is that the browser is waiting to see if you are actually performing a double tap. + +## Compatibility ## + +The library has been deployed as part of the [FT Web App](http://app.ft.com/) and is tried and tested on the following mobile browsers: + +* Mobile Safari on iOS 3 and upwards +* Chrome on iOS 5 and upwards +* Chrome on Android (ICS) +* Opera Mobile 11.5 and upwards +* Android Browser since Android 2 +* PlayBook OS 1 and upwards + +## When it isn't needed ## + +FastClick doesn't attach any listeners on desktop browsers. + +Chrome 32+ on Android with `width=device-width` in the [viewport meta tag](https://developer.mozilla.org/en-US/docs/Mobile/Viewport_meta_tag) doesn't have a 300ms delay, therefore listeners aren't attached. + +```html + +``` + +Same goes for Chrome on Android (all versions) with `user-scalable=no` in the viewport meta tag. But be aware that `user-scalable=no` also disables pinch zooming, which may be an accessibility concern. + +For IE11+, you can use `touch-action: manipulation;` to disable double-tap-to-zoom on certain elements (like links and buttons). For IE10 use `-ms-touch-action: manipulation`. + +## Usage ## + +Include fastclick.js in your JavaScript bundle or add it to your HTML page like this: + +```html + +``` + +The script must be loaded prior to instantiating FastClick on any element of the page. + +To instantiate FastClick on the `body`, which is the recommended method of use: + +```js +if ('addEventListener' in document) { + document.addEventListener('DOMContentLoaded', function() { + FastClick.attach(document.body); + }, false); +} +``` + +Or, if you're using jQuery: + +```js +$(function() { + FastClick.attach(document.body); +}); +``` + +If you're using Browserify or another CommonJS-style module system, the `FastClick.attach` function will be returned when you call `require('fastclick')`. As a result, the easiest way to use FastClick with these loaders is as follows: + +```js +var attachFastClick = require('fastclick'); +attachFastClick(document.body); +``` + +### Minified ### + +Run `make` to build a minified version of FastClick using the Closure Compiler REST API. The minified file is saved to `build/fastclick.min.js` or you can [download a pre-minified version](http://build.origami.ft.com/bundles/js?modules=fastclick). + +Note: the pre-minified version is built using [our build service](http://origami.ft.com/docs/developer-guide/build-service/) which exposes the `FastClick` object through `Origami.fastclick` and will have the Browserify/CommonJS API (see above). + +```js +var attachFastClick = Origami.fastclick; +attachFastClick(document.body); +``` + +### AMD ### + +FastClick has AMD (Asynchronous Module Definition) support. This allows it to be lazy-loaded with an AMD loader, such as [RequireJS](http://requirejs.org/). Note that when using the AMD style require, the full `FastClick` object will be returned, _not_ `FastClick.attach` + +```js +var FastClick = require('fastclick'); +FastClick.attach(document.body, options); +``` + +### Package managers ### + +You can install FastClick using [Component](https://github.com/component/component), [npm](https://npmjs.org/package/fastclick) or [Bower](http://bower.io/). + +For Ruby, there's a third-party gem called [fastclick-rails](http://rubygems.org/gems/fastclick-rails). For .NET there's a [NuGet package](http://nuget.org/packages/FastClick). + +## Advanced ## + +### Ignore certain elements with `needsclick` ### + +Sometimes you need FastClick to ignore certain elements. You can do this easily by adding the `needsclick` class. +```html +Ignored by FastClick +``` + +#### Use case 1: non-synthetic click required #### + +Internally, FastClick uses `document.createEvent` to fire a synthetic `click` event as soon as `touchend` is fired by the browser. It then suppresses the additional `click` event created by the browser after that. In some cases, the non-synthetic `click` event created by the browser is required, as described in the [triggering focus example](http://ftlabs.github.com/fastclick/examples/focus.html). + +This is where the `needsclick` class comes in. Add the class to any element that requires a non-synthetic click. + +#### Use case 2: Twitter Bootstrap 2.2.2 dropdowns #### + +Another example of when to use the `needsclick` class is with dropdowns in Twitter Bootstrap 2.2.2. Bootstrap add its own `touchstart` listener for dropdowns, so you want to tell FastClick to ignore those. If you don't, touch devices will automatically close the dropdown as soon as it is clicked, because both FastClick and Bootstrap execute the synthetic click, one opens the dropdown, the second closes it immediately after. + +```html +Dropdown +``` + +## Examples ## + +FastClick is designed to cope with many different browser oddities. Here are some examples to illustrate this: + +* [basic use](http://ftlabs.github.com/fastclick/examples/layer.html) showing the increase in perceived responsiveness +* [triggering focus](http://ftlabs.github.com/fastclick/examples/focus.html) on an input element from a `click` handler +* [input element](http://ftlabs.github.com/fastclick/examples/input.html) which never receives clicks but gets fast focus + +## Tests ## + +There are no automated tests. The files in `tests/` are manual reduced test cases. We've had a think about how best to test these cases, but they tend to be very browser/device specific and sometimes subjective which means it's not so trivial to test. + +## Credits and collaboration ## + +FastClick is maintained by [Rowan Beentje](http://twitter.com/rowanbeentje), [Matthew Caruana Galizia](http://twitter.com/mcaruanagalizia) and [Matthew Andrews](http://twitter.com/andrewsmatt) at [FT Labs](http://labs.ft.com). All open source code released by FT Labs is licenced under the MIT licence. We welcome comments, feedback and suggestions. Please feel free to raise an issue or pull request. diff --git a/themes/next-5.1.4/source/lib/fastclick/bower.json b/themes/next-5.1.4/source/lib/fastclick/bower.json new file mode 100644 index 0000000..18e1abd --- /dev/null +++ b/themes/next-5.1.4/source/lib/fastclick/bower.json @@ -0,0 +1,12 @@ +{ + "name": "fastclick", + "main": "lib/fastclick.js", + "ignore": [ + "**/.*", + "component.json", + "package.json", + "Makefile", + "tests", + "examples" + ] +} diff --git a/lib/fastclick/lib/fastclick.js b/themes/next-5.1.4/source/lib/fastclick/lib/fastclick.js similarity index 100% rename from lib/fastclick/lib/fastclick.js rename to themes/next-5.1.4/source/lib/fastclick/lib/fastclick.js diff --git a/lib/fastclick/lib/fastclick.min.js b/themes/next-5.1.4/source/lib/fastclick/lib/fastclick.min.js similarity index 100% rename from lib/fastclick/lib/fastclick.min.js rename to themes/next-5.1.4/source/lib/fastclick/lib/fastclick.min.js diff --git a/themes/next-5.1.4/source/lib/font-awesome/.bower.json b/themes/next-5.1.4/source/lib/font-awesome/.bower.json new file mode 100644 index 0000000..fb98b1d --- /dev/null +++ b/themes/next-5.1.4/source/lib/font-awesome/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "font-awesome", + "description": "Font Awesome", + "keywords": [], + "homepage": "http://fontawesome.io", + "dependencies": {}, + "devDependencies": {}, + "license": [ + "OFL-1.1", + "MIT", + "CC-BY-3.0" + ], + "main": [ + "less/font-awesome.less", + "scss/font-awesome.scss" + ], + "ignore": [ + "*/.*", + "*.json", + "src", + "*.yml", + "Gemfile", + "Gemfile.lock", + "*.md" + ], + "version": "4.7.0", + "_release": "4.7.0", + "_resolution": { + "type": "version", + "tag": "v4.7.0", + "commit": "a3fe90fa5f6fac55d197f9cbd18e3f57dafb716c" + }, + "_source": "https://github.com/FortAwesome/Font-Awesome.git", + "_target": "*", + "_originalSource": "fontawesome" +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/lib/font-awesome/.gitignore b/themes/next-5.1.4/source/lib/font-awesome/.gitignore new file mode 100644 index 0000000..39c4f20 --- /dev/null +++ b/themes/next-5.1.4/source/lib/font-awesome/.gitignore @@ -0,0 +1,33 @@ +*.pyc +*.egg-info +*.db +*.db.old +*.swp +*.db-journal + +.coverage +.DS_Store +.installed.cfg +_gh_pages/* + +.idea/* +.svn/* +src/website/static/* +src/website/media/* + +bin +cfcache +develop-eggs +dist +downloads +eggs +parts +tmp +.sass-cache +node_modules + +src/website/settingslocal.py +stunnel.log + +.ruby-version +.bundle diff --git a/themes/next-5.1.4/source/lib/font-awesome/.npmignore b/themes/next-5.1.4/source/lib/font-awesome/.npmignore new file mode 100644 index 0000000..54a691f --- /dev/null +++ b/themes/next-5.1.4/source/lib/font-awesome/.npmignore @@ -0,0 +1,42 @@ +*.pyc +*.egg-info +*.db +*.db.old +*.swp +*.db-journal + +.coverage +.DS_Store +.installed.cfg +_gh_pages/* + +.idea/* +.svn/* +src/website/static/* +src/website/media/* + +bin +cfcache +develop-eggs +dist +downloads +eggs +parts +tmp +.sass-cache +node_modules + +src/website/settingslocal.py +stunnel.log + +.ruby-version + +# don't need these in the npm package. +src/ +_config.yml +bower.json +component.json +composer.json +CONTRIBUTING.md +Gemfile +Gemfile.lock diff --git a/lib/font-awesome/HELP-US-OUT.txt b/themes/next-5.1.4/source/lib/font-awesome/HELP-US-OUT.txt similarity index 100% rename from lib/font-awesome/HELP-US-OUT.txt rename to themes/next-5.1.4/source/lib/font-awesome/HELP-US-OUT.txt diff --git a/themes/next-5.1.4/source/lib/font-awesome/bower.json b/themes/next-5.1.4/source/lib/font-awesome/bower.json new file mode 100644 index 0000000..9e21126 --- /dev/null +++ b/themes/next-5.1.4/source/lib/font-awesome/bower.json @@ -0,0 +1,22 @@ +{ + "name": "font-awesome", + "description": "Font Awesome", + "keywords": [], + "homepage": "http://fontawesome.io", + "dependencies": {}, + "devDependencies": {}, + "license": ["OFL-1.1", "MIT", "CC-BY-3.0"], + "main": [ + "less/font-awesome.less", + "scss/font-awesome.scss" + ], + "ignore": [ + "*/.*", + "*.json", + "src", + "*.yml", + "Gemfile", + "Gemfile.lock", + "*.md" + ] +} diff --git a/lib/font-awesome/css/font-awesome.css b/themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.css similarity index 100% rename from lib/font-awesome/css/font-awesome.css rename to themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.css diff --git a/lib/font-awesome/css/font-awesome.css.map b/themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.css.map similarity index 100% rename from lib/font-awesome/css/font-awesome.css.map rename to themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.css.map diff --git a/lib/font-awesome/css/font-awesome.min.css b/themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.min.css similarity index 100% rename from lib/font-awesome/css/font-awesome.min.css rename to themes/next-5.1.4/source/lib/font-awesome/css/font-awesome.min.css diff --git a/lib/font-awesome/fonts/FontAwesome.otf b/themes/next-5.1.4/source/lib/font-awesome/fonts/FontAwesome.otf similarity index 100% rename from lib/font-awesome/fonts/FontAwesome.otf rename to themes/next-5.1.4/source/lib/font-awesome/fonts/FontAwesome.otf diff --git a/lib/font-awesome/fonts/fontawesome-webfont.eot b/themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.eot similarity index 100% rename from lib/font-awesome/fonts/fontawesome-webfont.eot rename to themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.eot diff --git a/lib/font-awesome/fonts/fontawesome-webfont.svg b/themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.svg similarity index 100% rename from lib/font-awesome/fonts/fontawesome-webfont.svg rename to themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.svg diff --git a/lib/font-awesome/fonts/fontawesome-webfont.ttf b/themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.ttf similarity index 100% rename from lib/font-awesome/fonts/fontawesome-webfont.ttf rename to themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.ttf diff --git a/lib/font-awesome/fonts/fontawesome-webfont.woff b/themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.woff similarity index 100% rename from lib/font-awesome/fonts/fontawesome-webfont.woff rename to themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.woff diff --git a/lib/font-awesome/fonts/fontawesome-webfont.woff2 b/themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.woff2 similarity index 100% rename from lib/font-awesome/fonts/fontawesome-webfont.woff2 rename to themes/next-5.1.4/source/lib/font-awesome/fonts/fontawesome-webfont.woff2 diff --git a/themes/next-5.1.4/source/lib/jquery/.bower.json b/themes/next-5.1.4/source/lib/jquery/.bower.json new file mode 100644 index 0000000..30b67e0 --- /dev/null +++ b/themes/next-5.1.4/source/lib/jquery/.bower.json @@ -0,0 +1,15 @@ +{ + "name": "jquery", + "_cacheHeaders": { + "ETag": "\"5492efef-14960\"", + "Last-Modified": "Thu, 18 Dec 2014 15:17:03 GMT", + "Content-Length": "84320", + "Content-Type": "application/x-javascript" + }, + "_release": "e-tag:5492efef-", + "main": "index.js", + "_source": "http://code.jquery.com/jquery-2.1.3.min.js", + "_target": "*", + "_originalSource": "http://code.jquery.com/jquery-2.1.3.min.js", + "_direct": true +} \ No newline at end of file diff --git a/lib/jquery/index.js b/themes/next-5.1.4/source/lib/jquery/index.js similarity index 100% rename from lib/jquery/index.js rename to themes/next-5.1.4/source/lib/jquery/index.js diff --git a/themes/next-5.1.4/source/lib/jquery_lazyload/.bower.json b/themes/next-5.1.4/source/lib/jquery_lazyload/.bower.json new file mode 100644 index 0000000..9999f39 --- /dev/null +++ b/themes/next-5.1.4/source/lib/jquery_lazyload/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "jquery_lazyload", + "version": "1.9.7", + "homepage": "http://www.appelsiini.net/projects/lazyload", + "authors": [ + "Mika Tuupola " + ], + "description": "jQuery plugin for lazy loading images", + "main": [ + "jquery.lazyload.js", + "jquery.scrollstop.js" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "**/*.min.js", + "**/*.html", + "**/*.textile", + "Gruntfile.js", + "lazyload.jquery.json", + "package.json", + "node_modules", + "bower_components", + "test", + "img" + ], + "_release": "1.9.7", + "_resolution": { + "type": "version", + "tag": "1.9.7", + "commit": "218e50eb4999fe59ac94b939a65c8c988d1d420b" + }, + "_source": "git://github.com/tuupola/jquery_lazyload.git", + "_target": "~1.9.7", + "_originalSource": "jquery.lazyload", + "_direct": true +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/lib/jquery_lazyload/CONTRIBUTING.md b/themes/next-5.1.4/source/lib/jquery_lazyload/CONTRIBUTING.md new file mode 100644 index 0000000..4a5fb22 --- /dev/null +++ b/themes/next-5.1.4/source/lib/jquery_lazyload/CONTRIBUTING.md @@ -0,0 +1,39 @@ +# Contributing to Lazy Load + +## Only one feature or change per pull request + +Make pull requests only one feature or change at the time. For example you have fixed a bug. You also have optimized some code. Optimization is not related to a bug. These should be submitted as separate pull requests. This way I can easily choose what to include. It is also easier to understand the code changes. Commit messages should be descriptive and full sentences. + +Do not commit minified versions. Do not touch the version number. Make the pull requests against [1.9.x branch](https://github.com/tuupola/jquery_lazyload/commits/1.9.x). + +## Write meaningful commit messages + +Proper commit message is full sentence. It starts with capital letter but does not end with period. Headlines do not end with period. The GitHub default `Update filename.js` is not enough. When needed include also longer explanation what the commit does. + +``` +Capitalized, short (50 chars or less) summary + +More detailed explanatory text, if necessary. Wrap it to about 72 +characters or so. In some contexts, the first line is treated as the +subject of an email and the rest of the text as the body. The blank +line separating the summary from the body is critical (unless you omit +the body entirely); tools like rebase can get confused if you run the +two together. +``` + +When in doubt see Tim Pope's blogpost [A Note About Git Commit Messages](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html) + +## Follow the existing coding standards + +When contributing to open source project it is polite to follow the original authors coding standars. They might be different than yours. It is not a holy war. Just follow then original. + +```javascript +var snake_case = "something"; + +function camelCase(options) { +} + +if (true !== false) { + console.log("here be dragons"); +} +``` diff --git a/themes/next-5.1.4/source/lib/jquery_lazyload/README.md b/themes/next-5.1.4/source/lib/jquery_lazyload/README.md new file mode 100644 index 0000000..a9626ee --- /dev/null +++ b/themes/next-5.1.4/source/lib/jquery_lazyload/README.md @@ -0,0 +1,48 @@ +# Lazy Load Plugin for jQuery + +Lazy Load delays loading of images in long web pages. Images outside of viewport wont be loaded before user scrolls to them. This is opposite of image preloading. + +Using Lazy Load on long web pages containing many large images makes the page load faster. Browser will be in ready state after loading visible images. In some cases it can also help to reduce server load. + +Lazy Load is inspired by [YUI ImageLoader](http://developer.yahoo.com/yui/imageloader/) Utility by Matt Mlinac. + +## How to Use? + +Lazy Load depends on jQuery. Include them both in end of your HTML code: + +```html + + +``` + +You must alter your HTML code. URL of the real image must be put into data-original attribute. It is good idea to give Lazy Loaded image a specific class. This way you can easily control which images plugin is binded to. Note that you should have width and height attributes in your image tag. + +```html + +``` + +then in your code do: + +```js +$("img.lazy").lazyload(); +``` + +This causes all images of class lazy to be lazy loaded. + +More information on [Lazy Load](http://www.appelsiini.net/projects/lazyload) project page. + +## Install + +You can install with [bower](http://bower.io/) or [npm](https://www.npmjs.com/). + + +```sh +$ bower install jquery.lazyload +$ npm install jquery-lazyload +``` + + +# License + +All code licensed under the [MIT License](http://www.opensource.org/licenses/mit-license.php). All images licensed under [Creative Commons Attribution 3.0 Unported License](http://creativecommons.org/licenses/by/3.0/deed.en_US). In other words you are basically free to do whatever you want. Just don't remove my name from the source. + diff --git a/themes/next-5.1.4/source/lib/jquery_lazyload/bower.json b/themes/next-5.1.4/source/lib/jquery_lazyload/bower.json new file mode 100644 index 0000000..929d3c4 --- /dev/null +++ b/themes/next-5.1.4/source/lib/jquery_lazyload/bower.json @@ -0,0 +1,27 @@ +{ + "name": "jquery_lazyload", + "version": "1.9.4", + "homepage": "http://www.appelsiini.net/projects/lazyload", + "authors": [ + "Mika Tuupola " + ], + "description": "jQuery plugin for lazy loading images", + "main": [ + "jquery.lazyload.js", + "jquery.scrollstop.js" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "**/*.min.js", + "**/*.html", + "**/*.textile", + "Gruntfile.js", + "lazyload.jquery.json", + "package.json", + "node_modules", + "bower_components", + "test", + "img" + ] +} diff --git a/lib/jquery_lazyload/jquery.lazyload.js b/themes/next-5.1.4/source/lib/jquery_lazyload/jquery.lazyload.js similarity index 100% rename from lib/jquery_lazyload/jquery.lazyload.js rename to themes/next-5.1.4/source/lib/jquery_lazyload/jquery.lazyload.js diff --git a/lib/jquery_lazyload/jquery.scrollstop.js b/themes/next-5.1.4/source/lib/jquery_lazyload/jquery.scrollstop.js similarity index 100% rename from lib/jquery_lazyload/jquery.scrollstop.js rename to themes/next-5.1.4/source/lib/jquery_lazyload/jquery.scrollstop.js diff --git a/lib/needsharebutton/font-embedded.css b/themes/next-5.1.4/source/lib/needsharebutton/font-embedded.css similarity index 100% rename from lib/needsharebutton/font-embedded.css rename to themes/next-5.1.4/source/lib/needsharebutton/font-embedded.css diff --git a/lib/needsharebutton/needsharebutton.css b/themes/next-5.1.4/source/lib/needsharebutton/needsharebutton.css similarity index 100% rename from lib/needsharebutton/needsharebutton.css rename to themes/next-5.1.4/source/lib/needsharebutton/needsharebutton.css diff --git a/lib/needsharebutton/needsharebutton.js b/themes/next-5.1.4/source/lib/needsharebutton/needsharebutton.js similarity index 100% rename from lib/needsharebutton/needsharebutton.js rename to themes/next-5.1.4/source/lib/needsharebutton/needsharebutton.js diff --git a/lib/pace/pace-theme-barber-shop.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-barber-shop.min.css similarity index 100% rename from lib/pace/pace-theme-barber-shop.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-barber-shop.min.css diff --git a/lib/pace/pace-theme-big-counter.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-big-counter.min.css similarity index 100% rename from lib/pace/pace-theme-big-counter.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-big-counter.min.css diff --git a/lib/pace/pace-theme-bounce.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-bounce.min.css similarity index 100% rename from lib/pace/pace-theme-bounce.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-bounce.min.css diff --git a/lib/pace/pace-theme-center-atom.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-center-atom.min.css similarity index 100% rename from lib/pace/pace-theme-center-atom.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-center-atom.min.css diff --git a/lib/pace/pace-theme-center-circle.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-center-circle.min.css similarity index 100% rename from lib/pace/pace-theme-center-circle.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-center-circle.min.css diff --git a/lib/pace/pace-theme-center-radar.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-center-radar.min.css similarity index 100% rename from lib/pace/pace-theme-center-radar.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-center-radar.min.css diff --git a/lib/pace/pace-theme-center-simple.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-center-simple.min.css similarity index 100% rename from lib/pace/pace-theme-center-simple.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-center-simple.min.css diff --git a/lib/pace/pace-theme-corner-indicator.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-corner-indicator.min.css similarity index 100% rename from lib/pace/pace-theme-corner-indicator.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-corner-indicator.min.css diff --git a/lib/pace/pace-theme-fill-left.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-fill-left.min.css similarity index 100% rename from lib/pace/pace-theme-fill-left.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-fill-left.min.css diff --git a/lib/pace/pace-theme-flash.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-flash.min.css similarity index 100% rename from lib/pace/pace-theme-flash.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-flash.min.css diff --git a/lib/pace/pace-theme-loading-bar.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-loading-bar.min.css similarity index 100% rename from lib/pace/pace-theme-loading-bar.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-loading-bar.min.css diff --git a/lib/pace/pace-theme-mac-osx.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-mac-osx.min.css similarity index 100% rename from lib/pace/pace-theme-mac-osx.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-mac-osx.min.css diff --git a/lib/pace/pace-theme-minimal.min.css b/themes/next-5.1.4/source/lib/pace/pace-theme-minimal.min.css similarity index 100% rename from lib/pace/pace-theme-minimal.min.css rename to themes/next-5.1.4/source/lib/pace/pace-theme-minimal.min.css diff --git a/lib/pace/pace.min.js b/themes/next-5.1.4/source/lib/pace/pace.min.js similarity index 100% rename from lib/pace/pace.min.js rename to themes/next-5.1.4/source/lib/pace/pace.min.js diff --git a/lib/three/canvas_lines.min.js b/themes/next-5.1.4/source/lib/three/canvas_lines.min.js similarity index 100% rename from lib/three/canvas_lines.min.js rename to themes/next-5.1.4/source/lib/three/canvas_lines.min.js diff --git a/lib/three/canvas_sphere.min.js b/themes/next-5.1.4/source/lib/three/canvas_sphere.min.js similarity index 100% rename from lib/three/canvas_sphere.min.js rename to themes/next-5.1.4/source/lib/three/canvas_sphere.min.js diff --git a/lib/three/three-waves.min.js b/themes/next-5.1.4/source/lib/three/three-waves.min.js similarity index 100% rename from lib/three/three-waves.min.js rename to themes/next-5.1.4/source/lib/three/three-waves.min.js diff --git a/lib/three/three.min.js b/themes/next-5.1.4/source/lib/three/three.min.js similarity index 100% rename from lib/three/three.min.js rename to themes/next-5.1.4/source/lib/three/three.min.js diff --git a/lib/ua-parser-js/dist/ua-parser.min.js b/themes/next-5.1.4/source/lib/ua-parser-js/dist/ua-parser.min.js similarity index 100% rename from lib/ua-parser-js/dist/ua-parser.min.js rename to themes/next-5.1.4/source/lib/ua-parser-js/dist/ua-parser.min.js diff --git a/lib/ua-parser-js/dist/ua-parser.pack.js b/themes/next-5.1.4/source/lib/ua-parser-js/dist/ua-parser.pack.js similarity index 100% rename from lib/ua-parser-js/dist/ua-parser.pack.js rename to themes/next-5.1.4/source/lib/ua-parser-js/dist/ua-parser.pack.js diff --git a/themes/next-5.1.4/source/lib/velocity/.bower.json b/themes/next-5.1.4/source/lib/velocity/.bower.json new file mode 100644 index 0000000..8fb3b04 --- /dev/null +++ b/themes/next-5.1.4/source/lib/velocity/.bower.json @@ -0,0 +1,50 @@ +{ + "name": "velocity", + "version": "1.2.2", + "homepage": "http://velocityjs.org", + "authors": [ + { + "name": "Julian Shapiro", + "homepage": "http://julian.com/" + } + ], + "description": "Accelerated JavaScript animation.", + "main": [ + "./velocity.js", + "./velocity.ui.js" + ], + "keywords": [ + "animation", + "jquery", + "animate", + "lightweight", + "smooth", + "ui", + "velocity.js", + "velocityjs", + "javascript" + ], + "license": "MIT", + "ignore": [ + "*.json", + "!/bower.json", + "LICENSE", + "*.md" + ], + "dependencies": { + "jquery": "*" + }, + "repository": { + "type": "git", + "url": "http://github.com/julianshapiro/velocity.git" + }, + "_release": "1.2.2", + "_resolution": { + "type": "version", + "tag": "1.2.2", + "commit": "6b227928631aab5694255df3c219736c4c02449d" + }, + "_source": "git://github.com/julianshapiro/velocity.git", + "_target": "~1.2.1", + "_originalSource": "velocity" +} \ No newline at end of file diff --git a/themes/next-5.1.4/source/lib/velocity/bower.json b/themes/next-5.1.4/source/lib/velocity/bower.json new file mode 100644 index 0000000..768ee61 --- /dev/null +++ b/themes/next-5.1.4/source/lib/velocity/bower.json @@ -0,0 +1,38 @@ +{ + "name": "velocity", + "version": "1.2.2", + "homepage": "http://velocityjs.org", + "authors": [ + { "name" : "Julian Shapiro", + "homepage" : "http://julian.com/" + } + ], + "description": "Accelerated JavaScript animation.", + "main": [ "./velocity.js", "./velocity.ui.js"], + "keywords": [ + "animation", + "jquery", + "animate", + "lightweight", + "smooth", + "ui", + "velocity.js", + "velocityjs", + "javascript" + ], + "license": "MIT", + "ignore": [ + "*.json", + "!/bower.json", + "LICENSE", + "*.md" + ], + "dependencies": { + "jquery": "*" + }, + "repository" : + { + "type" : "git", + "url" : "http://github.com/julianshapiro/velocity.git" + } +} \ No newline at end of file diff --git a/lib/velocity/velocity.js b/themes/next-5.1.4/source/lib/velocity/velocity.js similarity index 100% rename from lib/velocity/velocity.js rename to themes/next-5.1.4/source/lib/velocity/velocity.js diff --git a/lib/velocity/velocity.min.js b/themes/next-5.1.4/source/lib/velocity/velocity.min.js similarity index 100% rename from lib/velocity/velocity.min.js rename to themes/next-5.1.4/source/lib/velocity/velocity.min.js diff --git a/lib/velocity/velocity.ui.js b/themes/next-5.1.4/source/lib/velocity/velocity.ui.js similarity index 100% rename from lib/velocity/velocity.ui.js rename to themes/next-5.1.4/source/lib/velocity/velocity.ui.js diff --git a/lib/velocity/velocity.ui.min.js b/themes/next-5.1.4/source/lib/velocity/velocity.ui.min.js similarity index 100% rename from lib/velocity/velocity.ui.min.js rename to themes/next-5.1.4/source/lib/velocity/velocity.ui.min.js diff --git a/themes/next-5.1.4/test/.jshintrc b/themes/next-5.1.4/test/.jshintrc new file mode 100644 index 0000000..038a8b0 --- /dev/null +++ b/themes/next-5.1.4/test/.jshintrc @@ -0,0 +1,23 @@ +{ + "curly": true, + "eqnull": true, + "eqeqeq": true, + "undef": true, + "newcap": true, + "unused": true, + "laxcomma": false, + "asi": false, + "expr": true, + "loopfunc": false, + "strict": false, + + "globals": { + "define": true, + "require": true, + "it": true, + "module": true, + "describe": true, + "window": true, + "$": true + } +} diff --git a/themes/next-5.1.4/test/helpers.js b/themes/next-5.1.4/test/helpers.js new file mode 100644 index 0000000..83f51d0 --- /dev/null +++ b/themes/next-5.1.4/test/helpers.js @@ -0,0 +1,133 @@ +define([ + 'intern!object', + 'intern/chai!assert', + 'intern/order!source/js/helpers.js' +], function (registerSuite, assert) { + registerSuite({ + name: 'helpers', + + beforeEach: function () { + window = { + navigator: { + userAgent: '' + } + }; + screen = { + width: 0 + }; + + minic = { + desktop: function (screenWidth) { + window.navigator.userAgent = 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.130 Safari/537.36'; + screen.width = screenWidth || 992; + }, + tablet: function (screenWidth) { + window.navigator.userAgent = 'Mozilla/5.0 (iPad; CPU OS 4_3_5 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8L1 Safari/6533.18.5'; + screen.width = screenWidth || 750; + }, + mobile: function (screenWidth) { + window.navigator.userAgent = 'Mozilla/5.0 (iPhone; CPU iPhone OS 8_0 like Mac OS X) AppleWebKit/600.1.3 (KHTML, like Gecko) Version/8.0 Mobile/12A4345d Safari/600.1.4'; + screen.width = screenWidth || 767; + } + }; + }, + + '#hasMobileUA': { + 'should be true': function () { + minic.mobile(); + assert.isTrue( hasMobileUA() ); + minic.tablet(); + assert.isTrue( hasMobileUA() ); + }, + + 'should be false': function () { + minic.desktop(); + assert.isFalse( hasMobileUA() ); + } + }, + + + '#isDesktop': { + 'should be true': function () { + minic.desktop(992); + assert.isTrue( isDesktop() ); + + minic.desktop(1200); + assert.isTrue( isDesktop() ); + }, + 'should be false': function () { + minic.mobile(); + assert.isFalse( isDesktop() ); + + minic.tablet(992); + assert.isFalse( isDesktop() ); + } + }, + + '#isTablet': { + 'should be true': function () { + minic.tablet(900); + assert.isTrue( isTablet() ); + + minic.tablet(780); + assert.isTrue( isTablet() ); + }, + 'should be false': function () { + minic.desktop(500); + assert.isFalse( isTablet() ); + + minic.tablet(1000); + assert.isFalse( isTablet() ); + + minic.tablet(500); + assert.isFalse( isTablet() ); + } + }, + + '#isMobile': { + 'should be true': function () { + minic.mobile(); + assert.isTrue( isMobile() ); + + minic.mobile(700); + assert.isTrue( isMobile() ); + }, + 'should be false': function () { + minic.desktop(); + assert.isFalse( isMobile() ); + + minic.tablet(); + assert.isFalse( isMobile() ); + + minic.mobile(1000); + assert.isFalse( isMobile() ); + } + }, + + '#escapeSelector': function () { + var selectors = ['(something', '.something', '$something']; + selectors.forEach(function (s) { + assert.equal( escapeSelector(s), '\\' + s ); + }); + }, + + '#displaySidebar': function () {}, + + '#isMist': { + beforeEach: function () { + CONFIG = { + scheme: '' + }; + }, + 'should be true': function () { + CONFIG.scheme = 'Mist'; + assert.isTrue( isMist() ); + }, + 'should be false': function () { + CONFIG.scheme = 'Minimal'; + assert.isFalse( isMist() ); + } + } + + }); +}); diff --git a/themes/next-5.1.4/test/intern.js b/themes/next-5.1.4/test/intern.js new file mode 100644 index 0000000..db115c7 --- /dev/null +++ b/themes/next-5.1.4/test/intern.js @@ -0,0 +1,65 @@ +// Learn more about configuring this file at . +// These default settings work OK for most people. The options that *must* be changed below are the +// packages, suites, excludeInstrumentation, and (if you want functional tests) functionalSuites. +define({ + // The port on which the instrumenting proxy will listen + proxyPort: 9000, + + // A fully qualified URL to the Intern proxy + proxyUrl: 'http://localhost:9000/', + + // Default desired capabilities for all environments. Individual capabilities can be overridden by any of the + // specified browser environments in the `environments` array below as well. See + // https://code.google.com/p/selenium/wiki/DesiredCapabilities for standard Selenium capabilities and + // https://saucelabs.com/docs/additional-config#desired-capabilities for Sauce Labs capabilities. + // Note that the `build` capability will be filled in with the current commit ID from the Travis CI environment + // automatically + capabilities: { + 'selenium-version': '2.41.0' + }, + + // Browsers to run integration testing against. Note that version numbers must be strings if used with Sauce + // OnDemand. Options that will be permutated are browserName, version, platform, and platformVersion; any other + // capabilities options specified for an environment will be copied as-is + environments: [ + { browserName: 'internet explorer', version: '11', platform: 'Windows 8.1' }, + { browserName: 'internet explorer', version: '10', platform: 'Windows 8' }, + { browserName: 'internet explorer', version: '9', platform: 'Windows 7' }, + { browserName: 'firefox', version: '28', platform: [ 'OS X 10.9', 'Windows 7', 'Linux' ] }, + { browserName: 'chrome', version: '34', platform: [ 'OS X 10.9', 'Windows 7', 'Linux' ] }, + { browserName: 'safari', version: '6', platform: 'OS X 10.8' }, + { browserName: 'safari', version: '7', platform: 'OS X 10.9' } + ], + + // Maximum number of simultaneous integration tests that should be executed on the remote WebDriver service + maxConcurrency: 3, + + // Name of the tunnel class to use for WebDriver tests + tunnel: 'SauceLabsTunnel', + + // The desired AMD loader to use when running unit tests (client.html/client.js). Omit to use the default Dojo + // loader + useLoader: { + 'host-node': 'dojo/dojo', + 'host-browser': 'node_modules/dojo/dojo.js' + }, + + // Configuration options for the module loader; any AMD configuration options supported by the specified AMD loader + // can be used here + loader: { + // Packages that should be registered with the loader in each testing environment + packages: [ { name: 'next', location: '.' } ] + }, + + // Non-functional test suite(s) to run in each browser + suites: [ + /* 'myPackage/tests/foo', 'myPackage/tests/bar' */ + 'tests/helpers' + ], + + // Functional test suite(s) to run in each browser once non-functional tests are completed + functionalSuites: [ /* 'myPackage/tests/functional' */ ], + + // A regular expression matching URLs to files that should not be included in code coverage analysis + excludeInstrumentation: /^(?:tests|node_modules)\// +});