├── 404.php ├── LICENSE ├── README.md ├── archive.php ├── comments.php ├── css ├── bootstrap.min.css ├── bootstrap.min.css.map ├── font-awesome.min.css ├── hint.min.css ├── jquery.fancybox.min.css └── waxy-main.css ├── fonts ├── FontAwesome.otf ├── fontawesome-webfont.eot ├── fontawesome-webfont.svg ├── fontawesome-webfont.ttf ├── fontawesome-webfont.woff ├── fontawesome-webfont.woff2 ├── glyphicons-halflings-regular.eot ├── glyphicons-halflings-regular.svg ├── glyphicons-halflings-regular.ttf ├── glyphicons-halflings-regular.woff └── glyphicons-halflings-regular.woff2 ├── footer.php ├── functions.php ├── header.php ├── img └── loading.gif ├── index.php ├── js ├── bootstrap.min.js ├── jquery.fancybox.min.js ├── jquery.lazyload.min.js ├── jquery.min.js ├── typed.js └── waxy-main.js ├── lib ├── prism │ ├── clipboard.min.js │ ├── css │ │ ├── Coy.css │ │ ├── Dark.css │ │ ├── Default.css │ │ ├── Funky.css │ │ ├── Okaidia.css │ │ ├── SolarizedLight.css │ │ ├── TomorrowNight.css │ │ └── Twilight.css │ └── prism.js └── shortcode.php ├── page.php ├── page_ friends.php ├── page_ friends_mini.php ├── page_articles.php ├── page_sitemap.php ├── page_timeline.php ├── post.php ├── screenshot.png ├── shortcode.php ├── sidebar.php └── waxy_logo.png /404.php: -------------------------------------------------------------------------------- 1 | 2 | need('header.php'); ?> 3 | 4 | 5 | 26 |
27 |
28 |
29 |

30 |

31 |

32 |
33 |
34 |
35 |
36 | 37 | 38 | need('footer.php'); ?> 39 | 40 | 41 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 dingzd 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Waxy 简约自适应博客主题 2 | 3 | ![Waxy 简约自适应博客主题](https://s2.loli.net/2023/07/11/t5yuAK2CUsvXNgL.png) 4 | 5 | **[在线预览(稳定)](https://www.idzd.top/) | [在线预览(测试)](https://test.706x.com/) | [更新计划](https://github.com/dingzd1995/typecho-theme-waxy/projects/2) | [问题反馈](https://github.com/dingzd1995/typecho-theme-waxy/issues)** 6 | 7 | Waxy,白蜡。白为色之祖,简而百搭;蜡,轻而易雕琢; 8 | 9 | Waxy(白蜡),代表着本主题的特点------轻量高效,悦于书写! 10 | 11 | 小巧,却拥有完善且丰富的功能。 12 | 13 | 即可开箱即用,也可以加以雕琢。简约的设计,无限的可能! 14 | 15 | 呐,朋友。 16 | 17 | **尺牍已展,静候佳作!** 18 | 19 | ------ 20 | 21 | ![Waxy 简约自适应博客主题](https://i.loli.net/2020/12/02/k6FsGWKjNlVAq1w.png) 22 | 23 | > 本主题参考**seventeen主题**,由其修改更新而来,感谢原作者的辛苦付出! 24 | 25 | ## 安装主题 26 | 27 | **主题下载地址:[GitHub](https://github.com/dingzd1995/typecho-theme-waxy/releases/tag/v2020.11.23) & [CDN](https://pic.idzd.top/typecho-theme-waxy/v2020.11.23.zip)** 28 | 29 | MD5: C514E80FE10F5F9DAE286A98E58EB61A 30 | 31 | SHA1: D7B316AAACE090D4CD8B4AB7837DC0D7366C5421 32 | 33 | 把主题上传到 Typecho 安装路径下的 `usr/themes/` 目录,然后解压,你也可以先解压在上传。 34 | 35 | 解压完成后,请将主题目录重命名为`Waxy`,并保证所有主题文件在此目录下。 36 | 37 | 登录 Typecho 的管理后台,进入 `控制台` -> `外观`,点击 **Waxy** 主题下方的`启用`按钮即可启用。 38 | 39 | 如需修改主题设置,请点击`设置外观`进入主题设置。 40 | 41 | ## 主题功能介绍 42 | 43 | - 轻量高效,悦于书写 44 | 45 | - 响应式布局 46 | 47 | - 图片懒加载/灯箱 48 | 49 | - 自定义侧边栏/JS/CSS样式 50 | 51 | - 文章置顶/标星/首图/内容失效提醒/阅读剩余部分 52 | 53 | - 短代码快捷功能(多彩提示框/多彩文字提示/简易提示框/收缩框/快捷插入音频&视频) 54 | 55 | - 置顶公告/CDN切换/代码高亮/时间线/归档页面/Sitemap/技术统计 56 | 57 | 58 | 59 | ### 短代码 60 | 61 | 短代码可以快速为你提供更多展示效果。使文章层次更丰富。 62 | 63 | #### 效果 64 | 65 | ![短代码效果](https://i.loli.net/2020/11/23/P4W8DkArqdfIQ9j.png) 66 | 67 | #### 使用方法 68 | 69 | ```bash 70 | #多彩提示框 71 | [info]一般提示[/info] 72 | [warning]警告提示[/warning] 73 | [danger]危险提示[/danger] 74 | [info]多行内容测试:
75 | 生活如酒,或芳香,或浓烈,因为诚实,它变得醇厚;生活如歌,或高昂,或低沉,因为守信,它变得悦耳; 生活如画,或明丽,或素雅,因为诚信,它变得美丽。[/info] 76 | 77 | 78 | #文字提示 79 | [em]警告文字样式[/em] 80 | [hi]高亮文字样式[/hi] 81 | [lo]备注文字样式[/lo] 82 | 83 | 84 | #插入视频(支持视频静音,自动播放,循环播放) 85 | [video src="视频地址" poster="视频封面地址(可省略)" muted="muted" autoplay="autoplay" loop="loop" ] 86 | 87 | #插入音频(支持自动播放,循环播放) 88 | [audio src="音频地址" autoplay="autoplay" loop="loop" ] 89 | 90 | #PS:某些浏览器限制,可能无法自动播放,不过一般静音视频不受影响~ 91 | 92 | 93 | #简易提示框(添加close="close",可以激活关闭按钮) 94 | [alert style="success" close="close"]简易提示框:success,默认样式[/alert] 95 | [alert style="info" close="close"]简易提示框:info[/alert] 96 | [alert style="warning" close="close"]简易提示框:warning[/alert] 97 | [alert style="danger" close="close"]简易提示框:danger[/alert] 98 | 99 | 100 | #收缩框(添加checked="checked",自动展开收缩框;style,控制外观样式) 101 | [shrinks title="收缩框:默认样式,自动展开" checked="checked"]内容[/shrinks] 102 | [shrinks title="收缩框:primary" style="primary"]内容[/shrinks] 103 | [shrinks title="收缩框:success" style="success"]内容[/shrinks] 104 | [shrinks title="收缩框:info" style="info"]内容[/shrinks] 105 | [shrinks title="收缩框:warning" style="warning"]内容[/shrinks] 106 | [shrinks title="收缩框:danger" style="danger"]内容[/shrinks] 107 | 108 | ``` 109 | 110 | ### 代码高亮 111 | 112 | 基于[prism.js](https://prismjs.com/download.html#themes=prism-okaidia&languages=markup+css+clike+javascript+apacheconf+c+csharp+bash+cpp+aspnet+coffeescript+markup-templating+git+less+java+php+javadoclike+markdown+json+nginx+sql+python+javadoc+smarty&plugins=line-numbers+toolbar+normalize-whitespace+show-language+copy-to-clipboard+match-braces)实现,自带8种主题。 113 | 114 | ![代码高亮设置](https://i.loli.net/2020/11/23/s5BIN9yjZQmzfOh.png) 115 | 116 | > 移植于[CodeHighlighter-for-Typecho插件](https://github.com/Copterfly/CodeHighlighter-for-Typecho),感谢原作者的辛苦劳动! 117 | 118 | ### 自定义侧边栏 119 | 120 | ![自定义侧边栏](https://i.loli.net/2020/11/23/ZFLUDgxQfsuiJjB.png) 121 | 122 | ### 自定义CSS/JS 123 | 124 | ![自定义CSS/JS](https://i.loli.net/2020/11/23/9OEhWAjxcJegRIQ.png) 125 | 126 | PS:通过与置顶公告联动,还可以实现一言效果~ 127 | 128 | ![hitokoto](https://i.loli.net/2020/11/23/Phk9Z5gFyM3R8f6.gif) 129 | 130 | 131 | ### 友情链接管理 132 | 133 | 一行一条,格式(请用半角空格或逗号分隔):网站名称,网站地址,网站图标(建议:32x32),网站说明 134 | 135 | ![友情链接管理](https://i.loli.net/2020/11/23/ytqnMQ4ml7uBkba.png) 136 | 137 | ### 文章首图 138 | 139 | 如果想使用首图,请在文章自定义字段 img 添加网址即可 140 | 141 | ### 文章标星 142 | 143 | 如果想在文章右上角显示一个显眼的标记,请添加文章自定义字段 star 即可 144 | 145 | ![star](https://i.loli.net/2020/11/23/z8BZR16vrXDN3iu.png) 146 | 147 | ### 文章内容失效提醒 148 | 149 | ![remind](https://i.loli.net/2020/11/23/IX1qEl72vnJ8CHa.png) 150 | 151 | ### 置顶公告&文章 152 | 153 | ![top](https://i.loli.net/2020/11/23/rbJEPSOakVTnuzG.png) 154 | 155 | **2020/10/05**可以同时置顶多篇文章,滚动展示。 156 | 157 | *多篇文章置顶效果:* 158 | 159 | ![top](https://i.loli.net/2020/11/23/P6BYJ3GH4NbhkKI.gif) 160 | 161 | 162 | ### 阅读剩余部分 163 | 164 | 在需要截断文章的位置插入``即可 165 | 166 | ![more](https://i.loli.net/2020/11/23/9CSjDnkx3tgaYFw.png) 167 | 168 | ### 时间线 169 | 170 | ```bash 171 | #时间线使用方法 172 | 173 | #新建独立页面,选择模板为 时间线 即可。并在其中按如下格式填写即可 174 | 175 | - **<红色的标题内容>** <气泡的内容,支持图片,超链接,短代码> 176 | - **<红色的标题内容>** <气泡的内容,支持图片,超链接,短代码> 177 | - **<红色的标题内容>** <气泡的内容,支持图片,超链接,短代码> 178 | - **<红色的标题内容>** <气泡的内容,支持图片,超链接,短代码> 179 | 180 | ``` 181 | 182 | 其中 `- ` 是markdown语法中的无序列表,`** **`是markdown语法中的文字加粗。`< >`是您自定义的内容,使用时请去掉尖括号。 183 | 184 | ![page_articles](https://i.loli.net/2020/11/23/6VkMKiN4mpqXZOo.png) 185 | 186 | 187 | 188 | ### 归档页面 189 | 190 | ```bash 191 | #归档页面,由系统自动生成。 192 | 193 | 您只需要新建独立页面,选择模板为 归档页面 即可。 194 | 195 | ``` 196 | 197 | ![page_timeline](https://i.loli.net/2020/11/23/ybvg9jYUVaIf1rp.png) 198 | 199 | 200 | ### 友情链接页面 201 | ```bash 202 | #使用方法 203 | 204 | #新建独立页面,选择模板为 友情链接 即可。并在其中按如下格式填写即可,空行间隔可分片 205 | 206 | - [![<网站地址>](<网站图片> )](<网站URL>) 207 | 208 | 209 | ``` 210 | 211 | ![page_friends.png](https://i.loli.net/2020/11/28/mDJtUMEIu9KlwcW.png) 212 | 213 | ### Sitemap/网站地图 214 | 215 | **百度/谷歌站长工具正常收录** 216 | 217 | ![百度/谷歌站长工具正常收录](https://i.loli.net/2020/11/23/FCA3nSqbUK2OMdY.png) 218 | 219 | ![Bing站长工具正常收录](https://i.loli.net/2020/11/23/vEyMC2q9wp7R4FG.png) 220 | 221 | 222 | 标准模式和纯文本模式(添加参数`?txt=1`) 223 | 224 | ![标准模式和纯文本模式(添加参数`?txt=1`)](https://i.loli.net/2020/11/23/7LMl9a5ftSykvBw.png) 225 | 226 | 启用Sitemap/网站地图 227 | 228 | ![启用Sitemap/网站地图](https://i.loli.net/2020/11/23/9pwEkinXOMb4Cur.png) 229 | -------------------------------------------------------------------------------- /archive.php: -------------------------------------------------------------------------------- 1 | 2 | need('header.php'); ?> 3 | 4 | 5 |
6 |
7 |
8 |
9 | 10 |
11 | 21 |
22 | 23 | next()): ?> 24 | 25 | options->articles_list==1):?> 26 |
27 | 28 | ___fields()))): ?> 31 | 32 |
33 |

title() ?>

34 | 41 |
42 |
43 | 44 | ___fields()))): ?> 45 | 48 | 49 | 50 |
51 | content,$this->permalink); ?> 52 |
53 | 54 | 55 |
56 | 57 |
58 | 59 | tags(' , ', true, 'none'); ?> 60 |
61 | 62 |
63 | 前往评论 64 |
65 |
66 |
67 | 68 | 69 | options->articles_list==0):?> 70 | 71 |
72 | 73 | ___fields()))): ?> 74 | 75 | 76 |
77 | ___fields()))): ?> 78 |
79 | <?php $this->title() ?> 80 |
81 | 82 | content)): ?> 83 |
84 | <?php $this->title() ?> 85 |
86 | 87 | 88 |
89 | 90 |
91 | title() ?> 92 |
93 |
94 | 95 |
date('Y-m-d'); ?>
96 |
category(','); ?>
97 | 98 |
99 |
100 | ___fields()))){ $this->fields->info();} else { echo getExcerpt($this->text,75,'');} ?> 101 | - 阅读更多 - 102 |
103 |
104 |
105 |
106 | 107 | 108 | 109 | 110 | 111 | 117 | 118 |
119 | 120 | need('sidebar.php'); ?> 121 | 122 |
123 |
124 |
125 | 126 | need('footer.php'); ?> 127 | -------------------------------------------------------------------------------- /comments.php: -------------------------------------------------------------------------------- 1 | 2 |
3 | comments()->to($comments); ?> 4 | have()): ?> 5 |

commentsNum(_t('暂无评论'), _t('仅有一条评论'), _t('已有 %d 条评论')); ?>

6 | 7 | listComments(); ?> 8 | 9 | pageNav('« 前一页', '后一页 »'); ?> 10 | 11 | 12 | 13 | allow('comment')): ?> 14 |
15 |
16 | cancelReply(); ?> 17 |
18 | 19 |

20 |
21 | user->hasLogin()): ?> 22 |

user->screenName(); ?>. »

23 | 24 |

25 | 26 |

27 |

28 | options->commentsRequireMail): ?> required /> 29 |

30 |

31 | options->commentsRequireURL): ?> required /> 32 |

33 | 34 |

35 | 36 |

37 |

38 |

39 | 40 |

41 |
42 |
43 | 44 |

45 | 46 |
47 | -------------------------------------------------------------------------------- /css/hint.min.css: -------------------------------------------------------------------------------- 1 | /*! Hint.css - v2.6.0 - 2019-04-27 2 | * http://kushagragour.in/lab/hint/ 3 | * Copyright (c) 2019 Kushagra Gour */ 4 | 5 | [class*=hint--]{position:relative;display:inline-block}[class*=hint--]:after,[class*=hint--]:before{position:absolute;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);transform:translate3d(0,0,0);visibility:hidden;opacity:0;z-index:1000000;pointer-events:none;-webkit-transition:.3s ease;-moz-transition:.3s ease;transition:.3s ease;-webkit-transition-delay:0s;-moz-transition-delay:0s;transition-delay:0s}[class*=hint--]:hover:after,[class*=hint--]:hover:before{visibility:visible;opacity:1;-webkit-transition-delay:.1s;-moz-transition-delay:.1s;transition-delay:.1s}[class*=hint--]:before{content:'';position:absolute;background:0 0;border:6px solid transparent;z-index:1000001}[class*=hint--]:after{background:#383838;color:#fff;padding:8px 10px;font-size:12px;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;line-height:12px;white-space:nowrap;text-shadow:0 -1px 0 #000;box-shadow:4px 4px 8px rgba(0,0,0,.3)}[class*=hint--][aria-label]:after{content:attr(aria-label)}[class*=hint--][data-hint]:after{content:attr(data-hint)}[aria-label='']:after,[aria-label='']:before,[data-hint='']:after,[data-hint='']:before{display:none!important}.hint--top-left:before,.hint--top-right:before,.hint--top:before{border-top-color:#383838}.hint--bottom-left:before,.hint--bottom-right:before,.hint--bottom:before{border-bottom-color:#383838}.hint--top:after,.hint--top:before{bottom:100%;left:50%}.hint--top:before{margin-bottom:-11px;left:calc(50% - 6px)}.hint--top:after{-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);transform:translateX(-50%)}.hint--top:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--top:hover:after{-webkit-transform:translateX(-50%) translateY(-8px);-moz-transform:translateX(-50%) translateY(-8px);transform:translateX(-50%) translateY(-8px)}.hint--bottom:after,.hint--bottom:before{top:100%;left:50%}.hint--bottom:before{margin-top:-11px;left:calc(50% - 6px)}.hint--bottom:after{-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);transform:translateX(-50%)}.hint--bottom:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--bottom:hover:after{-webkit-transform:translateX(-50%) translateY(8px);-moz-transform:translateX(-50%) translateY(8px);transform:translateX(-50%) translateY(8px)}.hint--right:before{border-right-color:#383838;margin-left:-11px;margin-bottom:-6px}.hint--right:after{margin-bottom:-14px}.hint--right:after,.hint--right:before{left:100%;bottom:50%}.hint--right:hover:after,.hint--right:hover:before{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.hint--left:before{border-left-color:#383838;margin-right:-11px;margin-bottom:-6px}.hint--left:after{margin-bottom:-14px}.hint--left:after,.hint--left:before{right:100%;bottom:50%}.hint--left:hover:after,.hint--left:hover:before{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--top-left:after,.hint--top-left:before{bottom:100%;left:50%}.hint--top-left:before{margin-bottom:-11px;left:calc(50% - 6px)}.hint--top-left:after{-webkit-transform:translateX(-100%);-moz-transform:translateX(-100%);transform:translateX(-100%);margin-left:12px}.hint--top-left:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--top-left:hover:after{-webkit-transform:translateX(-100%) translateY(-8px);-moz-transform:translateX(-100%) translateY(-8px);transform:translateX(-100%) translateY(-8px)}.hint--top-right:after,.hint--top-right:before{bottom:100%;left:50%}.hint--top-right:before{margin-bottom:-11px;left:calc(50% - 6px)}.hint--top-right:after{-webkit-transform:translateX(0);-moz-transform:translateX(0);transform:translateX(0);margin-left:-12px}.hint--top-right:hover:after,.hint--top-right:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--bottom-left:after,.hint--bottom-left:before{top:100%;left:50%}.hint--bottom-left:before{margin-top:-11px;left:calc(50% - 6px)}.hint--bottom-left:after{-webkit-transform:translateX(-100%);-moz-transform:translateX(-100%);transform:translateX(-100%);margin-left:12px}.hint--bottom-left:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--bottom-left:hover:after{-webkit-transform:translateX(-100%) translateY(8px);-moz-transform:translateX(-100%) translateY(8px);transform:translateX(-100%) translateY(8px)}.hint--bottom-right:after,.hint--bottom-right:before{top:100%;left:50%}.hint--bottom-right:before{margin-top:-11px;left:calc(50% - 6px)}.hint--bottom-right:after{-webkit-transform:translateX(0);-moz-transform:translateX(0);transform:translateX(0);margin-left:-12px}.hint--bottom-right:hover:after,.hint--bottom-right:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--large:after,.hint--medium:after,.hint--small:after{white-space:normal;line-height:1.4em;word-wrap:break-word}.hint--small:after{width:80px}.hint--medium:after{width:150px}.hint--large:after{width:300px}.hint--error:after{background-color:#b34e4d;text-shadow:0 -1px 0 #592726}.hint--error.hint--top-left:before,.hint--error.hint--top-right:before,.hint--error.hint--top:before{border-top-color:#b34e4d}.hint--error.hint--bottom-left:before,.hint--error.hint--bottom-right:before,.hint--error.hint--bottom:before{border-bottom-color:#b34e4d}.hint--error.hint--left:before{border-left-color:#b34e4d}.hint--error.hint--right:before{border-right-color:#b34e4d}.hint--warning:after{background-color:#c09854;text-shadow:0 -1px 0 #6c5328}.hint--warning.hint--top-left:before,.hint--warning.hint--top-right:before,.hint--warning.hint--top:before{border-top-color:#c09854}.hint--warning.hint--bottom-left:before,.hint--warning.hint--bottom-right:before,.hint--warning.hint--bottom:before{border-bottom-color:#c09854}.hint--warning.hint--left:before{border-left-color:#c09854}.hint--warning.hint--right:before{border-right-color:#c09854}.hint--info:after{background-color:#3986ac;text-shadow:0 -1px 0 #1a3c4d}.hint--info.hint--top-left:before,.hint--info.hint--top-right:before,.hint--info.hint--top:before{border-top-color:#3986ac}.hint--info.hint--bottom-left:before,.hint--info.hint--bottom-right:before,.hint--info.hint--bottom:before{border-bottom-color:#3986ac}.hint--info.hint--left:before{border-left-color:#3986ac}.hint--info.hint--right:before{border-right-color:#3986ac}.hint--success:after{background-color:#458746;text-shadow:0 -1px 0 #1a321a}.hint--success.hint--top-left:before,.hint--success.hint--top-right:before,.hint--success.hint--top:before{border-top-color:#458746}.hint--success.hint--bottom-left:before,.hint--success.hint--bottom-right:before,.hint--success.hint--bottom:before{border-bottom-color:#458746}.hint--success.hint--left:before{border-left-color:#458746}.hint--success.hint--right:before{border-right-color:#458746}.hint--always:after,.hint--always:before{opacity:1;visibility:visible}.hint--always.hint--top:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--top:after{-webkit-transform:translateX(-50%) translateY(-8px);-moz-transform:translateX(-50%) translateY(-8px);transform:translateX(-50%) translateY(-8px)}.hint--always.hint--top-left:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--top-left:after{-webkit-transform:translateX(-100%) translateY(-8px);-moz-transform:translateX(-100%) translateY(-8px);transform:translateX(-100%) translateY(-8px)}.hint--always.hint--top-right:after,.hint--always.hint--top-right:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--bottom:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--bottom:after{-webkit-transform:translateX(-50%) translateY(8px);-moz-transform:translateX(-50%) translateY(8px);transform:translateX(-50%) translateY(8px)}.hint--always.hint--bottom-left:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--bottom-left:after{-webkit-transform:translateX(-100%) translateY(8px);-moz-transform:translateX(-100%) translateY(8px);transform:translateX(-100%) translateY(8px)}.hint--always.hint--bottom-right:after,.hint--always.hint--bottom-right:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--left:after,.hint--always.hint--left:before{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--always.hint--right:after,.hint--always.hint--right:before{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.hint--rounded:after{border-radius:4px}.hint--no-animate:after,.hint--no-animate:before{-webkit-transition-duration:0s;-moz-transition-duration:0s;transition-duration:0s}.hint--bounce:after,.hint--bounce:before{-webkit-transition:opacity .3s ease,visibility .3s ease,-webkit-transform .3s cubic-bezier(.71,1.7,.77,1.24);-moz-transition:opacity .3s ease,visibility .3s ease,-moz-transform .3s cubic-bezier(.71,1.7,.77,1.24);transition:opacity .3s ease,visibility .3s ease,transform .3s cubic-bezier(.71,1.7,.77,1.24)}.hint--no-shadow:after,.hint--no-shadow:before{text-shadow:initial;box-shadow:initial} -------------------------------------------------------------------------------- /css/jquery.fancybox.min.css: -------------------------------------------------------------------------------- 1 | body.compensate-for-scrollbar{overflow:hidden}.fancybox-active{height:auto}.fancybox-is-hidden{left:-9999px;margin:0;position:absolute!important;top:-9999px;visibility:hidden}.fancybox-container{-webkit-backface-visibility:hidden;height:100%;left:0;outline:none;position:fixed;-webkit-tap-highlight-color:transparent;top:0;-ms-touch-action:manipulation;touch-action:manipulation;transform:translateZ(0);width:100%;z-index:99992}.fancybox-container *{box-sizing:border-box}.fancybox-bg,.fancybox-inner,.fancybox-outer,.fancybox-stage{bottom:0;left:0;position:absolute;right:0;top:0}.fancybox-outer{-webkit-overflow-scrolling:touch;overflow-y:auto}.fancybox-bg{background:#1e1e1e;opacity:0;transition-duration:inherit;transition-property:opacity;transition-timing-function:cubic-bezier(.47,0,.74,.71)}.fancybox-is-open .fancybox-bg{opacity:.9;transition-timing-function:cubic-bezier(.22,.61,.36,1)}.fancybox-caption,.fancybox-infobar,.fancybox-navigation .fancybox-button,.fancybox-toolbar{direction:ltr;opacity:0;position:absolute;transition:opacity .25s ease,visibility 0s ease .25s;visibility:hidden;z-index:99997}.fancybox-show-caption .fancybox-caption,.fancybox-show-infobar .fancybox-infobar,.fancybox-show-nav .fancybox-navigation .fancybox-button,.fancybox-show-toolbar .fancybox-toolbar{opacity:1;transition:opacity .25s ease 0s,visibility 0s ease 0s;visibility:visible}.fancybox-infobar{color:#ccc;font-size:13px;-webkit-font-smoothing:subpixel-antialiased;height:44px;left:0;line-height:44px;min-width:44px;mix-blend-mode:difference;padding:0 10px;pointer-events:none;top:0;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.fancybox-toolbar{right:0;top:0}.fancybox-stage{direction:ltr;overflow:visible;transform:translateZ(0);z-index:99994}.fancybox-is-open .fancybox-stage{overflow:hidden}.fancybox-slide{-webkit-backface-visibility:hidden;display:none;height:100%;left:0;outline:none;overflow:auto;-webkit-overflow-scrolling:touch;padding:44px;position:absolute;text-align:center;top:0;transition-property:transform,opacity;white-space:normal;width:100%;z-index:99994}.fancybox-slide:before{content:"";display:inline-block;font-size:0;height:100%;vertical-align:middle;width:0}.fancybox-is-sliding .fancybox-slide,.fancybox-slide--current,.fancybox-slide--next,.fancybox-slide--previous{display:block}.fancybox-slide--image{overflow:hidden;padding:44px 0}.fancybox-slide--image:before{display:none}.fancybox-slide--html{padding:6px}.fancybox-content{background:#fff;display:inline-block;margin:0;max-width:100%;overflow:auto;-webkit-overflow-scrolling:touch;padding:44px;position:relative;text-align:left;vertical-align:middle}.fancybox-slide--image .fancybox-content{animation-timing-function:cubic-bezier(.5,0,.14,1);-webkit-backface-visibility:hidden;background:transparent;background-repeat:no-repeat;background-size:100% 100%;left:0;max-width:none;overflow:visible;padding:0;position:absolute;top:0;transform-origin:top left;transition-property:transform,opacity;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:99995}.fancybox-can-zoomOut .fancybox-content{cursor:zoom-out}.fancybox-can-zoomIn .fancybox-content{cursor:zoom-in}.fancybox-can-pan .fancybox-content,.fancybox-can-swipe .fancybox-content{cursor:grab}.fancybox-is-grabbing .fancybox-content{cursor:grabbing}.fancybox-container [data-selectable=true]{cursor:text}.fancybox-image,.fancybox-spaceball{background:transparent;border:0;height:100%;left:0;margin:0;max-height:none;max-width:none;padding:0;position:absolute;top:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:100%}.fancybox-spaceball{z-index:1}.fancybox-slide--iframe .fancybox-content,.fancybox-slide--map .fancybox-content,.fancybox-slide--pdf .fancybox-content,.fancybox-slide--video .fancybox-content{height:100%;overflow:visible;padding:0;width:100%}.fancybox-slide--video .fancybox-content{background:#000}.fancybox-slide--map .fancybox-content{background:#e5e3df}.fancybox-slide--iframe .fancybox-content{background:#fff}.fancybox-iframe,.fancybox-video{background:transparent;border:0;display:block;height:100%;margin:0;overflow:hidden;padding:0;width:100%}.fancybox-iframe{left:0;position:absolute;top:0}.fancybox-error{background:#fff;cursor:default;max-width:400px;padding:40px;width:100%}.fancybox-error p{color:#444;font-size:16px;line-height:20px;margin:0;padding:0}.fancybox-button{background:rgba(30,30,30,.6);border:0;border-radius:0;box-shadow:none;cursor:pointer;display:inline-block;height:44px;margin:0;padding:10px;position:relative;transition:color .2s;vertical-align:top;visibility:inherit;width:44px}.fancybox-button,.fancybox-button:link,.fancybox-button:visited{color:#ccc}.fancybox-button:hover{color:#fff}.fancybox-button:focus{outline:none}.fancybox-button.fancybox-focus{outline:1px dotted}.fancybox-button[disabled],.fancybox-button[disabled]:hover{color:#888;cursor:default;outline:none}.fancybox-button div{height:100%}.fancybox-button svg{display:block;height:100%;overflow:visible;position:relative;width:100%}.fancybox-button svg path{fill:currentColor;stroke-width:0}.fancybox-button--fsenter svg:nth-child(2),.fancybox-button--fsexit svg:first-child,.fancybox-button--pause svg:first-child,.fancybox-button--play svg:nth-child(2){display:none}.fancybox-progress{background:#ff5268;height:2px;left:0;position:absolute;right:0;top:0;transform:scaleX(0);transform-origin:0;transition-property:transform;transition-timing-function:linear;z-index:99998}.fancybox-close-small{background:transparent;border:0;border-radius:0;color:#ccc;cursor:pointer;opacity:.8;padding:8px;position:absolute;right:-12px;top:-44px;z-index:401}.fancybox-close-small:hover{color:#fff;opacity:1}.fancybox-slide--html .fancybox-close-small{color:currentColor;padding:10px;right:0;top:0}.fancybox-slide--image.fancybox-is-scaling .fancybox-content{overflow:hidden}.fancybox-is-scaling .fancybox-close-small,.fancybox-is-zoomable.fancybox-can-pan .fancybox-close-small{display:none}.fancybox-navigation .fancybox-button{background-clip:content-box;height:100px;opacity:0;position:absolute;top:calc(50% - 50px);width:70px}.fancybox-navigation .fancybox-button div{padding:7px}.fancybox-navigation .fancybox-button--arrow_left{left:0;left:env(safe-area-inset-left);padding:31px 26px 31px 6px}.fancybox-navigation .fancybox-button--arrow_right{padding:31px 6px 31px 26px;right:0;right:env(safe-area-inset-right)}.fancybox-caption{background:linear-gradient(0deg,rgba(0,0,0,.85) 0,rgba(0,0,0,.3) 50%,rgba(0,0,0,.15) 65%,rgba(0,0,0,.075) 75.5%,rgba(0,0,0,.037) 82.85%,rgba(0,0,0,.019) 88%,transparent);bottom:0;color:#eee;font-size:14px;font-weight:400;left:0;line-height:1.5;padding:75px 44px 25px;pointer-events:none;right:0;text-align:center;z-index:99996}@supports (padding:max(0px)){.fancybox-caption{padding:75px max(44px,env(safe-area-inset-right)) max(25px,env(safe-area-inset-bottom)) max(44px,env(safe-area-inset-left))}}.fancybox-caption--separate{margin-top:-50px}.fancybox-caption__body{max-height:50vh;overflow:auto;pointer-events:all}.fancybox-caption a,.fancybox-caption a:link,.fancybox-caption a:visited{color:#ccc;text-decoration:none}.fancybox-caption a:hover{color:#fff;text-decoration:underline}.fancybox-loading{animation:a 1s linear infinite;background:transparent;border:4px solid #888;border-bottom-color:#fff;border-radius:50%;height:50px;left:50%;margin:-25px 0 0 -25px;opacity:.7;padding:0;position:absolute;top:50%;width:50px;z-index:99999}@keyframes a{to{transform:rotate(1turn)}}.fancybox-animated{transition-timing-function:cubic-bezier(0,0,.25,1)}.fancybox-fx-slide.fancybox-slide--previous{opacity:0;transform:translate3d(-100%,0,0)}.fancybox-fx-slide.fancybox-slide--next{opacity:0;transform:translate3d(100%,0,0)}.fancybox-fx-slide.fancybox-slide--current{opacity:1;transform:translateZ(0)}.fancybox-fx-fade.fancybox-slide--next,.fancybox-fx-fade.fancybox-slide--previous{opacity:0;transition-timing-function:cubic-bezier(.19,1,.22,1)}.fancybox-fx-fade.fancybox-slide--current{opacity:1}.fancybox-fx-zoom-in-out.fancybox-slide--previous{opacity:0;transform:scale3d(1.5,1.5,1.5)}.fancybox-fx-zoom-in-out.fancybox-slide--next{opacity:0;transform:scale3d(.5,.5,.5)}.fancybox-fx-zoom-in-out.fancybox-slide--current{opacity:1;transform:scaleX(1)}.fancybox-fx-rotate.fancybox-slide--previous{opacity:0;transform:rotate(-1turn)}.fancybox-fx-rotate.fancybox-slide--next{opacity:0;transform:rotate(1turn)}.fancybox-fx-rotate.fancybox-slide--current{opacity:1;transform:rotate(0deg)}.fancybox-fx-circular.fancybox-slide--previous{opacity:0;transform:scale3d(0,0,0) translate3d(-100%,0,0)}.fancybox-fx-circular.fancybox-slide--next{opacity:0;transform:scale3d(0,0,0) translate3d(100%,0,0)}.fancybox-fx-circular.fancybox-slide--current{opacity:1;transform:scaleX(1) translateZ(0)}.fancybox-fx-tube.fancybox-slide--previous{transform:translate3d(-100%,0,0) scale(.1) skew(-10deg)}.fancybox-fx-tube.fancybox-slide--next{transform:translate3d(100%,0,0) scale(.1) skew(10deg)}.fancybox-fx-tube.fancybox-slide--current{transform:translateZ(0) scale(1)}@media (max-height:576px){.fancybox-slide{padding-left:6px;padding-right:6px}.fancybox-slide--image{padding:6px 0}.fancybox-close-small{right:-6px}.fancybox-slide--image .fancybox-close-small{background:#4e4e4e;color:#f2f4f6;height:36px;opacity:1;padding:6px;right:0;top:0;width:36px}.fancybox-caption{padding-left:12px;padding-right:12px}@supports (padding:max(0px)){.fancybox-caption{padding-left:max(12px,env(safe-area-inset-left));padding-right:max(12px,env(safe-area-inset-right))}}}.fancybox-share{background:#f4f4f4;border-radius:3px;max-width:90%;padding:30px;text-align:center}.fancybox-share h1{color:#222;font-size:35px;font-weight:700;margin:0 0 20px}.fancybox-share p{margin:0;padding:0}.fancybox-share__button{border:0;border-radius:3px;display:inline-block;font-size:14px;font-weight:700;line-height:40px;margin:0 5px 10px;min-width:130px;padding:0 15px;text-decoration:none;transition:all .2s;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;white-space:nowrap}.fancybox-share__button:link,.fancybox-share__button:visited{color:#fff}.fancybox-share__button:hover{text-decoration:none}.fancybox-share__button--fb{background:#3b5998}.fancybox-share__button--fb:hover{background:#344e86}.fancybox-share__button--pt{background:#bd081d}.fancybox-share__button--pt:hover{background:#aa0719}.fancybox-share__button--tw{background:#1da1f2}.fancybox-share__button--tw:hover{background:#0d95e8}.fancybox-share__button svg{height:25px;margin-right:7px;position:relative;top:-1px;vertical-align:middle;width:25px}.fancybox-share__button svg path{fill:#fff}.fancybox-share__input{background:transparent;border:0;border-bottom:1px solid #d7d7d7;border-radius:0;color:#5d5b5b;font-size:14px;margin:10px 0 0;outline:none;padding:10px 15px;width:100%}.fancybox-thumbs{background:#ddd;bottom:0;display:none;margin:0;-webkit-overflow-scrolling:touch;-ms-overflow-style:-ms-autohiding-scrollbar;padding:2px 2px 4px;position:absolute;right:0;-webkit-tap-highlight-color:rgba(0,0,0,0);top:0;width:212px;z-index:99995}.fancybox-thumbs-x{overflow-x:auto;overflow-y:hidden}.fancybox-show-thumbs .fancybox-thumbs{display:block}.fancybox-show-thumbs .fancybox-inner{right:212px}.fancybox-thumbs__list{font-size:0;height:100%;list-style:none;margin:0;overflow-x:hidden;overflow-y:auto;padding:0;position:absolute;position:relative;white-space:nowrap;width:100%}.fancybox-thumbs-x .fancybox-thumbs__list{overflow:hidden}.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar{width:7px}.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar-track{background:#fff;border-radius:10px;box-shadow:inset 0 0 6px rgba(0,0,0,.3)}.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar-thumb{background:#2a2a2a;border-radius:10px}.fancybox-thumbs__list a{-webkit-backface-visibility:hidden;backface-visibility:hidden;background-color:rgba(0,0,0,.1);background-position:50%;background-repeat:no-repeat;background-size:cover;cursor:pointer;float:left;height:75px;margin:2px;max-height:calc(100% - 8px);max-width:calc(50% - 4px);outline:none;overflow:hidden;padding:0;position:relative;-webkit-tap-highlight-color:transparent;width:100px}.fancybox-thumbs__list a:before{border:6px solid #ff5268;bottom:0;content:"";left:0;opacity:0;position:absolute;right:0;top:0;transition:all .2s cubic-bezier(.25,.46,.45,.94);z-index:99991}.fancybox-thumbs__list a:focus:before{opacity:.5}.fancybox-thumbs__list a.fancybox-thumbs-active:before{opacity:1}@media (max-width:576px){.fancybox-thumbs{width:110px}.fancybox-show-thumbs .fancybox-inner{right:110px}.fancybox-thumbs__list a{max-width:calc(100% - 10px)}} -------------------------------------------------------------------------------- /fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /footer.php: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 14 | 15 | 16 | options->CDN,"staticfile")==0): ?> 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | options->CDN,"75cdn")==0): ?> 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | options->CDN,"bootcss")==0): ?> 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | options->CDN,"jsdelivr")==0): ?> 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | options->CDN,"local")==0): ?> 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | options->codeHighlightControl): ?> 64 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | options->sticky)&&count(explode(',', strtr($this->options->sticky, ' ', ',')))>1): ?> 80 | 93 | 94 | 95 | 96 | 97 | options->load_html): ?> 98 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | footer(); ?> 109 | 110 | 111 | -------------------------------------------------------------------------------- /header.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | <?php $this->archiveTitle(array( 10 | 'category' => _t('分类 %s 下的文章'), 11 | 'search' => _t('包含关键字 %s 的文章'), 12 | 'tag' => _t('标签 %s 下的文章'), 13 | 'author' => _t('%s 发布的文章') 14 | ), '', ' - '); ?><?php $this->options->title(); ?> 15 | 16 | 17 | options->load_html): ?> 18 | 66 |
67 |
68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 |
76 |
77 | 78 | 79 | 80 | 81 | options->CDN,"staticfile")==0): ?> 82 | 83 | 84 | 85 | 86 | 87 | 88 | options->CDN,"75cdn")==0): ?> 89 | 90 | 91 | 92 | 93 | 94 | 95 | options->CDN,"bootcss")==0): ?> 96 | 97 | 98 | 99 | 100 | 101 | 102 | options->CDN,"jsdelivr")==0): ?> 103 | 104 | 105 | 106 | 107 | 108 | 109 | options->CDN,"local")==0): ?> 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | options->codeHighlightControl): ?> 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | header(); ?> 130 | 131 | 132 | 133 | 261 | 262 | 263 | -------------------------------------------------------------------------------- /img/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/img/loading.gif -------------------------------------------------------------------------------- /index.php: -------------------------------------------------------------------------------- 1 | 详细说明请移步:https://github.com/dingzd1995/typecho-theme-waxy 4 | * 5 | * @package Waxy 6 | * @author Dingzd 7 | * @version 2020.10.18 8 | * @link https://www.idzd.top/ 9 | */ 10 | 11 | if (!defined('__TYPECHO_ROOT_DIR__')) exit; 12 | $this->need('header.php'); 13 | ?> 14 | 15 | 16 |
17 |
18 |
19 |
20 | 21 | is('index')){on_top_text($this);on_up_post($this);} ?> 22 | 23 | 24 | next()): ?> 25 | 26 | options->articles_list==1):?> 27 |
28 | 29 | ___fields()))): ?> 32 | 33 |
34 |

title() ?>

35 | 42 |
43 |
44 | ___fields()))): ?> 45 | 48 | 49 | content)): ?> 50 | 53 | 54 | 55 |
56 | content,$this->permalink); ?> 57 |
58 | 59 | 60 |
61 | 62 |
63 | 64 | tags(' , ', true, 'none'); ?> 65 |
66 | 67 |
68 | 前往评论 69 |
70 |
71 |
72 | 73 | 74 | options->articles_list==0):?> 75 | 76 |
77 | 78 | ___fields()))): ?> 79 | 80 | 81 |
82 | ___fields()))): ?> 83 |
84 | <?php $this->title() ?> 85 |
86 | 87 | content)): ?> 88 |
89 | <?php $this->title() ?> 90 |
91 | 92 | 93 |
94 | 95 |
96 | title() ?> 97 |
98 |
99 | 100 |
date('Y-m-d'); ?>
101 |
category(','); ?>
102 | 103 |
104 |
105 | ___fields()))){ $this->fields->info();} else { echo getExcerpt($this->text,75,'');} ?> 106 | - 阅读更多 - 107 |
108 |
109 |
110 |
111 | 112 | 113 | 114 | 115 | 116 | 122 | 123 | 124 |
125 | 126 | 127 | need('sidebar.php'); ?> 128 | 129 |
130 |
131 |
132 | 133 | 134 | need('footer.php'); ?> 135 | -------------------------------------------------------------------------------- /js/jquery.lazyload.min.js: -------------------------------------------------------------------------------- 1 | /*! Lazy Load 1.9.1 - MIT license - Copyright 2010-2013 Mika Tuupola */ 2 | !function(a,b,c,d){var e=a(b);a.fn.lazyload=function(f){function g(){var b=0;i.each(function(){var c=a(this);if(!j.skip_invisible||c.is(":visible"))if(a.abovethetop(this,j)||a.leftofbegin(this,j));else if(a.belowthefold(this,j)||a.rightoffold(this,j)){if(++b>j.failure_limit)return!1}else c.trigger("appear"),b=0})}var h,i=this,j={threshold:0,failure_limit:0,event:"scroll",effect:"show",container:b,data_attribute:"original",skip_invisible:!0,appear:null,load:null,placeholder:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB/AAffA0nNPuCLAAAAAElFTkSuQmCC"};return f&&(d!==f.failurelimit&&(f.failure_limit=f.failurelimit,delete f.failurelimit),d!==f.effectspeed&&(f.effect_speed=f.effectspeed,delete f.effectspeed),a.extend(j,f)),h=j.container===d||j.container===b?e:a(j.container),0===j.event.indexOf("scroll")&&h.bind(j.event,function(){return g()}),this.each(function(){var b=this,c=a(b);b.loaded=!1,(c.attr("src")===d||c.attr("src")===!1)&&c.is("img")&&c.attr("src",j.placeholder),c.one("appear",function(){if(!this.loaded){if(j.appear){var d=i.length;j.appear.call(b,d,j)}a("").bind("load",function(){var d=c.attr("data-"+j.data_attribute);c.hide(),c.is("img")?c.attr("src",d):c.css("background-image","url('"+d+"')"),c[j.effect](j.effect_speed),b.loaded=!0;var e=a.grep(i,function(a){return!a.loaded});if(i=a(e),j.load){var f=i.length;j.load.call(b,f,j)}}).attr("src",c.attr("data-"+j.data_attribute))}}),0!==j.event.indexOf("scroll")&&c.bind(j.event,function(){b.loaded||c.trigger("appear")})}),e.bind("resize",function(){g()}),/(?:iphone|ipod|ipad).*os 5/gi.test(navigator.appVersion)&&e.bind("pageshow",function(b){b.originalEvent&&b.originalEvent.persisted&&i.each(function(){a(this).trigger("appear")})}),a(c).ready(function(){g()}),this},a.belowthefold=function(c,f){var g;return g=f.container===d||f.container===b?(b.innerHeight?b.innerHeight:e.height())+e.scrollTop():a(f.container).offset().top+a(f.container).height(),g<=a(c).offset().top-f.threshold},a.rightoffold=function(c,f){var g;return g=f.container===d||f.container===b?e.width()+e.scrollLeft():a(f.container).offset().left+a(f.container).width(),g<=a(c).offset().left-f.threshold},a.abovethetop=function(c,f){var g;return g=f.container===d||f.container===b?e.scrollTop():a(f.container).offset().top,g>=a(c).offset().top+f.threshold+a(c).height()},a.leftofbegin=function(c,f){var g;return g=f.container===d||f.container===b?e.scrollLeft():a(f.container).offset().left,g>=a(c).offset().left+f.threshold+a(c).width()},a.inviewport=function(b,c){return!(a.rightoffold(b,c)||a.leftofbegin(b,c)||a.belowthefold(b,c)||a.abovethetop(b,c))},a.extend(a.expr[":"],{"below-the-fold":function(b){return a.belowthefold(b,{threshold:0})},"above-the-top":function(b){return!a.belowthefold(b,{threshold:0})},"right-of-screen":function(b){return a.rightoffold(b,{threshold:0})},"left-of-screen":function(b){return!a.rightoffold(b,{threshold:0})},"in-viewport":function(b){return a.inviewport(b,{threshold:0})},"above-the-fold":function(b){return!a.belowthefold(b,{threshold:0})},"right-of-fold":function(b){return a.rightoffold(b,{threshold:0})},"left-of-fold":function(b){return!a.rightoffold(b,{threshold:0})}})}(jQuery,window,document); -------------------------------------------------------------------------------- /js/typed.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * 3 | * typed.js - A JavaScript Typing Animation Library 4 | * Author: Matt Boldt 5 | * Version: v2.0.9 6 | * Url: https://github.com/mattboldt/typed.js 7 | * License(s): MIT 8 | * 9 | */ 10 | (function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.Typed=e():t.Typed=e()})(this,function(){return function(t){function e(n){if(s[n])return s[n].exports;var i=s[n]={exports:{},id:n,loaded:!1};return t[n].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var s={};return e.m=t,e.c=s,e.p="",e(0)}([function(t,e,s){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(t,e){for(var s=0;st.length)););var u=t.substring(0,e),l=t.substring(u.length+1,e+i),c=t.substring(e+i+1);t=u+l+c,i--}s.timeout=setTimeout(function(){s.toggleBlinking(!1),e===t.length?s.doneTyping(t,e):s.keepTyping(t,e,i),s.temporaryPause&&(s.temporaryPause=!1,s.options.onTypingResumed(s.arrayPos,s))},n)},n))}},{key:"keepTyping",value:function(t,e,s){0===e&&(this.toggleBlinking(!1),this.options.preStringTyped(this.arrayPos,this)),e+=s;var n=t.substr(0,e);this.replaceText(n),this.typewrite(t,e)}},{key:"doneTyping",value:function(t,e){var s=this;this.options.onStringTyped(this.arrayPos,this),this.toggleBlinking(!0),this.arrayPos===this.strings.length-1&&(this.complete(),this.loop===!1||this.curLoop===this.loopCount)||(this.timeout=setTimeout(function(){s.backspace(t,e)},this.backDelay))}},{key:"backspace",value:function(t,e){var s=this;if(this.pause.status===!0)return void this.setPauseStatus(t,e,!0);if(this.fadeOut)return this.initFadeOut();this.toggleBlinking(!1);var n=this.humanizer(this.backSpeed);this.timeout=setTimeout(function(){e=o.htmlParser.backSpaceHtmlChars(t,e,s);var n=t.substr(0,e);if(s.replaceText(n),s.smartBackspace){var i=s.strings[s.arrayPos+1];i&&n===i.substr(0,e)?s.stopNum=e:s.stopNum=0}e>s.stopNum?(e--,s.backspace(t,e)):e<=s.stopNum&&(s.arrayPos++,s.arrayPos===s.strings.length?(s.arrayPos=0,s.options.onLastStringBackspaced(),s.shuffleStringsIfNeeded(),s.begin()):s.typewrite(s.strings[s.sequence[s.arrayPos]],e))},n)}},{key:"complete",value:function(){this.options.onComplete(this),this.loop?this.curLoop++:this.typingComplete=!0}},{key:"setPauseStatus",value:function(t,e,s){this.pause.typewrite=s,this.pause.curString=t,this.pause.curStrPos=e}},{key:"toggleBlinking",value:function(t){this.cursor&&(this.pause.status||this.cursorBlinking!==t&&(this.cursorBlinking=t,t?this.cursor.classList.add("typed-cursor--blink"):this.cursor.classList.remove("typed-cursor--blink")))}},{key:"humanizer",value:function(t){return Math.round(Math.random()*t/2)+t}},{key:"shuffleStringsIfNeeded",value:function(){this.shuffle&&(this.sequence=this.sequence.sort(function(){return Math.random()-.5}))}},{key:"initFadeOut",value:function(){var t=this;return this.el.className+=" "+this.fadeOutClass,this.cursor&&(this.cursor.className+=" "+this.fadeOutClass),setTimeout(function(){t.arrayPos++,t.replaceText(""),t.strings.length>t.arrayPos?t.typewrite(t.strings[t.sequence[t.arrayPos]],0):(t.typewrite(t.strings[0],0),t.arrayPos=0)},this.fadeOutDelay)}},{key:"replaceText",value:function(t){this.attr?this.el.setAttribute(this.attr,t):this.isInput?this.el.value=t:"html"===this.contentType?this.el.innerHTML=t:this.el.textContent=t}},{key:"bindFocusEvents",value:function(){var t=this;this.isInput&&(this.el.addEventListener("focus",function(e){t.stop()}),this.el.addEventListener("blur",function(e){t.el.value&&0!==t.el.value.length||t.start()}))}},{key:"insertCursor",value:function(){this.showCursor&&(this.cursor||(this.cursor=document.createElement("span"),this.cursor.className="typed-cursor",this.cursor.innerHTML=this.cursorChar,this.el.parentNode&&this.el.parentNode.insertBefore(this.cursor,this.el.nextSibling)))}}]),t}();e["default"]=a,t.exports=e["default"]},function(t,e,s){"use strict";function n(t){return t&&t.__esModule?t:{"default":t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e":";";t.substr(e+1).charAt(0)!==i&&(e++,!(e+1>t.length)););e++}return e}},{key:"backSpaceHtmlChars",value:function(t,e,s){if("html"!==s.contentType)return e;var n=t.substr(e).charAt(0);if(">"===n||";"===n){var i="";for(i=">"===n?"<":"&";t.substr(e-1).charAt(0)!==i&&(e--,!(e<0)););e--}return e}}]),t}();e["default"]=i;var r=new i;e.htmlParser=r}])}); 11 | -------------------------------------------------------------------------------- /js/waxy-main.js: -------------------------------------------------------------------------------- 1 | /*回到顶部按钮*/ 2 | $(document).ready((function(_this) { 3 | return function() { 4 | var bt; 5 | bt = $('#back-to-top'); 6 | if ($(document).width() > 480) { 7 | $(window).scroll(function() { 8 | var st; 9 | st = $(window).scrollTop(); 10 | if (st > 400) { 11 | return bt.css('display', 'block'); 12 | } else { 13 | return bt.css('display', 'none'); 14 | } 15 | }); 16 | return bt.click(function() { 17 | $('body,html').animate({ 18 | scrollTop: 0 19 | }, 20 | 800); 21 | return false; 22 | }); 23 | } 24 | }; 25 | })(this)); 26 | 27 | 28 | /*图片懒加载*/ 29 | $(document).ready(function(){ 30 | $("img").lazyload({ 31 | /*placeholder: "/loading.gif",*/ 32 | effect: "fadeIn" 33 | }); 34 | }); 35 | 36 | 37 | $(document).ready(function(){ 38 | menuDropdown('.menu ul'); 39 | }); 40 | 41 | /*下拉菜单 */ 42 | function menuDropdown(ulclass){ 43 | $(document).ready(function(){ 44 | $(ulclass+' li').hover(function(){ 45 | $(this).children("ul").show(); //mouseover 46 | },function(){ 47 | $(this).children("ul").hide(); //mouseout 48 | }); 49 | }); 50 | } 51 | 52 | /* 鼠标特效 */ 53 | /* 54 | var a_idx = 0; 55 | jQuery(document).ready(function($) { 56 | $("body").click(function(e) { 57 | var a = new Array("富强", "民主", "文明", "和谐", "自由", "平等", "公正", "法治", "爱国", "敬业", "诚信", "友善"); 58 | var $i = $("").text(a[a_idx]); 59 | a_idx = (a_idx + 1) % a.length; 60 | var x = e.pageX, 61 | y = e.pageY; 62 | $i.css({ 63 | "z-index": 999999999999999999999999999999999999999999999999999999999999999999999, 64 | "top": y - 20, 65 | "left": x, 66 | "position": "absolute", 67 | "font-weight": "bold", 68 | "color": "rgb("+~~(255*Math.random())+","+~~(255*Math.random())+","+~~(255*Math.random())+")" 69 | }); 70 | $("body").append($i); 71 | $i.animate({ 72 | "top": y - 180, 73 | "opacity": 0 74 | }, 75 | 1500, 76 | function() { 77 | $i.remove(); 78 | }); 79 | }); 80 | });*/ 81 | -------------------------------------------------------------------------------- /lib/prism/clipboard.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * clipboard.js v2.0.0 3 | * https://zenorocha.github.io/clipboard.js 4 | * 5 | * Licensed MIT © Zeno Rocha 6 | */ 7 | !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(this,function(){return function(t){function e(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,e),r.l=!0,r.exports}var n={};return e.m=t,e.c=n,e.i=function(t){return t},e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:o})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=3)}([function(t,e,n){var o,r,i;!function(a,c){r=[t,n(7)],o=c,void 0!==(i="function"==typeof o?o.apply(e,r):o)&&(t.exports=i)}(0,function(t,e){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var o=function(t){return t&&t.__esModule?t:{default:t}}(e),r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t=this,e="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[e?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,o.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,o.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var t=void 0;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":r(t))||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),t}();t.exports=a})},function(t,e,n){function o(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!c.string(e))throw new TypeError("Second argument must be a String");if(!c.fn(n))throw new TypeError("Third argument must be a Function");if(c.node(t))return r(t,e,n);if(c.nodeList(t))return i(t,e,n);if(c.string(t))return a(t,e,n);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function r(t,e,n){return t.addEventListener(e,n),{destroy:function(){t.removeEventListener(e,n)}}}function i(t,e,n){return Array.prototype.forEach.call(t,function(t){t.addEventListener(e,n)}),{destroy:function(){Array.prototype.forEach.call(t,function(t){t.removeEventListener(e,n)})}}}function a(t,e,n){return u(document.body,t,e,n)}var c=n(6),u=n(5);t.exports=o},function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){function o(){r.off(t,o),e.apply(n,arguments)}var r=this;return o._=e,this.on(t,o,n)},emit:function(t){var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,r=n.length;for(o;o0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===d(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,f.default)(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new l.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return u("action",t)}},{key:"defaultTarget",value:function(t){var e=u("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return u("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach(function(t){n=n&&!!document.queryCommandSupported(t)}),n}}]),e}(s.default);t.exports=p})},function(t,e){function n(t,e){for(;t&&t.nodeType!==o;){if("function"==typeof t.matches&&t.matches(e))return t;t=t.parentNode}}var o=9;if("undefined"!=typeof Element&&!Element.prototype.matches){var r=Element.prototype;r.matches=r.matchesSelector||r.mozMatchesSelector||r.msMatchesSelector||r.oMatchesSelector||r.webkitMatchesSelector}t.exports=n},function(t,e,n){function o(t,e,n,o,r){var a=i.apply(this,arguments);return t.addEventListener(n,a,r),{destroy:function(){t.removeEventListener(n,a,r)}}}function r(t,e,n,r,i){return"function"==typeof t.addEventListener?o.apply(null,arguments):"function"==typeof n?o.bind(null,document).apply(null,arguments):("string"==typeof t&&(t=document.querySelectorAll(t)),Array.prototype.map.call(t,function(t){return o(t,e,n,r,i)}))}function i(t,e,n,o){return function(n){n.delegateTarget=a(n.target,e),n.delegateTarget&&o.call(t,n)}}var a=n(4);t.exports=r},function(t,e){e.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},e.nodeList=function(t){var n=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===n||"[object HTMLCollection]"===n)&&"length"in t&&(0===t.length||e.node(t[0]))},e.string=function(t){return"string"==typeof t||t instanceof String},e.fn=function(t){return"[object Function]"===Object.prototype.toString.call(t)}},function(t,e){function n(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var o=window.getSelection(),r=document.createRange();r.selectNodeContents(t),o.removeAllRanges(),o.addRange(r),e=o.toString()}return e}t.exports=n}])}); -------------------------------------------------------------------------------- /lib/prism/css/Coy.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-coy&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js Coy theme for JavaScript, CoffeeScript, CSS and HTML 5 | * Based on https://github.com/tshedor/workshop-wp-theme (Example: http://workshop.kansan.com/category/sessions/basics or http://workshop.timshedor.com/category/sessions/basics); 6 | * @author Tim Shedor 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | color: black; 12 | background: none; 13 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 14 | font-size: 1em; 15 | text-align: left; 16 | white-space: pre; 17 | word-spacing: normal; 18 | word-break: normal; 19 | word-wrap: normal; 20 | line-height: 1.5; 21 | margin: 0px; 22 | 23 | -moz-tab-size: 4; 24 | -o-tab-size: 4; 25 | tab-size: 4; 26 | 27 | -webkit-hyphens: none; 28 | -moz-hyphens: none; 29 | -ms-hyphens: none; 30 | hyphens: none; 31 | } 32 | 33 | /* Code blocks */ 34 | pre[class*="language-"] { 35 | position: relative; 36 | margin: .5em 0; 37 | overflow: visible; 38 | padding: 0; 39 | } 40 | pre[class*="language-"]>code { 41 | position: relative; 42 | border-left: 10px solid #358ccb; 43 | box-shadow: -1px 0px 0px 0px #358ccb, 0px 0px 0px 1px #dfdfdf; 44 | background-color: #fdfdfd; 45 | background-image: linear-gradient(transparent 50%, rgba(69, 142, 209, 0.04) 50%); 46 | background-size: 3em 3em; 47 | background-origin: content-box; 48 | background-attachment: local; 49 | } 50 | 51 | code[class*="language"] { 52 | max-height: inherit; 53 | height: inherit; 54 | padding: 0 1em; 55 | display: block; 56 | overflow: auto; 57 | } 58 | 59 | /* Margin bottom to accommodate shadow */ 60 | :not(pre) > code[class*="language-"], 61 | pre[class*="language-"] { 62 | background-color: #fdfdfd; 63 | -webkit-box-sizing: border-box; 64 | -moz-box-sizing: border-box; 65 | box-sizing: border-box; 66 | margin-bottom: 1em; 67 | } 68 | 69 | /* Inline code */ 70 | :not(pre) > code[class*="language-"] { 71 | position: relative; 72 | padding: .2em; 73 | border-radius: 0.3em; 74 | color: #c92c2c; 75 | border: 1px solid rgba(0, 0, 0, 0.1); 76 | display: inline; 77 | white-space: normal; 78 | } 79 | 80 | pre[class*="language-"]:before, 81 | pre[class*="language-"]:after { 82 | content: ''; 83 | z-index: -2; 84 | display: block; 85 | position: absolute; 86 | bottom: 0.75em; 87 | left: 0.18em; 88 | width: 40%; 89 | height: 20%; 90 | max-height: 13em; 91 | box-shadow: 0px 13px 8px #979797; 92 | -webkit-transform: rotate(-2deg); 93 | -moz-transform: rotate(-2deg); 94 | -ms-transform: rotate(-2deg); 95 | -o-transform: rotate(-2deg); 96 | transform: rotate(-2deg); 97 | } 98 | 99 | :not(pre) > code[class*="language-"]:after, 100 | pre[class*="language-"]:after { 101 | right: 0.75em; 102 | left: auto; 103 | -webkit-transform: rotate(2deg); 104 | -moz-transform: rotate(2deg); 105 | -ms-transform: rotate(2deg); 106 | -o-transform: rotate(2deg); 107 | transform: rotate(2deg); 108 | } 109 | 110 | .token.comment, 111 | .token.block-comment, 112 | .token.prolog, 113 | .token.doctype, 114 | .token.cdata { 115 | color: #7D8B99; 116 | } 117 | 118 | .token.punctuation { 119 | color: #5F6364; 120 | } 121 | 122 | .token.property, 123 | .token.tag, 124 | .token.boolean, 125 | .token.number, 126 | .token.function-name, 127 | .token.constant, 128 | .token.symbol, 129 | .token.deleted { 130 | color: #c92c2c; 131 | } 132 | 133 | .token.selector, 134 | .token.attr-name, 135 | .token.string, 136 | .token.char, 137 | .token.function, 138 | .token.builtin, 139 | .token.inserted { 140 | color: #2f9c0a; 141 | } 142 | 143 | .token.operator, 144 | .token.entity, 145 | .token.url, 146 | .token.variable { 147 | color: #a67f59; 148 | background: rgba(255, 255, 255, 0.5); 149 | } 150 | 151 | .token.atrule, 152 | .token.attr-value, 153 | .token.keyword, 154 | .token.class-name { 155 | color: #1990b8; 156 | } 157 | 158 | .token.regex, 159 | .token.important { 160 | color: #e90; 161 | } 162 | 163 | .language-css .token.string, 164 | .style .token.string { 165 | color: #a67f59; 166 | background: rgba(255, 255, 255, 0.5); 167 | } 168 | 169 | .token.important { 170 | font-weight: normal; 171 | } 172 | 173 | .token.bold { 174 | font-weight: bold; 175 | } 176 | .token.italic { 177 | font-style: italic; 178 | } 179 | 180 | .token.entity { 181 | cursor: help; 182 | } 183 | 184 | .namespace { 185 | opacity: .7; 186 | } 187 | 188 | @media screen and (max-width: 767px) { 189 | pre[class*="language-"]:before, 190 | pre[class*="language-"]:after { 191 | bottom: 14px; 192 | box-shadow: none; 193 | } 194 | 195 | } 196 | 197 | /* Plugin styles */ 198 | .token.tab:not(:empty):before, 199 | .token.cr:before, 200 | .token.lf:before { 201 | color: #e0d7d1; 202 | } 203 | 204 | /* Plugin styles: Line Numbers */ 205 | pre[class*="language-"].line-numbers.line-numbers { 206 | padding-left: 0; 207 | } 208 | 209 | pre[class*="language-"].line-numbers.line-numbers code { 210 | padding-left: 3.8em; 211 | } 212 | 213 | pre[class*="language-"].line-numbers.line-numbers .line-numbers-rows { 214 | left: 0; 215 | } 216 | 217 | /* Plugin styles: Line Highlight */ 218 | pre[class*="language-"][data-line] { 219 | padding-top: 0; 220 | padding-bottom: 0; 221 | padding-left: 0; 222 | } 223 | pre[data-line] code { 224 | position: relative; 225 | padding-left: 4em; 226 | } 227 | pre .line-highlight { 228 | margin-top: 0; 229 | } 230 | 231 | pre[class*="language-"].line-numbers { 232 | position: relative; 233 | padding-left: 3.8em; 234 | counter-reset: linenumber; 235 | } 236 | 237 | pre[class*="language-"].line-numbers > code { 238 | position: relative; 239 | white-space: inherit; 240 | } 241 | 242 | .line-numbers .line-numbers-rows { 243 | position: absolute; 244 | pointer-events: none; 245 | top: 0; 246 | font-size: 100%; 247 | left: -3.8em; 248 | width: 3em; /* works for line-numbers below 1000 lines */ 249 | letter-spacing: -1px; 250 | border-right: 1px solid #999; 251 | 252 | -webkit-user-select: none; 253 | -moz-user-select: none; 254 | -ms-user-select: none; 255 | user-select: none; 256 | 257 | } 258 | 259 | .line-numbers-rows > span { 260 | pointer-events: none; 261 | display: block; 262 | counter-increment: linenumber; 263 | } 264 | 265 | .line-numbers-rows > span:before { 266 | content: counter(linenumber); 267 | color: #999; 268 | display: block; 269 | padding-right: 0.8em; 270 | text-align: right; 271 | } 272 | 273 | div.code-toolbar { 274 | position: relative; 275 | } 276 | 277 | div.code-toolbar > .toolbar { 278 | position: absolute; 279 | top: .3em; 280 | right: .2em; 281 | transition: opacity 0.3s ease-in-out; 282 | opacity: 0; 283 | } 284 | 285 | div.code-toolbar:hover > .toolbar { 286 | opacity: 1; 287 | } 288 | 289 | /* Separate line b/c rules are thrown out if selector is invalid. 290 | IE11 and old Edge versions don't support :focus-within. */ 291 | div.code-toolbar:focus-within > .toolbar { 292 | opacity: 1; 293 | } 294 | 295 | div.code-toolbar > .toolbar .toolbar-item { 296 | display: inline-block; 297 | } 298 | 299 | div.code-toolbar > .toolbar a { 300 | cursor: pointer; 301 | } 302 | 303 | div.code-toolbar > .toolbar button { 304 | background: none; 305 | border: 0; 306 | color: inherit; 307 | font: inherit; 308 | line-height: normal; 309 | overflow: visible; 310 | padding: 0; 311 | -webkit-user-select: none; /* for button */ 312 | -moz-user-select: none; 313 | -ms-user-select: none; 314 | } 315 | 316 | div.code-toolbar > .toolbar a, 317 | div.code-toolbar > .toolbar button, 318 | div.code-toolbar > .toolbar span { 319 | color: #bbb; 320 | font-size: .8em; 321 | padding: 0 .5em; 322 | background: #f5f2f0; 323 | background: rgba(224, 224, 224, 0.2); 324 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 325 | border-radius: .5em; 326 | } 327 | 328 | div.code-toolbar > .toolbar a:hover, 329 | div.code-toolbar > .toolbar a:focus, 330 | div.code-toolbar > .toolbar button:hover, 331 | div.code-toolbar > .toolbar button:focus, 332 | div.code-toolbar > .toolbar span:hover, 333 | div.code-toolbar > .toolbar span:focus { 334 | color: inherit; 335 | text-decoration: none; 336 | } 337 | 338 | -------------------------------------------------------------------------------- /lib/prism/css/Dark.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-dark&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js Dark theme for JavaScript, CSS and HTML 5 | * Based on the slides of the talk “/Reg(exp){2}lained/” 6 | * @author Lea Verou 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | color: white; 12 | background: none; 13 | text-shadow: 0 -.1em .2em black; 14 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 15 | font-size: 1em; 16 | text-align: left; 17 | white-space: pre; 18 | word-spacing: normal; 19 | word-break: normal; 20 | word-wrap: normal; 21 | line-height: 1.5; 22 | margin: 0px; 23 | 24 | -moz-tab-size: 4; 25 | -o-tab-size: 4; 26 | tab-size: 4; 27 | 28 | -webkit-hyphens: none; 29 | -moz-hyphens: none; 30 | -ms-hyphens: none; 31 | hyphens: none; 32 | } 33 | 34 | @media print { 35 | code[class*="language-"], 36 | pre[class*="language-"] { 37 | text-shadow: none; 38 | } 39 | } 40 | 41 | pre[class*="language-"], 42 | :not(pre) > code[class*="language-"] { 43 | background: hsl(30, 20%, 25%); 44 | } 45 | 46 | /* Code blocks */ 47 | pre[class*="language-"] { 48 | padding: 1em; 49 | margin: .5em 0; 50 | overflow: auto; 51 | border: .3em solid hsl(30, 20%, 40%); 52 | border-radius: .5em; 53 | box-shadow: 1px 1px .5em black inset; 54 | } 55 | 56 | /* Inline code */ 57 | :not(pre) > code[class*="language-"] { 58 | padding: .15em .2em .05em; 59 | border-radius: .3em; 60 | border: .13em solid hsl(30, 20%, 40%); 61 | box-shadow: 1px 1px .3em -.1em black inset; 62 | white-space: normal; 63 | } 64 | 65 | .token.comment, 66 | .token.prolog, 67 | .token.doctype, 68 | .token.cdata { 69 | color: hsl(30, 20%, 50%); 70 | } 71 | 72 | .token.punctuation { 73 | opacity: .7; 74 | } 75 | 76 | .namespace { 77 | opacity: .7; 78 | } 79 | 80 | .token.property, 81 | .token.tag, 82 | .token.boolean, 83 | .token.number, 84 | .token.constant, 85 | .token.symbol { 86 | color: hsl(350, 40%, 70%); 87 | } 88 | 89 | .token.selector, 90 | .token.attr-name, 91 | .token.string, 92 | .token.char, 93 | .token.builtin, 94 | .token.inserted { 95 | color: hsl(75, 70%, 60%); 96 | } 97 | 98 | .token.operator, 99 | .token.entity, 100 | .token.url, 101 | .language-css .token.string, 102 | .style .token.string, 103 | .token.variable { 104 | color: hsl(40, 90%, 60%); 105 | } 106 | 107 | .token.atrule, 108 | .token.attr-value, 109 | .token.keyword { 110 | color: hsl(350, 40%, 70%); 111 | } 112 | 113 | .token.regex, 114 | .token.important { 115 | color: #e90; 116 | } 117 | 118 | .token.important, 119 | .token.bold { 120 | font-weight: bold; 121 | } 122 | .token.italic { 123 | font-style: italic; 124 | } 125 | 126 | .token.entity { 127 | cursor: help; 128 | } 129 | 130 | .token.deleted { 131 | color: red; 132 | } 133 | 134 | pre[class*="language-"].line-numbers { 135 | position: relative; 136 | padding-left: 3.8em; 137 | counter-reset: linenumber; 138 | } 139 | 140 | pre[class*="language-"].line-numbers > code { 141 | position: relative; 142 | white-space: inherit; 143 | } 144 | 145 | .line-numbers .line-numbers-rows { 146 | position: absolute; 147 | pointer-events: none; 148 | top: 0; 149 | font-size: 100%; 150 | left: -3.8em; 151 | width: 3em; /* works for line-numbers below 1000 lines */ 152 | letter-spacing: -1px; 153 | border-right: 1px solid #999; 154 | 155 | -webkit-user-select: none; 156 | -moz-user-select: none; 157 | -ms-user-select: none; 158 | user-select: none; 159 | 160 | } 161 | 162 | .line-numbers-rows > span { 163 | pointer-events: none; 164 | display: block; 165 | counter-increment: linenumber; 166 | } 167 | 168 | .line-numbers-rows > span:before { 169 | content: counter(linenumber); 170 | color: #999; 171 | display: block; 172 | padding-right: 0.8em; 173 | text-align: right; 174 | } 175 | 176 | div.code-toolbar { 177 | position: relative; 178 | } 179 | 180 | div.code-toolbar > .toolbar { 181 | position: absolute; 182 | top: .3em; 183 | right: .2em; 184 | transition: opacity 0.3s ease-in-out; 185 | opacity: 0; 186 | } 187 | 188 | div.code-toolbar:hover > .toolbar { 189 | opacity: 1; 190 | } 191 | 192 | /* Separate line b/c rules are thrown out if selector is invalid. 193 | IE11 and old Edge versions don't support :focus-within. */ 194 | div.code-toolbar:focus-within > .toolbar { 195 | opacity: 1; 196 | } 197 | 198 | div.code-toolbar > .toolbar .toolbar-item { 199 | display: inline-block; 200 | } 201 | 202 | div.code-toolbar > .toolbar a { 203 | cursor: pointer; 204 | } 205 | 206 | div.code-toolbar > .toolbar button { 207 | background: none; 208 | border: 0; 209 | color: inherit; 210 | font: inherit; 211 | line-height: normal; 212 | overflow: visible; 213 | padding: 0; 214 | -webkit-user-select: none; /* for button */ 215 | -moz-user-select: none; 216 | -ms-user-select: none; 217 | } 218 | 219 | div.code-toolbar > .toolbar a, 220 | div.code-toolbar > .toolbar button, 221 | div.code-toolbar > .toolbar span { 222 | color: #bbb; 223 | font-size: .8em; 224 | padding: 0 .5em; 225 | background: #f5f2f0; 226 | background: rgba(224, 224, 224, 0.2); 227 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 228 | border-radius: .5em; 229 | } 230 | 231 | div.code-toolbar > .toolbar a:hover, 232 | div.code-toolbar > .toolbar a:focus, 233 | div.code-toolbar > .toolbar button:hover, 234 | div.code-toolbar > .toolbar button:focus, 235 | div.code-toolbar > .toolbar span:hover, 236 | div.code-toolbar > .toolbar span:focus { 237 | color: inherit; 238 | text-decoration: none; 239 | } 240 | 241 | -------------------------------------------------------------------------------- /lib/prism/css/Default.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js default theme for JavaScript, CSS and HTML 5 | * Based on dabblet (http://dabblet.com) 6 | * @author Lea Verou 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | color: black; 12 | background: none; 13 | text-shadow: 0 1px white; 14 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 15 | font-size: 1em; 16 | text-align: left; 17 | white-space: pre; 18 | word-spacing: normal; 19 | word-break: normal; 20 | word-wrap: normal; 21 | line-height: 1.5; 22 | margin: 0px; 23 | 24 | -moz-tab-size: 4; 25 | -o-tab-size: 4; 26 | tab-size: 4; 27 | 28 | -webkit-hyphens: none; 29 | -moz-hyphens: none; 30 | -ms-hyphens: none; 31 | hyphens: none; 32 | } 33 | 34 | pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection, 35 | code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection { 36 | text-shadow: none; 37 | background: #b3d4fc; 38 | } 39 | 40 | pre[class*="language-"]::selection, pre[class*="language-"] ::selection, 41 | code[class*="language-"]::selection, code[class*="language-"] ::selection { 42 | text-shadow: none; 43 | background: #b3d4fc; 44 | } 45 | 46 | @media print { 47 | code[class*="language-"], 48 | pre[class*="language-"] { 49 | text-shadow: none; 50 | } 51 | } 52 | 53 | /* Code blocks */ 54 | pre[class*="language-"] { 55 | padding: 1em; 56 | margin: .5em 0; 57 | overflow: auto; 58 | } 59 | 60 | :not(pre) > code[class*="language-"], 61 | pre[class*="language-"] { 62 | background: #f5f2f0; 63 | } 64 | 65 | /* Inline code */ 66 | :not(pre) > code[class*="language-"] { 67 | padding: .1em; 68 | border-radius: .3em; 69 | white-space: normal; 70 | } 71 | 72 | .token.comment, 73 | .token.prolog, 74 | .token.doctype, 75 | .token.cdata { 76 | color: slategray; 77 | } 78 | 79 | .token.punctuation { 80 | color: #999; 81 | } 82 | 83 | .namespace { 84 | opacity: .7; 85 | } 86 | 87 | .token.property, 88 | .token.tag, 89 | .token.boolean, 90 | .token.number, 91 | .token.constant, 92 | .token.symbol, 93 | .token.deleted { 94 | color: #905; 95 | } 96 | 97 | .token.selector, 98 | .token.attr-name, 99 | .token.string, 100 | .token.char, 101 | .token.builtin, 102 | .token.inserted { 103 | color: #690; 104 | } 105 | 106 | .token.operator, 107 | .token.entity, 108 | .token.url, 109 | .language-css .token.string, 110 | .style .token.string { 111 | color: #9a6e3a; 112 | background: hsla(0, 0%, 100%, .5); 113 | } 114 | 115 | .token.atrule, 116 | .token.attr-value, 117 | .token.keyword { 118 | color: #07a; 119 | } 120 | 121 | .token.function, 122 | .token.class-name { 123 | color: #DD4A68; 124 | } 125 | 126 | .token.regex, 127 | .token.important, 128 | .token.variable { 129 | color: #e90; 130 | } 131 | 132 | .token.important, 133 | .token.bold { 134 | font-weight: bold; 135 | } 136 | .token.italic { 137 | font-style: italic; 138 | } 139 | 140 | .token.entity { 141 | cursor: help; 142 | } 143 | 144 | pre[class*="language-"].line-numbers { 145 | position: relative; 146 | padding-left: 3.8em; 147 | counter-reset: linenumber; 148 | } 149 | 150 | pre[class*="language-"].line-numbers > code { 151 | position: relative; 152 | white-space: inherit; 153 | } 154 | 155 | .line-numbers .line-numbers-rows { 156 | position: absolute; 157 | pointer-events: none; 158 | top: 0; 159 | font-size: 100%; 160 | left: -3.8em; 161 | width: 3em; /* works for line-numbers below 1000 lines */ 162 | letter-spacing: -1px; 163 | border-right: 1px solid #999; 164 | 165 | -webkit-user-select: none; 166 | -moz-user-select: none; 167 | -ms-user-select: none; 168 | user-select: none; 169 | 170 | } 171 | 172 | .line-numbers-rows > span { 173 | pointer-events: none; 174 | display: block; 175 | counter-increment: linenumber; 176 | } 177 | 178 | .line-numbers-rows > span:before { 179 | content: counter(linenumber); 180 | color: #999; 181 | display: block; 182 | padding-right: 0.8em; 183 | text-align: right; 184 | } 185 | 186 | div.code-toolbar { 187 | position: relative; 188 | } 189 | 190 | div.code-toolbar > .toolbar { 191 | position: absolute; 192 | top: .3em; 193 | right: .2em; 194 | transition: opacity 0.3s ease-in-out; 195 | opacity: 0; 196 | } 197 | 198 | div.code-toolbar:hover > .toolbar { 199 | opacity: 1; 200 | } 201 | 202 | /* Separate line b/c rules are thrown out if selector is invalid. 203 | IE11 and old Edge versions don't support :focus-within. */ 204 | div.code-toolbar:focus-within > .toolbar { 205 | opacity: 1; 206 | } 207 | 208 | div.code-toolbar > .toolbar .toolbar-item { 209 | display: inline-block; 210 | } 211 | 212 | div.code-toolbar > .toolbar a { 213 | cursor: pointer; 214 | } 215 | 216 | div.code-toolbar > .toolbar button { 217 | background: none; 218 | border: 0; 219 | color: inherit; 220 | font: inherit; 221 | line-height: normal; 222 | overflow: visible; 223 | padding: 0; 224 | -webkit-user-select: none; /* for button */ 225 | -moz-user-select: none; 226 | -ms-user-select: none; 227 | } 228 | 229 | div.code-toolbar > .toolbar a, 230 | div.code-toolbar > .toolbar button, 231 | div.code-toolbar > .toolbar span { 232 | color: #bbb; 233 | font-size: .8em; 234 | padding: 0 .5em; 235 | background: #f5f2f0; 236 | background: rgba(224, 224, 224, 0.2); 237 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 238 | border-radius: .5em; 239 | } 240 | 241 | div.code-toolbar > .toolbar a:hover, 242 | div.code-toolbar > .toolbar a:focus, 243 | div.code-toolbar > .toolbar button:hover, 244 | div.code-toolbar > .toolbar button:focus, 245 | div.code-toolbar > .toolbar span:hover, 246 | div.code-toolbar > .toolbar span:focus { 247 | color: inherit; 248 | text-decoration: none; 249 | } 250 | 251 | -------------------------------------------------------------------------------- /lib/prism/css/Funky.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-funky&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js Funky theme 5 | * Based on “Polyfilling the gaps” talk slides http://lea.verou.me/polyfilling-the-gaps/ 6 | * @author Lea Verou 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 12 | font-size: 1em; 13 | text-align: left; 14 | white-space: pre; 15 | word-spacing: normal; 16 | word-break: normal; 17 | word-wrap: normal; 18 | line-height: 1.5; 19 | margin: 0px; 20 | 21 | -moz-tab-size: 4; 22 | -o-tab-size: 4; 23 | tab-size: 4; 24 | 25 | -webkit-hyphens: none; 26 | -moz-hyphens: none; 27 | -ms-hyphens: none; 28 | hyphens: none; 29 | } 30 | 31 | /* Code blocks */ 32 | pre[class*="language-"] { 33 | padding: .4em .8em; 34 | margin: .5em 0; 35 | overflow: auto; 36 | background: url('data:image/svg+xml;charset=utf-8,%0D%0A%0D%0A%0D%0A<%2Fsvg>'); 37 | background-size: 1em 1em; 38 | } 39 | 40 | code[class*="language-"] { 41 | background: black; 42 | color: white; 43 | box-shadow: -.3em 0 0 .3em black, .3em 0 0 .3em black; 44 | } 45 | 46 | /* Inline code */ 47 | :not(pre) > code[class*="language-"] { 48 | padding: .2em; 49 | border-radius: .3em; 50 | box-shadow: none; 51 | white-space: normal; 52 | } 53 | 54 | .token.comment, 55 | .token.prolog, 56 | .token.doctype, 57 | .token.cdata { 58 | color: #aaa; 59 | } 60 | 61 | .token.punctuation { 62 | color: #999; 63 | } 64 | 65 | .namespace { 66 | opacity: .7; 67 | } 68 | 69 | .token.property, 70 | .token.tag, 71 | .token.boolean, 72 | .token.number, 73 | .token.constant, 74 | .token.symbol { 75 | color: #0cf; 76 | } 77 | 78 | .token.selector, 79 | .token.attr-name, 80 | .token.string, 81 | .token.char, 82 | .token.builtin { 83 | color: yellow; 84 | } 85 | 86 | .token.operator, 87 | .token.entity, 88 | .token.url, 89 | .language-css .token.string, 90 | .token.variable, 91 | .token.inserted { 92 | color: yellowgreen; 93 | } 94 | 95 | .token.atrule, 96 | .token.attr-value, 97 | .token.keyword { 98 | color: deeppink; 99 | } 100 | 101 | .token.regex, 102 | .token.important { 103 | color: orange; 104 | } 105 | 106 | .token.important, 107 | .token.bold { 108 | font-weight: bold; 109 | } 110 | .token.italic { 111 | font-style: italic; 112 | } 113 | 114 | .token.entity { 115 | cursor: help; 116 | } 117 | 118 | .token.deleted { 119 | color: red; 120 | } 121 | 122 | /* Plugin styles: Diff Highlight */ 123 | pre.diff-highlight.diff-highlight > code .token.deleted:not(.prefix), 124 | pre > code.diff-highlight.diff-highlight .token.deleted:not(.prefix) { 125 | background-color: rgba(255, 0, 0, .3); 126 | display: inline; 127 | } 128 | 129 | pre.diff-highlight.diff-highlight > code .token.inserted:not(.prefix), 130 | pre > code.diff-highlight.diff-highlight .token.inserted:not(.prefix) { 131 | background-color: rgba(0, 255, 128, .3); 132 | display: inline; 133 | } 134 | 135 | pre[class*="language-"].line-numbers { 136 | position: relative; 137 | padding-left: 3.8em; 138 | counter-reset: linenumber; 139 | } 140 | 141 | pre[class*="language-"].line-numbers > code { 142 | position: relative; 143 | white-space: inherit; 144 | } 145 | 146 | .line-numbers .line-numbers-rows { 147 | position: absolute; 148 | pointer-events: none; 149 | top: 0; 150 | font-size: 100%; 151 | left: -3.8em; 152 | width: 3em; /* works for line-numbers below 1000 lines */ 153 | letter-spacing: -1px; 154 | border-right: 1px solid #999; 155 | 156 | -webkit-user-select: none; 157 | -moz-user-select: none; 158 | -ms-user-select: none; 159 | user-select: none; 160 | 161 | } 162 | 163 | .line-numbers-rows > span { 164 | pointer-events: none; 165 | display: block; 166 | counter-increment: linenumber; 167 | } 168 | 169 | .line-numbers-rows > span:before { 170 | content: counter(linenumber); 171 | color: #999; 172 | display: block; 173 | padding-right: 0.8em; 174 | text-align: right; 175 | } 176 | 177 | div.code-toolbar { 178 | position: relative; 179 | } 180 | 181 | div.code-toolbar > .toolbar { 182 | position: absolute; 183 | top: .3em; 184 | right: .2em; 185 | transition: opacity 0.3s ease-in-out; 186 | opacity: 0; 187 | } 188 | 189 | div.code-toolbar:hover > .toolbar { 190 | opacity: 1; 191 | } 192 | 193 | /* Separate line b/c rules are thrown out if selector is invalid. 194 | IE11 and old Edge versions don't support :focus-within. */ 195 | div.code-toolbar:focus-within > .toolbar { 196 | opacity: 1; 197 | } 198 | 199 | div.code-toolbar > .toolbar .toolbar-item { 200 | display: inline-block; 201 | } 202 | 203 | div.code-toolbar > .toolbar a { 204 | cursor: pointer; 205 | } 206 | 207 | div.code-toolbar > .toolbar button { 208 | background: none; 209 | border: 0; 210 | color: inherit; 211 | font: inherit; 212 | line-height: normal; 213 | overflow: visible; 214 | padding: 0; 215 | -webkit-user-select: none; /* for button */ 216 | -moz-user-select: none; 217 | -ms-user-select: none; 218 | } 219 | 220 | div.code-toolbar > .toolbar a, 221 | div.code-toolbar > .toolbar button, 222 | div.code-toolbar > .toolbar span { 223 | color: #bbb; 224 | font-size: .8em; 225 | padding: 0 .5em; 226 | background: #f5f2f0; 227 | background: rgba(224, 224, 224, 0.2); 228 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 229 | border-radius: .5em; 230 | } 231 | 232 | div.code-toolbar > .toolbar a:hover, 233 | div.code-toolbar > .toolbar a:focus, 234 | div.code-toolbar > .toolbar button:hover, 235 | div.code-toolbar > .toolbar button:focus, 236 | div.code-toolbar > .toolbar span:hover, 237 | div.code-toolbar > .toolbar span:focus { 238 | color: inherit; 239 | text-decoration: none; 240 | } 241 | 242 | -------------------------------------------------------------------------------- /lib/prism/css/Okaidia.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-okaidia&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * okaidia theme for JavaScript, CSS and HTML 5 | * Loosely based on Monokai textmate theme by http://www.monokai.nl/ 6 | * @author ocodia 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | color: #f8f8f2; 12 | background: none; 13 | text-shadow: 0 1px rgba(0, 0, 0, 0.3); 14 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 15 | font-size: 1em; 16 | text-align: left; 17 | white-space: pre; 18 | word-spacing: normal; 19 | word-break: normal; 20 | word-wrap: normal; 21 | line-height: 1.5; 22 | margin: 0px; 23 | 24 | -moz-tab-size: 4; 25 | -o-tab-size: 4; 26 | tab-size: 4; 27 | 28 | -webkit-hyphens: none; 29 | -moz-hyphens: none; 30 | -ms-hyphens: none; 31 | hyphens: none; 32 | } 33 | 34 | /* Code blocks */ 35 | pre[class*="language-"] { 36 | padding: 1em; 37 | margin: .5em 0; 38 | overflow: auto; 39 | border-radius: 0.3em; 40 | } 41 | 42 | :not(pre) > code[class*="language-"], 43 | pre[class*="language-"] { 44 | background: #272822; 45 | } 46 | 47 | /* Inline code */ 48 | :not(pre) > code[class*="language-"] { 49 | padding: .1em; 50 | border-radius: .3em; 51 | white-space: normal; 52 | } 53 | 54 | .token.comment, 55 | .token.prolog, 56 | .token.doctype, 57 | .token.cdata { 58 | color: slategray; 59 | } 60 | 61 | .token.punctuation { 62 | color: #f8f8f2; 63 | } 64 | 65 | .namespace { 66 | opacity: .7; 67 | } 68 | 69 | .token.property, 70 | .token.tag, 71 | .token.constant, 72 | .token.symbol, 73 | .token.deleted { 74 | color: #f92672; 75 | } 76 | 77 | .token.boolean, 78 | .token.number { 79 | color: #ae81ff; 80 | } 81 | 82 | .token.selector, 83 | .token.attr-name, 84 | .token.string, 85 | .token.char, 86 | .token.builtin, 87 | .token.inserted { 88 | color: #a6e22e; 89 | } 90 | 91 | .token.operator, 92 | .token.entity, 93 | .token.url, 94 | .language-css .token.string, 95 | .style .token.string, 96 | .token.variable { 97 | color: #f8f8f2; 98 | } 99 | 100 | .token.atrule, 101 | .token.attr-value, 102 | .token.function, 103 | .token.class-name { 104 | color: #e6db74; 105 | } 106 | 107 | .token.keyword { 108 | color: #66d9ef; 109 | } 110 | 111 | .token.regex, 112 | .token.important { 113 | color: #fd971f; 114 | } 115 | 116 | .token.important, 117 | .token.bold { 118 | font-weight: bold; 119 | } 120 | .token.italic { 121 | font-style: italic; 122 | } 123 | 124 | .token.entity { 125 | cursor: help; 126 | } 127 | 128 | pre[class*="language-"].line-numbers { 129 | position: relative; 130 | padding-left: 3.8em; 131 | counter-reset: linenumber; 132 | } 133 | 134 | pre[class*="language-"].line-numbers > code { 135 | position: relative; 136 | white-space: inherit; 137 | } 138 | 139 | .line-numbers .line-numbers-rows { 140 | position: absolute; 141 | pointer-events: none; 142 | top: 0; 143 | font-size: 100%; 144 | left: -3.8em; 145 | width: 3em; /* works for line-numbers below 1000 lines */ 146 | letter-spacing: -1px; 147 | border-right: 1px solid #999; 148 | 149 | -webkit-user-select: none; 150 | -moz-user-select: none; 151 | -ms-user-select: none; 152 | user-select: none; 153 | 154 | } 155 | 156 | .line-numbers-rows > span { 157 | pointer-events: none; 158 | display: block; 159 | counter-increment: linenumber; 160 | } 161 | 162 | .line-numbers-rows > span:before { 163 | content: counter(linenumber); 164 | color: #999; 165 | display: block; 166 | padding-right: 0.8em; 167 | text-align: right; 168 | } 169 | 170 | div.code-toolbar { 171 | position: relative; 172 | } 173 | 174 | div.code-toolbar > .toolbar { 175 | position: absolute; 176 | top: .3em; 177 | right: .2em; 178 | transition: opacity 0.3s ease-in-out; 179 | opacity: 0; 180 | } 181 | 182 | div.code-toolbar:hover > .toolbar { 183 | opacity: 1; 184 | } 185 | 186 | /* Separate line b/c rules are thrown out if selector is invalid. 187 | IE11 and old Edge versions don't support :focus-within. */ 188 | div.code-toolbar:focus-within > .toolbar { 189 | opacity: 1; 190 | } 191 | 192 | div.code-toolbar > .toolbar .toolbar-item { 193 | display: inline-block; 194 | } 195 | 196 | div.code-toolbar > .toolbar a { 197 | cursor: pointer; 198 | } 199 | 200 | div.code-toolbar > .toolbar button { 201 | background: none; 202 | border: 0; 203 | color: inherit; 204 | font: inherit; 205 | line-height: normal; 206 | overflow: visible; 207 | padding: 0; 208 | -webkit-user-select: none; /* for button */ 209 | -moz-user-select: none; 210 | -ms-user-select: none; 211 | } 212 | 213 | div.code-toolbar > .toolbar a, 214 | div.code-toolbar > .toolbar button, 215 | div.code-toolbar > .toolbar span { 216 | color: #bbb; 217 | font-size: .8em; 218 | padding: 0 .5em; 219 | background: #f5f2f0; 220 | background: rgba(224, 224, 224, 0.2); 221 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 222 | border-radius: .5em; 223 | } 224 | 225 | div.code-toolbar > .toolbar a:hover, 226 | div.code-toolbar > .toolbar a:focus, 227 | div.code-toolbar > .toolbar button:hover, 228 | div.code-toolbar > .toolbar button:focus, 229 | div.code-toolbar > .toolbar span:hover, 230 | div.code-toolbar > .toolbar span:focus { 231 | color: inherit; 232 | text-decoration: none; 233 | } 234 | 235 | -------------------------------------------------------------------------------- /lib/prism/css/SolarizedLight.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-solarizedlight&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /* 4 | Solarized Color Schemes originally by Ethan Schoonover 5 | http://ethanschoonover.com/solarized 6 | 7 | Ported for PrismJS by Hector Matos 8 | Website: https://krakendev.io 9 | Twitter Handle: https://twitter.com/allonsykraken) 10 | */ 11 | 12 | /* 13 | SOLARIZED HEX 14 | --------- ------- 15 | base03 #002b36 16 | base02 #073642 17 | base01 #586e75 18 | base00 #657b83 19 | base0 #839496 20 | base1 #93a1a1 21 | base2 #eee8d5 22 | base3 #fdf6e3 23 | yellow #b58900 24 | orange #cb4b16 25 | red #dc322f 26 | magenta #d33682 27 | violet #6c71c4 28 | blue #268bd2 29 | cyan #2aa198 30 | green #859900 31 | */ 32 | 33 | code[class*="language-"], 34 | pre[class*="language-"] { 35 | color: #657b83; /* base00 */ 36 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 37 | font-size: 1em; 38 | text-align: left; 39 | white-space: pre; 40 | word-spacing: normal; 41 | word-break: normal; 42 | word-wrap: normal; 43 | margin: 0px; 44 | 45 | line-height: 1.5; 46 | 47 | -moz-tab-size: 4; 48 | -o-tab-size: 4; 49 | tab-size: 4; 50 | 51 | -webkit-hyphens: none; 52 | -moz-hyphens: none; 53 | -ms-hyphens: none; 54 | hyphens: none; 55 | } 56 | 57 | pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection, 58 | code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection { 59 | background: #073642; /* base02 */ 60 | } 61 | 62 | pre[class*="language-"]::selection, pre[class*="language-"] ::selection, 63 | code[class*="language-"]::selection, code[class*="language-"] ::selection { 64 | background: #073642; /* base02 */ 65 | } 66 | 67 | /* Code blocks */ 68 | pre[class*="language-"] { 69 | padding: 1em; 70 | margin: .5em 0; 71 | overflow: auto; 72 | border-radius: 0.3em; 73 | } 74 | 75 | :not(pre) > code[class*="language-"], 76 | pre[class*="language-"] { 77 | background-color: #fdf6e3; /* base3 */ 78 | } 79 | 80 | /* Inline code */ 81 | :not(pre) > code[class*="language-"] { 82 | padding: .1em; 83 | border-radius: .3em; 84 | } 85 | 86 | .token.comment, 87 | .token.prolog, 88 | .token.doctype, 89 | .token.cdata { 90 | color: #93a1a1; /* base1 */ 91 | } 92 | 93 | .token.punctuation { 94 | color: #586e75; /* base01 */ 95 | } 96 | 97 | .namespace { 98 | opacity: .7; 99 | } 100 | 101 | .token.property, 102 | .token.tag, 103 | .token.boolean, 104 | .token.number, 105 | .token.constant, 106 | .token.symbol, 107 | .token.deleted { 108 | color: #268bd2; /* blue */ 109 | } 110 | 111 | .token.selector, 112 | .token.attr-name, 113 | .token.string, 114 | .token.char, 115 | .token.builtin, 116 | .token.url, 117 | .token.inserted { 118 | color: #2aa198; /* cyan */ 119 | } 120 | 121 | .token.entity { 122 | color: #657b83; /* base00 */ 123 | background: #eee8d5; /* base2 */ 124 | } 125 | 126 | .token.atrule, 127 | .token.attr-value, 128 | .token.keyword { 129 | color: #859900; /* green */ 130 | } 131 | 132 | .token.function, 133 | .token.class-name { 134 | color: #b58900; /* yellow */ 135 | } 136 | 137 | .token.regex, 138 | .token.important, 139 | .token.variable { 140 | color: #cb4b16; /* orange */ 141 | } 142 | 143 | .token.important, 144 | .token.bold { 145 | font-weight: bold; 146 | } 147 | .token.italic { 148 | font-style: italic; 149 | } 150 | 151 | .token.entity { 152 | cursor: help; 153 | } 154 | 155 | pre[class*="language-"].line-numbers { 156 | position: relative; 157 | padding-left: 3.8em; 158 | counter-reset: linenumber; 159 | } 160 | 161 | pre[class*="language-"].line-numbers > code { 162 | position: relative; 163 | white-space: inherit; 164 | } 165 | 166 | .line-numbers .line-numbers-rows { 167 | position: absolute; 168 | pointer-events: none; 169 | top: 0; 170 | font-size: 100%; 171 | left: -3.8em; 172 | width: 3em; /* works for line-numbers below 1000 lines */ 173 | letter-spacing: -1px; 174 | border-right: 1px solid #999; 175 | 176 | -webkit-user-select: none; 177 | -moz-user-select: none; 178 | -ms-user-select: none; 179 | user-select: none; 180 | 181 | } 182 | 183 | .line-numbers-rows > span { 184 | pointer-events: none; 185 | display: block; 186 | counter-increment: linenumber; 187 | } 188 | 189 | .line-numbers-rows > span:before { 190 | content: counter(linenumber); 191 | color: #999; 192 | display: block; 193 | padding-right: 0.8em; 194 | text-align: right; 195 | } 196 | 197 | div.code-toolbar { 198 | position: relative; 199 | } 200 | 201 | div.code-toolbar > .toolbar { 202 | position: absolute; 203 | top: .3em; 204 | right: .2em; 205 | transition: opacity 0.3s ease-in-out; 206 | opacity: 0; 207 | } 208 | 209 | div.code-toolbar:hover > .toolbar { 210 | opacity: 1; 211 | } 212 | 213 | /* Separate line b/c rules are thrown out if selector is invalid. 214 | IE11 and old Edge versions don't support :focus-within. */ 215 | div.code-toolbar:focus-within > .toolbar { 216 | opacity: 1; 217 | } 218 | 219 | div.code-toolbar > .toolbar .toolbar-item { 220 | display: inline-block; 221 | } 222 | 223 | div.code-toolbar > .toolbar a { 224 | cursor: pointer; 225 | } 226 | 227 | div.code-toolbar > .toolbar button { 228 | background: none; 229 | border: 0; 230 | color: inherit; 231 | font: inherit; 232 | line-height: normal; 233 | overflow: visible; 234 | padding: 0; 235 | -webkit-user-select: none; /* for button */ 236 | -moz-user-select: none; 237 | -ms-user-select: none; 238 | } 239 | 240 | div.code-toolbar > .toolbar a, 241 | div.code-toolbar > .toolbar button, 242 | div.code-toolbar > .toolbar span { 243 | color: #bbb; 244 | font-size: .8em; 245 | padding: 0 .5em; 246 | background: #f5f2f0; 247 | background: rgba(224, 224, 224, 0.2); 248 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 249 | border-radius: .5em; 250 | } 251 | 252 | div.code-toolbar > .toolbar a:hover, 253 | div.code-toolbar > .toolbar a:focus, 254 | div.code-toolbar > .toolbar button:hover, 255 | div.code-toolbar > .toolbar button:focus, 256 | div.code-toolbar > .toolbar span:hover, 257 | div.code-toolbar > .toolbar span:focus { 258 | color: inherit; 259 | text-decoration: none; 260 | } 261 | 262 | -------------------------------------------------------------------------------- /lib/prism/css/TomorrowNight.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-tomorrow&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js tomorrow night eighties for JavaScript, CoffeeScript, CSS and HTML 5 | * Based on https://github.com/chriskempson/tomorrow-theme 6 | * @author Rose Pritchard 7 | */ 8 | 9 | code[class*="language-"], 10 | pre[class*="language-"] { 11 | color: #ccc; 12 | background: none; 13 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 14 | font-size: 1em; 15 | text-align: left; 16 | white-space: pre; 17 | word-spacing: normal; 18 | word-break: normal; 19 | word-wrap: normal; 20 | line-height: 1.5; 21 | margin: 0px; 22 | 23 | -moz-tab-size: 4; 24 | -o-tab-size: 4; 25 | tab-size: 4; 26 | 27 | -webkit-hyphens: none; 28 | -moz-hyphens: none; 29 | -ms-hyphens: none; 30 | hyphens: none; 31 | 32 | } 33 | 34 | /* Code blocks */ 35 | pre[class*="language-"] { 36 | padding: 1em; 37 | margin: .5em 0; 38 | overflow: auto; 39 | } 40 | 41 | :not(pre) > code[class*="language-"], 42 | pre[class*="language-"] { 43 | background: #2d2d2d; 44 | } 45 | 46 | /* Inline code */ 47 | :not(pre) > code[class*="language-"] { 48 | padding: .1em; 49 | border-radius: .3em; 50 | white-space: normal; 51 | } 52 | 53 | .token.comment, 54 | .token.block-comment, 55 | .token.prolog, 56 | .token.doctype, 57 | .token.cdata { 58 | color: #999; 59 | } 60 | 61 | .token.punctuation { 62 | color: #ccc; 63 | } 64 | 65 | .token.tag, 66 | .token.attr-name, 67 | .token.namespace, 68 | .token.deleted { 69 | color: #e2777a; 70 | } 71 | 72 | .token.function-name { 73 | color: #6196cc; 74 | } 75 | 76 | .token.boolean, 77 | .token.number, 78 | .token.function { 79 | color: #f08d49; 80 | } 81 | 82 | .token.property, 83 | .token.class-name, 84 | .token.constant, 85 | .token.symbol { 86 | color: #f8c555; 87 | } 88 | 89 | .token.selector, 90 | .token.important, 91 | .token.atrule, 92 | .token.keyword, 93 | .token.builtin { 94 | color: #cc99cd; 95 | } 96 | 97 | .token.string, 98 | .token.char, 99 | .token.attr-value, 100 | .token.regex, 101 | .token.variable { 102 | color: #7ec699; 103 | } 104 | 105 | .token.operator, 106 | .token.entity, 107 | .token.url { 108 | color: #67cdcc; 109 | } 110 | 111 | .token.important, 112 | .token.bold { 113 | font-weight: bold; 114 | } 115 | .token.italic { 116 | font-style: italic; 117 | } 118 | 119 | .token.entity { 120 | cursor: help; 121 | } 122 | 123 | .token.inserted { 124 | color: green; 125 | } 126 | 127 | pre[class*="language-"].line-numbers { 128 | position: relative; 129 | padding-left: 3.8em; 130 | counter-reset: linenumber; 131 | } 132 | 133 | pre[class*="language-"].line-numbers > code { 134 | position: relative; 135 | white-space: inherit; 136 | } 137 | 138 | .line-numbers .line-numbers-rows { 139 | position: absolute; 140 | pointer-events: none; 141 | top: 0; 142 | font-size: 100%; 143 | left: -3.8em; 144 | width: 3em; /* works for line-numbers below 1000 lines */ 145 | letter-spacing: -1px; 146 | border-right: 1px solid #999; 147 | 148 | -webkit-user-select: none; 149 | -moz-user-select: none; 150 | -ms-user-select: none; 151 | user-select: none; 152 | 153 | } 154 | 155 | .line-numbers-rows > span { 156 | pointer-events: none; 157 | display: block; 158 | counter-increment: linenumber; 159 | } 160 | 161 | .line-numbers-rows > span:before { 162 | content: counter(linenumber); 163 | color: #999; 164 | display: block; 165 | padding-right: 0.8em; 166 | text-align: right; 167 | } 168 | 169 | div.code-toolbar { 170 | position: relative; 171 | } 172 | 173 | div.code-toolbar > .toolbar { 174 | position: absolute; 175 | top: .3em; 176 | right: .2em; 177 | transition: opacity 0.3s ease-in-out; 178 | opacity: 0; 179 | } 180 | 181 | div.code-toolbar:hover > .toolbar { 182 | opacity: 1; 183 | } 184 | 185 | /* Separate line b/c rules are thrown out if selector is invalid. 186 | IE11 and old Edge versions don't support :focus-within. */ 187 | div.code-toolbar:focus-within > .toolbar { 188 | opacity: 1; 189 | } 190 | 191 | div.code-toolbar > .toolbar .toolbar-item { 192 | display: inline-block; 193 | } 194 | 195 | div.code-toolbar > .toolbar a { 196 | cursor: pointer; 197 | } 198 | 199 | div.code-toolbar > .toolbar button { 200 | background: none; 201 | border: 0; 202 | color: inherit; 203 | font: inherit; 204 | line-height: normal; 205 | overflow: visible; 206 | padding: 0; 207 | -webkit-user-select: none; /* for button */ 208 | -moz-user-select: none; 209 | -ms-user-select: none; 210 | } 211 | 212 | div.code-toolbar > .toolbar a, 213 | div.code-toolbar > .toolbar button, 214 | div.code-toolbar > .toolbar span { 215 | color: #bbb; 216 | font-size: .8em; 217 | padding: 0 .5em; 218 | background: #f5f2f0; 219 | background: rgba(224, 224, 224, 0.2); 220 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 221 | border-radius: .5em; 222 | } 223 | 224 | div.code-toolbar > .toolbar a:hover, 225 | div.code-toolbar > .toolbar a:focus, 226 | div.code-toolbar > .toolbar button:hover, 227 | div.code-toolbar > .toolbar button:focus, 228 | div.code-toolbar > .toolbar span:hover, 229 | div.code-toolbar > .toolbar span:focus { 230 | color: inherit; 231 | text-decoration: none; 232 | } 233 | 234 | -------------------------------------------------------------------------------- /lib/prism/css/Twilight.css: -------------------------------------------------------------------------------- 1 | /* PrismJS 1.17.1 2 | https://prismjs.com/download.html#themes=prism-twilight&languages=markup+css+clike+javascript+apacheconf+aspnet+bash+c+csharp+cpp+coffeescript+git+go+java+javadoc+javadoclike+json+less+lua+markdown+markup-templating+nginx+php+python+ruby+smarty+sql&plugins=line-numbers+show-language+normalize-whitespace+toolbar+copy-to-clipboard */ 3 | /** 4 | * prism.js Twilight theme 5 | * Based (more or less) on the Twilight theme originally of Textmate fame. 6 | * @author Remy Bach 7 | */ 8 | code[class*="language-"], 9 | pre[class*="language-"] { 10 | color: white; 11 | background: none; 12 | font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; 13 | font-size: 1em; 14 | text-align: left; 15 | text-shadow: 0 -.1em .2em black; 16 | white-space: pre; 17 | word-spacing: normal; 18 | word-break: normal; 19 | word-wrap: normal; 20 | line-height: 1.5; 21 | margin: 0px; 22 | 23 | -moz-tab-size: 4; 24 | -o-tab-size: 4; 25 | tab-size: 4; 26 | 27 | -webkit-hyphens: none; 28 | -moz-hyphens: none; 29 | -ms-hyphens: none; 30 | hyphens: none; 31 | } 32 | 33 | pre[class*="language-"], 34 | :not(pre) > code[class*="language-"] { 35 | background: hsl(0, 0%, 8%); /* #141414 */ 36 | } 37 | 38 | /* Code blocks */ 39 | pre[class*="language-"] { 40 | border-radius: .5em; 41 | border: .3em solid hsl(0, 0%, 33%); /* #282A2B */ 42 | box-shadow: 1px 1px .5em black inset; 43 | margin: .5em 0; 44 | overflow: auto; 45 | padding: 1em; 46 | } 47 | 48 | pre[class*="language-"]::-moz-selection { 49 | /* Firefox */ 50 | background: hsl(200, 4%, 16%); /* #282A2B */ 51 | } 52 | 53 | pre[class*="language-"]::selection { 54 | /* Safari */ 55 | background: hsl(200, 4%, 16%); /* #282A2B */ 56 | } 57 | 58 | /* Text Selection colour */ 59 | pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection, 60 | code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection { 61 | text-shadow: none; 62 | background: hsla(0, 0%, 93%, 0.15); /* #EDEDED */ 63 | } 64 | 65 | pre[class*="language-"]::selection, pre[class*="language-"] ::selection, 66 | code[class*="language-"]::selection, code[class*="language-"] ::selection { 67 | text-shadow: none; 68 | background: hsla(0, 0%, 93%, 0.15); /* #EDEDED */ 69 | } 70 | 71 | /* Inline code */ 72 | :not(pre) > code[class*="language-"] { 73 | border-radius: .3em; 74 | border: .13em solid hsl(0, 0%, 33%); /* #545454 */ 75 | box-shadow: 1px 1px .3em -.1em black inset; 76 | padding: .15em .2em .05em; 77 | white-space: normal; 78 | } 79 | 80 | .token.comment, 81 | .token.prolog, 82 | .token.doctype, 83 | .token.cdata { 84 | color: hsl(0, 0%, 47%); /* #777777 */ 85 | } 86 | 87 | .token.punctuation { 88 | opacity: .7; 89 | } 90 | 91 | .namespace { 92 | opacity: .7; 93 | } 94 | 95 | .token.tag, 96 | .token.boolean, 97 | .token.number, 98 | .token.deleted { 99 | color: hsl(14, 58%, 55%); /* #CF6A4C */ 100 | } 101 | 102 | .token.keyword, 103 | .token.property, 104 | .token.selector, 105 | .token.constant, 106 | .token.symbol, 107 | .token.builtin { 108 | color: hsl(53, 89%, 79%); /* #F9EE98 */ 109 | } 110 | 111 | .token.attr-name, 112 | .token.attr-value, 113 | .token.string, 114 | .token.char, 115 | .token.operator, 116 | .token.entity, 117 | .token.url, 118 | .language-css .token.string, 119 | .style .token.string, 120 | .token.variable, 121 | .token.inserted { 122 | color: hsl(76, 21%, 52%); /* #8F9D6A */ 123 | } 124 | 125 | .token.atrule { 126 | color: hsl(218, 22%, 55%); /* #7587A6 */ 127 | } 128 | 129 | .token.regex, 130 | .token.important { 131 | color: hsl(42, 75%, 65%); /* #E9C062 */ 132 | } 133 | 134 | .token.important, 135 | .token.bold { 136 | font-weight: bold; 137 | } 138 | .token.italic { 139 | font-style: italic; 140 | } 141 | 142 | .token.entity { 143 | cursor: help; 144 | } 145 | 146 | pre[data-line] { 147 | padding: 1em 0 1em 3em; 148 | position: relative; 149 | } 150 | 151 | /* Markup */ 152 | .language-markup .token.tag, 153 | .language-markup .token.attr-name, 154 | .language-markup .token.punctuation { 155 | color: hsl(33, 33%, 52%); /* #AC885B */ 156 | } 157 | 158 | /* Make the tokens sit above the line highlight so the colours don't look faded. */ 159 | .token { 160 | position: relative; 161 | z-index: 1; 162 | } 163 | 164 | .line-highlight { 165 | background: hsla(0, 0%, 33%, 0.25); /* #545454 */ 166 | background: linear-gradient(to right, hsla(0, 0%, 33%, .1) 70%, hsla(0, 0%, 33%, 0)); /* #545454 */ 167 | border-bottom: 1px dashed hsl(0, 0%, 33%); /* #545454 */ 168 | border-top: 1px dashed hsl(0, 0%, 33%); /* #545454 */ 169 | left: 0; 170 | line-height: inherit; 171 | margin-top: 0.75em; /* Same as .prism’s padding-top */ 172 | padding: inherit 0; 173 | pointer-events: none; 174 | position: absolute; 175 | right: 0; 176 | white-space: pre; 177 | z-index: 0; 178 | } 179 | 180 | .line-highlight:before, 181 | .line-highlight[data-end]:after { 182 | background-color: hsl(215, 15%, 59%); /* #8794A6 */ 183 | border-radius: 999px; 184 | box-shadow: 0 1px white; 185 | color: hsl(24, 20%, 95%); /* #F5F2F0 */ 186 | content: attr(data-start); 187 | font: bold 65%/1.5 sans-serif; 188 | left: .6em; 189 | min-width: 1em; 190 | padding: 0 .5em; 191 | position: absolute; 192 | text-align: center; 193 | text-shadow: none; 194 | top: .4em; 195 | vertical-align: .3em; 196 | } 197 | 198 | .line-highlight[data-end]:after { 199 | bottom: .4em; 200 | content: attr(data-end); 201 | top: auto; 202 | } 203 | 204 | pre[class*="language-"].line-numbers { 205 | position: relative; 206 | padding-left: 3.8em; 207 | counter-reset: linenumber; 208 | } 209 | 210 | pre[class*="language-"].line-numbers > code { 211 | position: relative; 212 | white-space: inherit; 213 | } 214 | 215 | .line-numbers .line-numbers-rows { 216 | position: absolute; 217 | pointer-events: none; 218 | top: 0; 219 | font-size: 100%; 220 | left: -3.8em; 221 | width: 3em; /* works for line-numbers below 1000 lines */ 222 | letter-spacing: -1px; 223 | border-right: 1px solid #999; 224 | 225 | -webkit-user-select: none; 226 | -moz-user-select: none; 227 | -ms-user-select: none; 228 | user-select: none; 229 | 230 | } 231 | 232 | .line-numbers-rows > span { 233 | pointer-events: none; 234 | display: block; 235 | counter-increment: linenumber; 236 | } 237 | 238 | .line-numbers-rows > span:before { 239 | content: counter(linenumber); 240 | color: #999; 241 | display: block; 242 | padding-right: 0.8em; 243 | text-align: right; 244 | } 245 | 246 | div.code-toolbar { 247 | position: relative; 248 | } 249 | 250 | div.code-toolbar > .toolbar { 251 | position: absolute; 252 | top: .3em; 253 | right: .2em; 254 | transition: opacity 0.3s ease-in-out; 255 | opacity: 0; 256 | } 257 | 258 | div.code-toolbar:hover > .toolbar { 259 | opacity: 1; 260 | } 261 | 262 | /* Separate line b/c rules are thrown out if selector is invalid. 263 | IE11 and old Edge versions don't support :focus-within. */ 264 | div.code-toolbar:focus-within > .toolbar { 265 | opacity: 1; 266 | } 267 | 268 | div.code-toolbar > .toolbar .toolbar-item { 269 | display: inline-block; 270 | } 271 | 272 | div.code-toolbar > .toolbar a { 273 | cursor: pointer; 274 | } 275 | 276 | div.code-toolbar > .toolbar button { 277 | background: none; 278 | border: 0; 279 | color: inherit; 280 | font: inherit; 281 | line-height: normal; 282 | overflow: visible; 283 | padding: 0; 284 | -webkit-user-select: none; /* for button */ 285 | -moz-user-select: none; 286 | -ms-user-select: none; 287 | } 288 | 289 | div.code-toolbar > .toolbar a, 290 | div.code-toolbar > .toolbar button, 291 | div.code-toolbar > .toolbar span { 292 | color: #bbb; 293 | font-size: .8em; 294 | padding: 0 .5em; 295 | background: #f5f2f0; 296 | background: rgba(224, 224, 224, 0.2); 297 | box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); 298 | border-radius: .5em; 299 | } 300 | 301 | div.code-toolbar > .toolbar a:hover, 302 | div.code-toolbar > .toolbar a:focus, 303 | div.code-toolbar > .toolbar button:hover, 304 | div.code-toolbar > .toolbar button:focus, 305 | div.code-toolbar > .toolbar span:hover, 306 | div.code-toolbar > .toolbar span:focus { 307 | color: inherit; 308 | text-decoration: none; 309 | } 310 | 311 | -------------------------------------------------------------------------------- /lib/shortcode.php: -------------------------------------------------------------------------------- 1 | 7 | * @link https://github.com/maicong/stay 8 | * @since 1.0.0 9 | * 10 | */ 11 | 12 | $shortcode_tags = array(); 13 | 14 | function add_shortcode($tag, $func) { 15 | global $shortcode_tags; 16 | if ( '' == trim( $tag ) ) { 17 | return; 18 | } 19 | if ( 0 !== preg_match( '@[<>&/\[\]\x00-\x20=]@', $tag ) ) { 20 | return; 21 | } 22 | $shortcode_tags[ $tag ] = $func; 23 | } 24 | 25 | function do_shortcode( $content, $ignore_html = false ) { 26 | global $shortcode_tags; 27 | if ( false === strpos( $content, '[' ) ) { 28 | return $content; 29 | } 30 | if (empty($shortcode_tags) || !is_array($shortcode_tags)) { 31 | return $content; 32 | } 33 | // Find all registered tag names in $content. 34 | //20180603 35 | $pregRule="/

\[(.*?)\]<\/p>/"; 36 | $content = preg_replace($pregRule,'[${1}]', $content); 37 | 38 | preg_match_all( '@\[([^<>&/\[\]\x00-\x20=]++)@', $content, $matches ); 39 | $tagnames = array_intersect( array_keys( $shortcode_tags ), $matches[1] ); 40 | if ( empty( $tagnames ) ) { 41 | return $content; 42 | } 43 | $content = do_shortcodes_in_html_tags( $content, $ignore_html, $tagnames ); 44 | $pattern = get_shortcode_regex( $tagnames ); 45 | $content = preg_replace_callback( "/$pattern/", 'do_shortcode_tag', $content ); 46 | // Always restore square braces so we don't break things like is found. 245 | . '-(?!->)' // Dash not followed by end of comment. 246 | . '[^\-]*+' // Consume non-dashes. 247 | . ')*+' // Loop possessively. 248 | . '(?:-->)?'; // End of comment. If not found, match all input. 249 | $cdata = 250 | '!\[CDATA\[' // Start of comment, after the <. 251 | . '[^\]]*+' // Consume non-]. 252 | . '(?:' // Unroll the loop: Consume everything until ]]> is found. 253 | . '](?!]>)' // One ] not followed by end of comment. 254 | . '[^\]]*+' // Consume non-]. 255 | . ')*+' // Loop possessively. 256 | . '(?:]]>)?'; // End of comment. If not found, match all input. 257 | $escaped = 258 | '(?=' // Is the element escaped? 259 | . '!--' 260 | . '|' 261 | . '!\[CDATA\[' 262 | . ')' 263 | . '(?(?=!-)' // If yes, which type? 264 | . $comments 265 | . '|' 266 | . $cdata 267 | . ')'; 268 | $regex = 269 | '/(' // Capture the entire match. 270 | . '<' // Find start of element. 271 | . '(?' // Conditional expression follows. 272 | . $escaped // Find end of escaped element. 273 | . '|' // ... else ... 274 | . '[^>]*>?' // Find end of normal element. 275 | . ')' 276 | . ')/'; 277 | } 278 | return $regex; 279 | } 280 | 281 | function kses_attr_parse( $element ) { 282 | $valid = preg_match('%^(<\s*)(/\s*)?([a-zA-Z0-9]+\s*)([^>]*)(>?)$%', $element, $matches); 283 | if ( 1 !== $valid ) { 284 | return false; 285 | } 286 | $begin = $matches[1]; 287 | $slash = $matches[2]; 288 | $elname = $matches[3]; 289 | $attr = $matches[4]; 290 | $end = $matches[5]; 291 | if ( '' !== $slash ) { 292 | // Closing elements do not get parsed. 293 | return false; 294 | } 295 | // Is there a closing XHTML slash at the end of the attributes? 296 | if ( 1 === preg_match( '%\s*/\s*$%', $attr, $matches ) ) { 297 | $xhtml_slash = $matches[0]; 298 | $attr = substr( $attr, 0, -strlen( $xhtml_slash ) ); 299 | } else { 300 | $xhtml_slash = ''; 301 | } 302 | 303 | // Split it 304 | $attrarr = kses_hair_parse( $attr ); 305 | if ( false === $attrarr ) { 306 | return false; 307 | } 308 | // Make sure all input is returned by adding front and back matter. 309 | array_unshift( $attrarr, $begin . $slash . $elname ); 310 | array_push( $attrarr, $xhtml_slash . $end ); 311 | 312 | return $attrarr; 313 | } 314 | 315 | function kses_hair_parse( $attr ) { 316 | if ( '' === $attr ) { 317 | return array(); 318 | } 319 | $regex = 320 | '(?:' 321 | . '[-a-zA-Z:]+' // Attribute name. 322 | . '|' 323 | . '\[\[?[^\[\]]+\]\]?' // Shortcode in the name position implies unfiltered_html. 324 | . ')' 325 | . '(?:' // Attribute value. 326 | . '\s*=\s*' // All values begin with '=' 327 | . '(?:' 328 | . '"[^"]*"' // Double-quoted 329 | . '|' 330 | . "'[^']*'" // Single-quoted 331 | . '|' 332 | . '[^\s"\']+' // Non-quoted 333 | . '(?:\s|$)' // Must have a space 334 | . ')' 335 | . '|' 336 | . '(?:\s|$)' // If attribute has no value, space is required. 337 | . ')' 338 | . '\s*'; // Trailing space is optional except as mentioned above. 339 | // Although it is possible to reduce this procedure to a single regexp, 340 | // we must run that regexp twice to get exactly the expected result. 341 | $validation = "%^($regex)+$%"; 342 | $extraction = "%$regex%"; 343 | if ( 1 === preg_match( $validation, $attr ) ) { 344 | preg_match_all( $extraction, $attr, $attrarr ); 345 | return $attrarr[0]; 346 | } else { 347 | return false; 348 | } 349 | } 350 | 351 | function kses_one_attr( $string, $element ) { 352 | $string = preg_replace( ['/[\x00-\x08\x0B\x0C\x0E-\x1F]/', '%&\s*\{[^}]*(\}\s*;?|$)%'], '', $string ); 353 | 354 | // Preserve leading and trailing whitespace. 355 | $matches = array(); 356 | preg_match('/^\s*/', $string, $matches); 357 | $lead = $matches[0]; 358 | preg_match('/\s*$/', $string, $matches); 359 | $trail = $matches[0]; 360 | if ( empty( $trail ) ) { 361 | $string = substr( $string, strlen( $lead ) ); 362 | } else { 363 | $string = substr( $string, strlen( $lead ), -strlen( $trail ) ); 364 | } 365 | 366 | // Parse attribute name and value from input. 367 | $split = preg_split( '/\s*=\s*/', $string, 2 ); 368 | $name = $split[0]; 369 | if ( count( $split ) == 2 ) { 370 | $value = $split[1]; 371 | // Remove quotes surrounding $value. 372 | // Also guarantee correct quoting in $string for this one attribute. 373 | if ( '' == $value ) { 374 | $quote = ''; 375 | } else { 376 | $quote = $value[0]; 377 | } 378 | if ( '"' == $quote || "'" == $quote ) { 379 | if ( substr( $value, -1 ) != $quote ) { 380 | return ''; 381 | } 382 | $value = substr( $value, 1, -1 ); 383 | } else { 384 | $quote = '"'; 385 | } 386 | // Sanitize quotes, angle braces, and entities. 387 | $value = htmlspecialchars( $value, ENT_QUOTES, 'UTF-8' ); 388 | // Sanitize URI values. 389 | $string = "$name=$quote$value$quote"; 390 | $vless = 'n'; 391 | } else { 392 | $value = ''; 393 | $vless = 'y'; 394 | } 395 | 396 | // Restore whitespace. 397 | return $lead . $string . $trail; 398 | } 399 | 400 | function autop( $pee, $br = true ) { 401 | $pre_tags = array(); 402 | if ( trim( $pee ) === '' ) { 403 | return ''; 404 | } 405 | // Just to make things a little easier, pad the end. 406 | $pee = $pee . "\n"; 407 | /* 408 | * Pre tags shouldn't be touched by autop. 409 | * Replace pre tags with placeholders and bring them back after autop. 410 | */ 411 | if ( strpos( $pee, '', $pee ); 413 | $last_pee = array_pop( $pee_parts ); 414 | $pee = ''; 415 | $i = 0; 416 | foreach ( $pee_parts as $pee_part ) { 417 | $start = strpos( $pee_part, ''; 425 | $pee .= substr( $pee_part, 0, $start ) . $name; 426 | $i++; 427 | } 428 | $pee .= $last_pee; 429 | } 430 | // Change multiple
s into two line breaks, which will turn into paragraphs. 431 | $pee = preg_replace( '|\s*|', "\n\n", $pee ); 432 | $allblocks = '(?:table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|form|map|area|blockquote|address|math|style|p|h[1-6]|hr|fieldset|legend|section|article|aside|hgroup|header|footer|nav|figure|figcaption|details|menu|summary)'; 433 | // Add a double line break above block-level opening tags. 434 | $pee = preg_replace( '!(<' . $allblocks . '[\s/>])!', "\n\n$1", $pee ); 435 | // Add a double line break below block-level closing tags. 436 | $pee = preg_replace( '!()!', "$1\n\n", $pee ); 437 | // Standardize newline characters to "\n". 438 | $pee = str_replace( array( "\r\n", "\r" ), "\n", $pee ); 439 | // Find newlines in all elements and add placeholders. 440 | $pee = replace_in_html_tags( $pee, array( "\n" => ' ' ) ); 441 | // Collapse line breaks before and after ', $pee ); 445 | } 446 | /* 447 | * Collapse line breaks inside elements, before and elements 448 | * so they don't get autop'd. 449 | */ 450 | if ( strpos( $pee, '' ) !== false ) { 451 | $pee = preg_replace( '|(]*>)\s*|', '$1', $pee ); 452 | $pee = preg_replace( '|\s*|', '', $pee ); 453 | $pee = preg_replace( '%\s*(]*>)\s*%', '$1', $pee ); 454 | } 455 | /* 456 | * Collapse line breaks inside

elements. 465 | if ( strpos( $pee, ']*>)|', '$1', $pee ); 467 | $pee = preg_replace( '|
\s*|', '', $pee ); 468 | } 469 | // Remove more than two contiguous line breaks. 470 | $pee = preg_replace( "/\n\n+/", "\n\n", $pee ); 471 | // Split up the contents into an array of strings, separated by double line breaks. 472 | $pees = preg_split( '/\n\s*\n/', $pee, -1, PREG_SPLIT_NO_EMPTY ); 473 | // Reset $pee prior to rebuilding. 474 | $pee = ''; 475 | // Rebuild the content as a string, wrapping every bit with a

. 476 | foreach ( $pees as $tinkle ) { 477 | $pee .= '

' . trim( $tinkle, "\n" ) . "

\n"; 478 | } 479 | // Under certain strange conditions it could create a P of entirely whitespace. 480 | $pee = preg_replace( '|

\s*

|', '', $pee ); 481 | // Add a closing

inside

,
, or
tag if missing. 482 | $pee = preg_replace( '!

([^<]+)!', '

$1

', $pee ); 483 | // If an opening or closing block element tag is wrapped in a

, unwrap it. 484 | $pee = preg_replace( '!

\s*(]*>)\s*

!', '$1', $pee ); 485 | // In some cases
  • may get wrapped in

    , fix them. 486 | $pee = preg_replace( '|

    (|', '$1', $pee ); 487 | // If a

    is wrapped with a

    , move it inside the

    . 488 | $pee = preg_replace( '|

    ]*)>|i', '

    ', $pee ); 489 | $pee = str_replace( '

    ', '

    ', $pee ); 490 | // If an opening or closing block element tag is preceded by an opening

    tag, remove it. 491 | $pee = preg_replace( '!

    \s*(]*>)!', '$1', $pee ); 492 | // If an opening or closing block element tag is followed by a closing

    tag, remove it. 493 | $pee = preg_replace( '!(]*>)\s*

    !', '$1', $pee ); 494 | // Optionally insert line breaks. 495 | if ( $br ) { 496 | // Replace newlines that shouldn't be touched with a placeholder. 497 | $pee = preg_replace_callback( '/<(script|style).*?<\/\\1>/s', '_autop_newline_preservation_helper', $pee ); 498 | // Normalize
    499 | $pee = str_replace( array( '
    ', '
    ' ), '
    ', $pee ); 500 | // Replace any new line characters that aren't preceded by a
    with a
    . 501 | $pee = preg_replace( '|(?)\s*\n|', "
    \n", $pee ); 502 | // Replace newline placeholders with newlines. 503 | $pee = str_replace( '', "\n", $pee ); 504 | } 505 | // If a
    tag is after an opening or closing block tag, remove it. 506 | $pee = preg_replace( '!(]*>)\s*
    !', '$1', $pee ); 507 | // If a
    tag is before a subset of opening or closing block tags, remove it. 508 | $pee = preg_replace( '!
    (\s*]*>)!', '$1', $pee ); 509 | $pee = preg_replace( "|\n

    $|", '

    ', $pee ); 510 | // Replace placeholder
     tags with their original content.
    511 | 	if ( ! empty( $pre_tags ) ) {
    512 | 		$pee = str_replace( array_keys( $pre_tags ), array_values( $pre_tags ), $pee );
    513 | 	}
    514 | 	// Restore newlines in all elements.
    515 | 	if ( false !== strpos( $pee, '' ) ) {
    516 | 		$pee = str_replace( array( '  ', '' ), "\n", $pee );
    517 | 	}
    518 | 	return $pee;
    519 | }
    520 | 
    521 | function _autop_newline_preservation_helper( $matches ) {
    522 | 	return str_replace( "\n", '', $matches[0] );
    523 | }
    524 | 
    525 | function replace_in_html_tags( $haystack, $replace_pairs ) {
    526 | 	// Find all elements.
    527 | 	$textarr = html_split( $haystack );
    528 | 	$changed = false;
    529 | 	// Optimize when searching for one item.
    530 | 	if ( 1 === count( $replace_pairs ) ) {
    531 | 		// Extract $needle and $replace.
    532 | 		foreach ( $replace_pairs as $needle => $replace ) {
    533 | 		}
    534 | 		// Loop through delimiters (elements) only.
    535 | 		for ( $i = 1, $c = count( $textarr ); $i < $c; $i += 2 ) {
    536 | 			if ( false !== strpos( $textarr[ $i ], $needle ) ) {
    537 | 				$textarr[ $i ] = str_replace( $needle, $replace, $textarr[ $i ] );
    538 | 				$changed       = true;
    539 | 			}
    540 | 		}
    541 | 	} else {
    542 | 		// Extract all $needles.
    543 | 		$needles = array_keys( $replace_pairs );
    544 | 		// Loop through delimiters (elements) only.
    545 | 		for ( $i = 1, $c = count( $textarr ); $i < $c; $i += 2 ) {
    546 | 			foreach ( $needles as $needle ) {
    547 | 				if ( false !== strpos( $textarr[ $i ], $needle ) ) {
    548 | 					$textarr[ $i ] = strtr( $textarr[ $i ], $replace_pairs );
    549 | 					$changed       = true;
    550 | 					// After one strtr() break out of the foreach loop and look at next element.
    551 | 					break;
    552 | 				}
    553 | 			}
    554 | 		}
    555 | 	}
    556 | 	if ( $changed ) {
    557 | 		$haystack = implode( $textarr );
    558 | 	}
    559 | 	return $haystack;
    560 | }
    561 | 
    
    
    --------------------------------------------------------------------------------
    /page.php:
    --------------------------------------------------------------------------------
     1 | 
     2 | need('header.php'); ?>
     3 | 
     4 | 
    5 |
    6 |
    7 |
    8 |
    9 |
    10 |

    title() ?>

    11 | 12 |
    13 |
    14 | 15 |
    16 | 17 | content); ?> 18 |
    19 |
    20 |
    21 |
    22 | need('comments.php'); ?> 23 |
    24 |
    25 | need('sidebar.php'); ?> 26 |
    27 |
    28 |
    29 | 30 | need('footer.php'); ?> 31 | -------------------------------------------------------------------------------- /page_ friends.php: -------------------------------------------------------------------------------- 1 | 8 | 9 | shortcode) { 14 | $content = do_shortcode($content); 15 | } 16 | 17 | $pattern = '/\]*>/i'; 18 | $replacement = '$2$3'; 19 | 20 | if ($options->picHtmlPrint&&$options->JQlazyload) { 21 | $replacement = '$2$3'; 22 | } 23 | 24 | $content = preg_replace($pattern, $replacement, $content); 25 | return $content; 26 | } 27 | 28 | ?> 29 | need('header.php'); ?> 30 | 88 | 89 |
    90 |
    91 |
    92 |
    93 |
    94 |
    95 |

    友情链接

    96 |
    有朋自远方来,不亦乐乎?
    97 |
    98 |
    99 | content);?> 100 |
    101 |
    102 |
    103 | need('comments.php'); ?> 104 |
    105 |
    106 | need('sidebar.php'); ?> 107 |
    108 |
    109 |
    110 | 111 | need('footer.php'); ?> 112 | -------------------------------------------------------------------------------- /page_ friends_mini.php: -------------------------------------------------------------------------------- 1 | 8 | 9 | shortcode) { 14 | $content = do_shortcode($content); 15 | } 16 | 17 | $pattern = '/\]*>/i'; 18 | $replacement = '$2$3'; 19 | 20 | if ($options->picHtmlPrint&&$options->JQlazyload) { 21 | $replacement = '$2$3'; 22 | } 23 | 24 | $content = preg_replace($pattern, $replacement, $content); 25 | return $content; 26 | } 27 | 28 | ?> 29 | 30 | 31 | need('header.php'); ?> 32 | 79 | 80 |
    81 |
    82 |
    83 |
    84 |
    85 |
    86 |

    友情链接

    87 |
    有朋自远方来,不亦乐乎?
    88 |
    89 |
    90 | content);?> 91 |
    92 |
    93 |
    94 | need('comments.php'); ?> 95 |
    96 |
    97 | need('sidebar.php'); ?> 98 |
    99 |
    100 |
    101 | 102 | need('footer.php'); ?> 103 | -------------------------------------------------------------------------------- /page_articles.php: -------------------------------------------------------------------------------- 1 | 8 | 9 | need('header.php'); ?> 10 | 100 | 101 |
    102 |
    103 |
    104 |
    105 |
    106 |
    107 |
    很好! 目前共计to($stat)->publishedPostsNum(); ?>篇文章,继续加油呀~
    108 |
    109 |
    110 |
    111 | 112 | widget('Widget_Contents_Post_Recent', 'pageSize=10000')->to($archives); 113 | $year=0; $mon=0; $i=0; $j=0;$output=""; 114 | // while($archives->next()): 115 | // $year_tmp = date('Y',$archives->created); 116 | // $mon_tmp = date('m',$archives->created); 117 | // $y=$year; $m=$mon; 118 | // if ($mon != $mon_tmp && $mon > 0) $output .= '
  • '; 119 | // if ($year != $year_tmp && $year > 0) $output .= ''; 120 | // if ($year != $year_tmp) { 121 | // $year = $year_tmp; 122 | // // $output .= '

    '. $year .' 年

    '; //输出年份 123 | // } 124 | // if ($mon != $mon_tmp) { 125 | // $mon = $mon_tmp; 126 | // $output .= '

    '. $year .' 年 '. $mon .' 月

      '; //输出月份 127 | // } 128 | // //$output .= '
    • '.date('d日: ',$archives->created).''. $archives->title .''; 129 | // $output .= '
    • '. $archives->title .''; 130 | // $output .= ' ('.date('Y/m/d',$archives->created).')'; 131 | // //$output .= '('. $archives->commentsNum.'条评论)'; 132 | // $output .= '
    • '; //输出文章日期和标题 133 | // endwhile; 134 | // $output .= '
    '; 135 | while($archives->next()): 136 | $year_tmp = date('Y',$archives->created); 137 | $mon_tmp = date('m',$archives->created); 138 | $y=$year; $m=$mon; 139 | if ($year != $year_tmp) { 140 | $year = $year_tmp; 141 | $output .= '

    '. $year .'

    '; //输出年份 142 | } 143 | $output .= ''; 144 | endwhile; 145 | echo $output; 146 | ?> 147 |
    148 | 149 | 150 | 151 | need('sidebar.php'); ?> 152 | 153 | 154 | 155 | need('footer.php'); ?> 156 | -------------------------------------------------------------------------------- /page_sitemap.php: -------------------------------------------------------------------------------- 1 | 9 | fetchAll($db->select()->from('table.contents') 13 | ->where('table.contents.status = ?', 'publish') 14 | ->order('table.contents.created', Typecho_Db::SORT_DESC)); 15 | $is_txt=false; 16 | //搜索引擎限制sitemap文件最多有50,000条记录 17 | $list_num=50000; 18 | $sitemap_list = ""; 19 | //相对于其他页面的优先权 20 | $priority ="0.8"; 21 | //页面内容更新频率:always,hourly,daily,weekly,monthly,yearly,never 22 | $changefreq = "daily"; 23 | //增加纯文本地址列表 24 | if (isset($_GET['txt'])) {$is_txt=true;} 25 | 26 | //获取文章信息 27 | foreach($posts as $p){ 28 | /** 取出所有分类 */ 29 | $p['categories'] = $db->fetchAll($db 30 | ->select()->from('table.metas') 31 | ->join('table.relationships', 'table.relationships.mid = table.metas.mid') 32 | ->where('table.relationships.cid = ?', $p['cid']) 33 | ->where('table.metas.type = ?', 'category') 34 | ->order('table.metas.order', Typecho_Db::SORT_ASC)); 35 | 36 | /** 取出第一个分类作为slug条件 */ 37 | $p['category'] = current(Typecho_Common::arrayFlatten($p['categories'], 'slug')); 38 | //去掉附件 39 | $type = $p['type']; 40 | if($type == "post"){ 41 | $routeExists = (NULL != Typecho_Router::get($type)); 42 | $pathinfo = $routeExists ? Typecho_Router::url($type, $p) : '#'; 43 | $permalink = Typecho_Common::url($pathinfo, $options->index); 44 | if($is_txt){ 45 | $sitemap_list=$sitemap_list.$permalink . "\n\r
    "; 46 | }else { 47 | $sitemap_list=$sitemap_list."\t\n\t\t" . $permalink ."\n" 48 | . "\t\t" . date('Y-m-d\TH:i:s+08:00',$p['created']) . "\n" 49 | . "\t\t" . $changefreq . "\n" 50 | . "\t\t" . $priority . "\n" 51 | . "\t\n"; 52 | } 53 | $list_num--; 54 | if($list_num<=0){ 55 | break; 56 | } 57 | } 58 | } 59 | if(!$is_txt){ 60 | header("Content-Type: application/xml"); 61 | $sitemap_list ="\n \n" . $sitemap_list . ""; 62 | } 63 | echo $sitemap_list; 64 | ?> 65 | -------------------------------------------------------------------------------- /page_timeline.php: -------------------------------------------------------------------------------- 1 | 8 | 9 | need('header.php'); ?> 10 | 62 | 63 |
    64 |
    65 |
    66 |
    67 |
    68 |
    69 | 70 | content); ?> 71 |
    72 |
    73 | 74 |
    75 | need('comments.php'); ?> 76 |
    77 |
    78 | need('sidebar.php'); ?> 79 |
    80 |
    81 |
    82 | 83 | need('footer.php'); ?> 84 | -------------------------------------------------------------------------------- /post.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | modified; ?> 4 | need('header.php'); ?> 5 | 6 |
    7 |
    8 |
    9 |
    10 |
    11 | 12 |
    13 |

    title() ?>

    14 | 21 |
    22 |
    23 | 24 |
    25 | $halfyear): ?> 26 |
    27 | warning: 28 | 这篇文章距离上次修改已过天,其中的内容可能已经有所变动。 29 |
    30 | 31 | 32 | content); ?> 33 |
    34 | 35 | 36 |
    37 |
    38 | 39 | tags(' , ', true, 'none'); ?> 40 |
    41 |
    42 | 最后修改于:modified); ?> 43 |
    44 |
    45 |
    46 | 47 |
    48 |
      49 | thePrev('
    • %s
    • ','',['title'=>'上一篇','tagClass'=>'btn btn-default']); ?> 50 | theNext('
    • %s
    • ','',['title'=>'下一篇','tagClass'=>'btn btn-default']); ?> 51 |
    52 |
    53 | 54 |
    need('comments.php'); ?>
    55 |
    56 | 57 | need('sidebar.php'); ?> 58 | 59 |
    60 |
    61 |
    62 | 63 | need('footer.php'); ?> 64 | -------------------------------------------------------------------------------- /screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/screenshot.png -------------------------------------------------------------------------------- /shortcode.php: -------------------------------------------------------------------------------- 1 | info:' . $content . ''; 11 | } 12 | add_shortcode( 'info' , 'shortcode_panel_info' ); 13 | 14 | // 警告提示 15 | function shortcode_panel_warning( $atts, $content = '' ) { 16 | return '
    warning:' . $content . '
    '; 17 | } 18 | add_shortcode( 'warning' , 'shortcode_panel_warning' ); 19 | 20 | // 危险提示 21 | function shortcode_panel_danger( $atts, $content = '' ) { 22 | return '
    Error:' . $content . '
    '; 23 | } 24 | add_shortcode( 'danger' , 'shortcode_panel_danger' ); 25 | 26 | // 特别强调文字 27 | function shortcode_panel_em( $atts, $content = '' ) { 28 | return '
    ' . $content . '
    '; 29 | } 30 | add_shortcode( 'em' , 'shortcode_panel_em' ); 31 | 32 | // 高亮文字 33 | function shortcode_panel_hi( $atts, $content = '' ) { 34 | return '' . $content . ''; 35 | } 36 | add_shortcode( 'hi' , 'shortcode_panel_hi' ); 37 | 38 | // 不重要文字 39 | function shortcode_panel_lo( $atts, $content = '' ) { 40 | return '
    ' . $content . '
    '; 41 | } 42 | add_shortcode( 'lo' , 'shortcode_panel_lo' ); 43 | 44 | 45 | // 代办事项已完成 46 | function shortcode_panel_check( $atts, $content = '' ) { 47 | return ''; 48 | } 49 | add_shortcode( 'check' , 'shortcode_panel_check' ); 50 | 51 | // 代办事项未完成 52 | function shortcode_panel_uncheck( $atts, $content = '' ) { 53 | return ''; 54 | } 55 | add_shortcode( 'uncheck' , 'shortcode_panel_uncheck' ); 56 | 57 | // 音频播放 58 | function shortcode_audio( $atts, $content = '' ) { 59 | $args = shortcode_atts( array( 60 | 'src' => '', 61 | 'controls' => 'controls', 62 | 'preload' => 'metadata' 63 | ), $atts ); 64 | if (!empty($atts['autoplay'])) { 65 | $args['autoplay'] = 'autoplay'; 66 | } 67 | if (!empty($atts['loop'])) { 68 | $args['loop'] = 'loop'; 69 | } 70 | $attr_strings = array(); 71 | foreach ( $args as $k => $v ) { 72 | $attr_strings[] = $k . '="' . htmlspecialchars( $v, ENT_QUOTES, 'UTF-8' ) . '"'; 73 | } 74 | //$audio = sprintf( '', join( ' ', $attr_strings ), $content ); 75 | //return "
    {$audio}
    "; 76 | return sprintf( '', join( ' ', $attr_strings ), $content ); 77 | } 78 | add_shortcode( 'audio' , 'shortcode_audio' ); 79 | 80 | // 视频播放 81 | function shortcode_video( $atts, $content = '' ) { 82 | $args = shortcode_atts( array( 83 | 'src' => '', 84 | 'poster' => '', 85 | 'controls' => 'controls', 86 | 'preload' => 'metadata' 87 | 88 | ), $atts ); 89 | if (!empty($atts['autoplay'])) { 90 | $args['autoplay'] = 'autoplay'; 91 | } 92 | if (!empty($atts['loop'])) { 93 | $args['loop'] = 'loop'; 94 | } 95 | if (!empty($atts['muted'])) { 96 | $args['muted'] = 'muted'; 97 | } 98 | //默认播放器大小100% 99 | /*if (!empty($atts['width'])) { 100 | $args['width'] = $atts['width']; 101 | } 102 | if (!empty($atts['height'])) { 103 | $args['height'] = $atts['height']; 104 | }*/ 105 | $args['width'] ='100%'; 106 | $args['height'] ='100%'; 107 | $attr_strings = array(); 108 | foreach ( $args as $k => $v ) { 109 | $attr_strings[] = $k . '="' . htmlspecialchars( $v, ENT_QUOTES, 'UTF-8' ) . '"'; 110 | } 111 | return sprintf( '', join( ' ', $attr_strings ), $content ); 112 | } 113 | add_shortcode( 'video' , 'shortcode_video' ); 114 | 115 | //收缩框 116 | function shortcode_shrinks( $atts, $content = '' ) { 117 | $args = shortcode_atts( array( 118 | 'title' => '', 119 | 'style' => 'default' 120 | 121 | ), $atts ); 122 | if (!empty($atts['checked'])) { 123 | $args['checked'] = 'active'; 124 | } 125 | $attr_strings = array(); 126 | foreach ( $args as $k => $v ) { 127 | $attr_strings[] = $k . '="' . htmlspecialchars( $v, ENT_QUOTES, 'UTF-8' ) . '"'; 128 | } 129 | return '
    130 |
    '.$args['title'].'
    '.$content.'
    '; 131 | } 132 | add_shortcode( 'shrinks' , 'shortcode_shrinks' ); 133 | 134 | 135 | //简易提示框 136 | function shortcode_alert( $atts, $content = '' ) { 137 | $closebutton=''; 138 | $args = shortcode_atts( array( 139 | 'style' => 'success' 140 | 141 | ), $atts ); 142 | if (!empty($atts['close'])) { 143 | $args['close'] = 'alert-dismissible'; 144 | $closebutton = ''; 145 | } 146 | $attr_strings = array(); 147 | foreach ( $args as $k => $v ) { 148 | $attr_strings[] = $k . '="' . htmlspecialchars( $v, ENT_QUOTES, 'UTF-8' ) . '"'; 149 | } 150 | return ''; 151 | } 152 | add_shortcode( 'alert' , 'shortcode_alert' ); 153 | -------------------------------------------------------------------------------- /sidebar.php: -------------------------------------------------------------------------------- 1 | 2 | 221 | -------------------------------------------------------------------------------- /waxy_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dingzd1995/typecho-theme-waxy/948f0baeacc91f33bc4ca6a9be6847e9499ed5d6/waxy_logo.png --------------------------------------------------------------------------------