Commit 28611056 authored by Liang Ding's avatar Liang Ding

Merge branch '2.9.1-dev'

parents 0fed47eb 36ec7415
...@@ -26,6 +26,19 @@ ...@@ -26,6 +26,19 @@
</style> </style>
</head> </head>
<body> <body>
<h2>Release 2.9.1 - Jun 27, 2018</h2>
<ul>
<li><a href="https://github.com/b3log/solo/issues/12451">12451 支持 Chrome 地址栏 tab 键进行搜索</a>&nbsp;<span
style='background: #02e10c !important;color:#FFFFFF !important;padding: 1px 4px;'>feature</span></li>
<li><a href="https://github.com/b3log/solo/issues/12459">12459 支持 PJAX</a>&nbsp;<span
style='background: #02e10c !important;color:#FFFFFF !important;padding: 1px 4px;'>feature</span></li>
<li><a href="https://github.com/b3log/solo/issues/12458">12458 统一使用服务端上传</a>&nbsp;<span
style='background: #84b6eb !important;color:#FFFFFF !important;padding: 1px 4px;'>enhancement</span></li>
<li><a href="https://github.com/b3log/solo/issues/12454">12454 开源协议从 APLv2 变更为 AGPLv3</a>&nbsp;<span
style='background: #e102d8 !important;color:#FFFFFF !important;padding: 1px 4px;'>development</span></li>
<li><a href="https://github.com/b3log/solo/issues/12448">12448 Feed/Sitemap 转义报错</a>&nbsp;<span
style='background: #fc2929 !important;color:#FFFFFF !important;padding: 1px 4px;'>bug</span></li>
</ul>
<h2>Release 2.9.0 - May 17, 2018</h2> <h2>Release 2.9.0 - May 17, 2018</h2>
<ul> <ul>
<li><a href="https://github.com/b3log/solo/issues/12412">12412 后台文章管理增加搜索的功能</a>&nbsp;<span <li><a href="https://github.com/b3log/solo/issues/12412">12412 后台文章管理增加搜索的功能</a>&nbsp;<span
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- <!--
Description: Solo POM. Description: Solo POM.
Version: 3.18.3.8, May 17, 2018 Version: 3.18.3.9, Jun 27, 2018
Author: <a href="http://88250.b3log.org">Liang Ding</a> Author: <a href="http://88250.b3log.org">Liang Ding</a>
Author: <a href="http://www.annpeter.cn">Ann Peter</a> Author: <a href="http://www.annpeter.cn">Ann Peter</a>
Author: <a href="http://vanessa.b3log.org">Vanessa</a> Author: <a href="http://vanessa.b3log.org">Vanessa</a>
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<artifactId>solo</artifactId> <artifactId>solo</artifactId>
<packaging>war</packaging> <packaging>war</packaging>
<name>Solo</name> <name>Solo</name>
<version>2.9.0</version> <version>2.9.1</version>
<description> <description>
A blogging system written in Java, feel free to create your or your team own blog. A blogging system written in Java, feel free to create your or your team own blog.
一个用 Java 实现的博客系统,为你或你的团队创建个博客吧! 一个用 Java 实现的博客系统,为你或你的团队创建个博客吧!
...@@ -362,14 +362,12 @@ ...@@ -362,14 +362,12 @@
<encoding>UTF-8</encoding> <encoding>UTF-8</encoding>
</configuration> </configuration>
<executions> <executions>
<!--
<execution> <execution>
<phase>generate-sources</phase> <phase>generate-sources</phase>
<goals> <goals>
<goal>format</goal> <goal>format</goal>
</goals> </goals>
</execution> </execution>
-->
</executions> </executions>
</plugin> </plugin>
...@@ -413,14 +411,12 @@ ...@@ -413,14 +411,12 @@
<jsTargetDir>src/main/webapp/js</jsTargetDir> <jsTargetDir>src/main/webapp/js</jsTargetDir>
</configuration> </configuration>
<executions> <executions>
<!--
<execution> <execution>
<phase>process-resources</phase> <phase>process-resources</phase>
<goals> <goals>
<goal>min</goal> <goal>min</goal>
</goals> </goals>
</execution> </execution>
-->
</executions> </executions>
</plugin> </plugin>
......
...@@ -61,7 +61,7 @@ import java.util.concurrent.locks.ReentrantLock; ...@@ -61,7 +61,7 @@ import java.util.concurrent.locks.ReentrantLock;
* Solo Servlet listener. * Solo Servlet listener.
* *
* @author <a href="http://88250.b3log.org">Liang Ding</a> * @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.9.3.32, May 17, 2018 * @version 1.9.3.33, Jun 27, 2018
* @since 0.3.1 * @since 0.3.1
*/ */
public final class SoloServletListener extends AbstractServletListener { public final class SoloServletListener extends AbstractServletListener {
...@@ -74,7 +74,7 @@ public final class SoloServletListener extends AbstractServletListener { ...@@ -74,7 +74,7 @@ public final class SoloServletListener extends AbstractServletListener {
/** /**
* Solo version. * Solo version.
*/ */
public static final String VERSION = "2.9.0"; public static final String VERSION = "2.9.1";
/** /**
* Bean manager. * Bean manager.
......
...@@ -54,7 +54,7 @@ import java.sql.Statement; ...@@ -54,7 +54,7 @@ import java.sql.Statement;
* *
* @author <a href="http://88250.b3log.org">Liang Ding</a> * @author <a href="http://88250.b3log.org">Liang Ding</a>
* @author <a href="mailto:dongxu.wang@acm.org">Dongxu Wang</a> * @author <a href="mailto:dongxu.wang@acm.org">Dongxu Wang</a>
* @version 1.2.0.25, May 17, 2018 * @version 1.2.0.26, Jun 27, 2018
* @since 1.2.0 * @since 1.2.0
*/ */
@Service @Service
...@@ -78,7 +78,7 @@ public class UpgradeService { ...@@ -78,7 +78,7 @@ public class UpgradeService {
/** /**
* Old version. * Old version.
*/ */
private static final String FROM_VER = "2.8.0"; private static final String FROM_VER = "2.9.0";
/** /**
* New version. * New version.
......
...@@ -26,6 +26,19 @@ ...@@ -26,6 +26,19 @@
</style> </style>
</head> </head>
<body> <body>
<h2>Release 2.9.1 - Jun 27, 2018</h2>
<ul>
<li><a href="https://github.com/b3log/solo/issues/12451">12451 支持 Chrome 地址栏 tab 键进行搜索</a>&nbsp;<span
style='background: #02e10c !important;color:#FFFFFF !important;padding: 1px 4px;'>feature</span></li>
<li><a href="https://github.com/b3log/solo/issues/12459">12459 支持 PJAX</a>&nbsp;<span
style='background: #02e10c !important;color:#FFFFFF !important;padding: 1px 4px;'>feature</span></li>
<li><a href="https://github.com/b3log/solo/issues/12458">12458 统一使用服务端上传</a>&nbsp;<span
style='background: #84b6eb !important;color:#FFFFFF !important;padding: 1px 4px;'>enhancement</span></li>
<li><a href="https://github.com/b3log/solo/issues/12454">12454 开源协议从 APLv2 变更为 AGPLv3</a>&nbsp;<span
style='background: #e102d8 !important;color:#FFFFFF !important;padding: 1px 4px;'>development</span></li>
<li><a href="https://github.com/b3log/solo/issues/12448">12448 Feed/Sitemap 转义报错</a>&nbsp;<span
style='background: #fc2929 !important;color:#FFFFFF !important;padding: 1px 4px;'>bug</span></li>
</ul>
<h2>Release 2.9.0 - May 17, 2018</h2> <h2>Release 2.9.0 - May 17, 2018</h2>
<ul> <ul>
<li><a href="https://github.com/b3log/solo/issues/12412">12412 后台文章管理增加搜索的功能</a>&nbsp;<span <li><a href="https://github.com/b3log/solo/issues/12412">12412 后台文章管理增加搜索的功能</a>&nbsp;<span
......
This diff is collapsed.
/**
* Solo - A beautiful, simple, stable, fast Java blogging system.
* Copyright (c) 2010-2018, b3log.org & hacpai.com
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
html,body,div,ul,li,h1,h2,h3,h4,h5,h6,p,dd,dl,ol{margin:0;padding:0}body{background-color:#FFF;color:#000;font-family:elvetica,Arial,'sans-serif','\5fae\8f6f\96c5\9ed1';font-size:small}img{border:medium none;margin:0;padding:0;vertical-align:middle}h1{font-size:160%}h2{font-size:140%}h3{font-size:120%}h4{font-size:110%}textarea{overflow:auto}button,.button{background:url(../images/icon.png) repeat center bottom;border:1px solid;border-color:#CCC #bbb #a0a0a0;border-radius:4px;height:28px;margin:0;padding:0 6px;vertical-align:top}button:hover,.button:hover{border-color:#BBB}.padding12{padding:12px}.paddingBottom12{padding-bottom:12px !important}.paddingTop12{padding-top:12px !important}.margin12{margin:12px}.marginTop12{margin-top:12px !important}.marginBottom12{margin-bottom:12px !important}.marginLeft12{margin-left:12px !important}.marginLeft6{margin-left:6px !important}.marginRight12{margin-right:12px !important}.f-bold{font-weight:bold !important}.nowrap{white-space:nowrap}.left{float:left}.right{float:right}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.fn-clear:before,.fn-clear:after{display:table;content:""}.fn-clear:after{clear:both}.fn__flex{display:flex}.fn__flex1{flex:1;min-width:1px}.none{display:none}.pointer{cursor:pointer}.no-underline{text-decoration:none !important}.red{color:red}.contentBody{margin-bottom:12px;padding:3px 12px}.form th{text-align:right;white-space:nowrap}.form input[type='text'],.form input[type='password'],.form textarea{border-color:#c0c0c0 #d9d9d9 #d9d9d9;border-right:1px solid #d9d9d9;border-style:solid;border-width:1px;font-family:Helvetica,Arial,sans-serif;font-size:12px;outline:medium none;width:99%;padding:0 3px}.form input{height:24px}.form input[type='checkbox']{border:0;vertical-align:sub;height:20px}.form input.normalInput{width:auto}.form input[type='checkbox']:focus{border:0;box-shadow:0}.form input:focus,.form textarea:focus{box-shadow:0 1px 2px rgba(0,0,0,0.3) inset}.form textarea{padding:3px;overflow:auto;resize:vertical}.logo{padding:0 5px;text-decoration:none;text-shadow:0 0 1px #eee}.putTopIcon,.notPutTopIcon,.deleteIcon,.updateIcon,.commentIcon,.homeIcon,.adminIcon,.loginIcon,.logoutIcon,.calendarIcon,.browserIcon,.postIcon,.articlesIcon,.draftsIcon,.usersIcon,.linkIcon,.preferenceIcon,.pageIcon,.trueIcon,.falseIcon,.fileIcon,.othersIcon,.goTopIcon,.goBottomIcon,.cacheIcon,.aboutIcon{background-image:url("../images/icon.png");cursor:pointer;height:16px;width:16px}.adminIcon,.loginIcon,.logoutIcon,.homeIcon{margin-top:3px}.pageIcon{background-position:-144px 0}.postIcon{background-position:-16px 0}.linkIcon{background-position:-32px 0}.preferenceIcon{background-position:-48px 0}.articlesIcon{background-position:-64px 0}.trueIcon{background-position:-80px 0;cursor:auto}.falseIcon{background-position:-96px 0;cursor:auto}.fileIcon{background-position:-112px 0}.deleteIcon{background-position:0 -16px}.updateIcon{background-position:-16px -16px}.commentIcon{background-position:-32px -16px}.homeIcon{background-position:-64px -16px}.adminIcon{background-position:-80px -16px}.logoutIcon{background-position:-96px -16px}.loginIcon{background-position:-112px -16px}.browserIcon{background-position:-128px -16px}.calendarIcon{background-position:-144px -16px}.putTopIcon{background-position:-16px -32px;float:left}.notPutTopIcon{background-position:-32px -32px;float:left}.othersIcon{background-position:-48px -32px}.cacheIcon{background-position:-96px -32px}.draftsIcon{background-position:-96px -32px}.usersIcon{background-position:-112px -32px}.goTopIcon{background-position:-64px -32px;position:fixed;right:20px;top:45%}.goBottomIcon{background-position:-80px -32px;bottom:40%;position:fixed;right:20px}.article-body{overflow:hidden;line-height:145%;word-wrap:break-word}.article-body blockquote{border:1px dotted #98a47f;font-style:italic;margin:12px;padding:12px}.article-body h1{font-size:2em;margin:.67em 0}.article-body h2{font-size:1.5em;margin:.75em 0}.article-body h3{font-size:1.17em;margin:.83em 0}.article-body h4,.article-body p,.article-body blockquote,.article-body ul,.article-body fieldset,.article-body form,.article-body ol,.article-body dl,.article-body dir,.article-body menu{margin:1.12em 0}.article-body h5{font-size:.83em;margin:1.5em 0}.article-body h6{font-size:.75em;margin:1.67em 0}.article-body blockquote{margin-left:40px;margin-right:40px}.article-body ol,.article-body ul,.article-body dir,.article-body menu,.article-body dd{margin-left:40px}.em00,.em01,.em02,.em03,.em04,.em05,.em06,.em07,.em08,.em09,.em10,.em11,.em12,.em13,.em14{background-image:url("../images/emotions/emotions.png");background-size:120px;float:left;height:24px;margin-right:5px;width:24px}#emotions span{cursor:pointer}.em01{background-position:-24px 0}.em02{background-position:-48px 0}.em03{background-position:-72px 0}.em04{background-position:-96px 0}.em05{background-position:0 -24px}.em06{background-position:-24px -24px}.em07{background-position:-48px -24px}.em08{background-position:-72px -24px}.em09{background-position:-96px -24px}.em10{background-position:0 -48px}.em11{background-position:-24px -48px}.em12{background-position:-48px -48px}.em13{background-position:-72px -48px}.em14{background-position:-96px -48px}#tags{list-style:none}#tags li{float:left;list-style:none;height:38px}#tags a:hover{text-shadow:0 0 2px #555}#tags a{border-radius:3px 3px 3px 3px;box-shadow:1px 1px 3px #555;float:left;margin:3px 6px;padding:3px 12px;text-decoration:none}#tags .tags1{font-size:12px;font-weight:normal}#tags .tags2{font-size:14px;font-weight:normal}#tags .tags3{font-size:16px;font-weight:normal}#tags .tags4{font-size:18px;font-weight:bold}#tags .tags5{font-size:20px;font-weight:bold}#captcha,#captchaReply{cursor:pointer} html,body,div,ul,li,h1,h2,h3,h4,h5,h6,p,dd,dl,ol{margin:0;padding:0}body{background-color:#FFF;color:#000;font-family:elvetica,Arial,'sans-serif','\5fae\8f6f\96c5\9ed1';font-size:small}img{border:medium none;margin:0;padding:0;vertical-align:middle}h1{font-size:160%}h2{font-size:140%}h3{font-size:120%}h4{font-size:110%}textarea{overflow:auto}button,.button{background:url(../images/icon.png) repeat center bottom;border:1px solid;border-color:#CCC #bbb #a0a0a0;border-radius:4px;height:28px;margin:0;padding:0 6px;vertical-align:top}button:hover,.button:hover{border-color:#BBB}.padding12{padding:12px}.paddingBottom12{padding-bottom:12px !important}.paddingTop12{padding-top:12px !important}.margin12{margin:12px}.marginTop12{margin-top:12px !important}.marginBottom12{margin-bottom:12px !important}.marginLeft12{margin-left:12px !important}.marginLeft6{margin-left:6px !important}.marginRight12{margin-right:12px !important}.f-bold{font-weight:bold !important}.nowrap{white-space:nowrap}.left{float:left}.right{float:right}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.fn-clear:before,.fn-clear:after{display:table;content:""}.fn-clear:after{clear:both}.fn__flex{display:flex}.fn__flex1{flex:1;min-width:1px}.none{display:none}.pointer{cursor:pointer}.no-underline{text-decoration:none !important}.red{color:red}.contentBody{margin-bottom:12px;padding:3px 12px}.form th{text-align:right;white-space:nowrap}.form input[type='text'],.form input[type='password'],.form textarea{border-color:#c0c0c0 #d9d9d9 #d9d9d9;border-right:1px solid #d9d9d9;border-style:solid;border-width:1px;font-family:Helvetica,Arial,sans-serif;font-size:12px;outline:medium none;width:99%;padding:0 3px}.form input{height:24px}.form input[type='checkbox']{border:0;vertical-align:sub;height:20px}.form input.normalInput{width:auto}.form input[type='checkbox']:focus{border:0;box-shadow:0}.form input:focus,.form textarea:focus{box-shadow:0 1px 2px rgba(0,0,0,0.3) inset}.form textarea{padding:3px;overflow:auto;resize:vertical}.logo{padding:0 5px;text-decoration:none;text-shadow:0 0 1px #eee}.putTopIcon,.notPutTopIcon,.deleteIcon,.updateIcon,.commentIcon,.homeIcon,.adminIcon,.loginIcon,.logoutIcon,.calendarIcon,.browserIcon,.postIcon,.articlesIcon,.draftsIcon,.usersIcon,.linkIcon,.preferenceIcon,.pageIcon,.trueIcon,.falseIcon,.fileIcon,.othersIcon,.goTopIcon,.goBottomIcon,.cacheIcon,.aboutIcon{background-image:url("../images/icon.png");cursor:pointer;height:16px;width:16px}.adminIcon,.loginIcon,.logoutIcon,.homeIcon{margin-top:3px}.pageIcon{background-position:-144px 0}.postIcon{background-position:-16px 0}.linkIcon{background-position:-32px 0}.preferenceIcon{background-position:-48px 0}.articlesIcon{background-position:-64px 0}.trueIcon{background-position:-80px 0;cursor:auto}.falseIcon{background-position:-96px 0;cursor:auto}.fileIcon{background-position:-112px 0}.deleteIcon{background-position:0 -16px}.updateIcon{background-position:-16px -16px}.commentIcon{background-position:-32px -16px}.homeIcon{background-position:-64px -16px}.adminIcon{background-position:-80px -16px}.logoutIcon{background-position:-96px -16px}.loginIcon{background-position:-112px -16px}.browserIcon{background-position:-128px -16px}.calendarIcon{background-position:-144px -16px}.putTopIcon{background-position:-16px -32px;float:left}.notPutTopIcon{background-position:-32px -32px;float:left}.othersIcon{background-position:-48px -32px}.cacheIcon{background-position:-96px -32px}.draftsIcon{background-position:-96px -32px}.usersIcon{background-position:-112px -32px}.goTopIcon{background-position:-64px -32px;position:fixed;right:20px;top:45%}.goBottomIcon{background-position:-80px -32px;bottom:40%;position:fixed;right:20px}.article-body{overflow:hidden;line-height:145%;word-wrap:break-word}.article-body blockquote{border:1px dotted #98a47f;font-style:italic;margin:12px;padding:12px}.article-body h1{font-size:2em;margin:.67em 0}.article-body h2{font-size:1.5em;margin:.75em 0}.article-body h3{font-size:1.17em;margin:.83em 0}.article-body h4,.article-body p,.article-body blockquote,.article-body ul,.article-body fieldset,.article-body form,.article-body ol,.article-body dl,.article-body dir,.article-body menu{margin:1.12em 0}.article-body h5{font-size:.83em;margin:1.5em 0}.article-body h6{font-size:.75em;margin:1.67em 0}.article-body blockquote{margin-left:40px;margin-right:40px}.article-body ol,.article-body ul,.article-body dir,.article-body menu,.article-body dd{margin-left:40px}.em00,.em01,.em02,.em03,.em04,.em05,.em06,.em07,.em08,.em09,.em10,.em11,.em12,.em13,.em14{background-image:url("../images/emotions/emotions.png");background-size:120px;float:left;height:24px;margin-right:5px;width:24px}#emotions span{cursor:pointer}.em01{background-position:-24px 0}.em02{background-position:-48px 0}.em03{background-position:-72px 0}.em04{background-position:-96px 0}.em05{background-position:0 -24px}.em06{background-position:-24px -24px}.em07{background-position:-48px -24px}.em08{background-position:-72px -24px}.em09{background-position:-96px -24px}.em10{background-position:0 -48px}.em11{background-position:-24px -48px}.em12{background-position:-48px -48px}.em13{background-position:-72px -48px}.em14{background-position:-96px -48px}#tags{list-style:none}#tags li{float:left;list-style:none;height:38px}#tags a:hover{text-shadow:0 0 2px #555}#tags a{border-radius:3px 3px 3px 3px;box-shadow:1px 1px 3px #555;float:left;margin:3px 6px;padding:3px 12px;text-decoration:none}#tags .tags1{font-size:12px;font-weight:normal}#tags .tags2{font-size:14px;font-weight:normal}#tags .tags3{font-size:16px;font-weight:normal}#tags .tags4{font-size:18px;font-weight:bold}#tags .tags5{font-size:20px;font-weight:bold}#captcha,#captchaReply{cursor:pointer}
\ No newline at end of file
/**
* Solo - A beautiful, simple, stable, fast Java blogging system.
* Copyright (c) 2010-2018, b3log.org & hacpai.com
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
html,body{margin:0;padding:0}body{background-color:#fff;color:#333;font-family:\5fae\8f6f\96c5\9ed1;font-size:small;height:100%}h2{background-color:#f3f1e5;border-radius:4px 4px 0 0;font-size:16px;margin:0;padding:10px 20px;text-shadow:0 -1px 0 rgba(255,255,255,0.5)}input{border:1px solid #ccc;border-radius:3px 3px 3px 3px;box-shadow:0 1px 2px rgba(0,0,0,0.075) inset;font-size:13px;margin:15px 0;padding:7px 8px;vertical-align:middle;width:410px;font-family:\5fae\8f6f\96c5\9ed1;font-size:small}input:focus{box-shadow:0 1px 2px rgba(0,0,0,0.075) inset,0 0 5px rgbargba(200,200,200,0.9);border:1px solid #e6e5d9}.form{padding:20px}label{font-size:13px}button{position:relative;display:inline-block;font-size:13px;font-weight:700;color:#333;text-shadow:0 1px 0 rgba(255,255,255,0.9);white-space:nowrap;background-color:#eaeaea;background-image:linear-gradient(#fafafa,#eaeaea);background-repeat:repeat-x;border-radius:3px;border:1px solid #ddd;border-bottom-color:#c5c5c5;box-shadow:0 1px 3px rgba(0,0,0,0.075);vertical-align:baseline;cursor:pointer;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;outline:0;padding:7px 15px;margin-top:10px}button:hover,button:active{color:#fff;text-decoration:none;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#3072b3;background-image:linear-gradient(#599bcd,#3072b3);background-repeat:repeat-x}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.fn-clear:before,.fn-clear:after{display:table;content:""}.fn-clear:after{clear:both}.fn-left{float:left}.fn-right{float:right}.none{display:none}.solo{color:orangered;font-weight:bold}.logo{float:left;padding:142px 12px 0;width:217px;text-align:center}.wrap{border-top:5px solid #e6e5d9;padding:110px 0;background-color:#f3f1e5}.content{background-color:#fff;margin:0 auto;width:760px}.main{border-left:1px solid #e6e5d9;float:right;font-size:15px;padding:20px;width:470px;min-height:360px}.main a{text-decoration:none}.main li{margin:6px 0 6px 16px}.footerWrapper{background-color:#fff;border-top:1px solid #e6e5d9;padding:12px 0;text-align:center}.footerWrapper a{text-decoration:none}.article-pwd>div,.article-pwd>form{margin:0 20px}.article-pwd>div{margin-bottom:10px;max-height:264px;overflow:auto;word-wrap:break-word}.a-error{text-align:right}.img-error{max-width:100%;margin:20px auto;padding:0;display:block}.kill img{position:absolute;right:40px;top:200px}.kill ul{margin-bottom:50px}.kill p{margin:12px 20px}.kill span{margin-left:20px}#init{position:absolute;width:470px}#init input,.register input{margin:5px 0;padding:5px 8px}.register{height:400px}#sys p{height:206px}#sys{padding:0 20px}#initButton{margin-right:10px}#tip{color:#21759b;font-weight:bold;margin-left:10px}.content-reset{font-family:"Helvetica Neue","Luxi Sans","DejaVu Sans",Tahoma,"Hiragino Sans GB","Microsoft Yahei",sans-serif;word-wrap:break-word;overflow:auto;line-height:1.5;font-size:13px;word-break:break-all;color:#545454}.content-reset ul,.content-reset ol{padding-left:2em;margin-top:0;margin-bottom:16px}.content-reset li{margin-top:.25em}.content-reset h1,.content-reset h2,.content-reset h3,.content-reset h4,.content-reset h5,.content-reset h6{margin-top:24px;margin-bottom:16px;font-weight:600;line-height:1.25}.content-reset h1{padding-bottom:.3em;font-size:2em;border-bottom:1px solid #eee}.content-reset h2{padding-bottom:.3em;font-size:1.5em;border-bottom:1px solid #eee}.content-reset h3{font-size:1.25em}.content-reset h4{font-size:1em}.content-reset h5{font-size:.875em}.content-reset h6{font-size:.85em}.content-reset hr{height:2px;padding:0;margin:5px 0;background-color:#e7e7e7;border:0}.content-reset p{margin-top:0;margin-bottom:0}.content-reset blockquote{padding:0 1em;color:#777;border-left:.25em solid #ddd;margin-bottom:16px}.content-reset blockquote p{margin:0}.content-reset iframe{border:1px solid #ccc}.content-reset table{width:100%;border:1px solid #dedede;margin:15px auto;border-collapse:collapse;empty-cells:show}.content-reset thead{text-align:center}.content-reset td,.content-reset th{height:35px;border:1px solid #dedede;padding:0 10px}.content-reset th{font-weight:bold;text-align:center !important;background:rgba(158,188,226,0.2)}.content-reset tbody tr:nth-child(2n){background:rgba(158,188,226,0.12)}.content-reset tr:hover{background:#efefef}.content-reset code{padding:.2em .4em;margin:0;font-size:85%;background-color:rgba(252,41,41,0.12);border-radius:3px;color:#d23f31;font-family:mononoki,Consolas,"Liberation Mono",Menlo,Courier,monospace}.content-reset pre>code{padding:.5em;border-radius:0;color:#333;background-color:rgba(0,0,0,0.04);background-size:20px 20px;border-radius:5px}.content-reset kbd{display:inline-block;padding:3px 5px;font:11px Consolas,"Liberation Mono",Menlo,Courier,monospace;line-height:10px;color:#555;vertical-align:middle;background-color:#fcfcfc;border:solid 1px #ccc;border-bottom-color:#bbb;border-radius:3px;box-shadow:inset 0 -1px 0 #bbb}.search{border-top:5px solid #e6e5d9;background-color:#f3f1e5;padding:20px 0 20px 84px;min-height:480px}.search__header{margin:20px}.search__header a{line-height:44px}.search__input input{margin:0 10px 0 20px;height:32px;line-height:32px;float:left;font-size:16px;padding:5px 10px}.search__input button{height:44px;margin:0;float:left}.search__articles{width:600px}.search__articles header h1{margin:0}.search__articles header h1>a{font-size:18px;text-decoration:none;font-weight:normal}.search__articles .meta{font-size:14px;color:#999}.search__articles footer{margin-bottom:30px}.search__articles footer a{text-decoration:none;font-size:13px}.search__articles footer a:hover,.search__articles header h1>a:hover,.search__pagination a:hover{text-decoration:underline}.search__pagination a{color:#4285f4;text-decoration:none}.search__pagination a,.search__pagination span{margin-right:5px}@media(max-width:780px){.wrap{padding:40px 0}.content{width:auto}.logo,.search__header img,.search__header>.fn-right{display:none}.main{border:0;float:none;width:auto}input{width:100%;box-sizing:border-box;display:block}.a-500,.a-403,.a-404{margin:0 20px 0 0}#init{width:100%;padding:0 20px;box-sizing:border-box;left:0}.search__input{float:none}.search__input input{margin:0}.search__input button{position:absolute;right:20px;height:32px;line-height:16px}.search{padding:20px;width:100%;min-height:auto;box-sizing:border-box}.search__articles{width:auto}} html,body{margin:0;padding:0}body{background-color:#fff;color:#333;font-family:\5fae\8f6f\96c5\9ed1;font-size:small;height:100%}h2{background-color:#f3f1e5;border-radius:4px 4px 0 0;font-size:16px;margin:0;padding:10px 20px;text-shadow:0 -1px 0 rgba(255,255,255,0.5)}input{border:1px solid #ccc;border-radius:3px 3px 3px 3px;box-shadow:0 1px 2px rgba(0,0,0,0.075) inset;font-size:13px;margin:15px 0;padding:7px 8px;vertical-align:middle;width:410px;font-family:\5fae\8f6f\96c5\9ed1;font-size:small}input:focus{box-shadow:0 1px 2px rgba(0,0,0,0.075) inset,0 0 5px rgbargba(200,200,200,0.9);border:1px solid #e6e5d9}.form{padding:20px}label{font-size:13px}button{position:relative;display:inline-block;font-size:13px;font-weight:700;color:#333;text-shadow:0 1px 0 rgba(255,255,255,0.9);white-space:nowrap;background-color:#eaeaea;background-image:linear-gradient(#fafafa,#eaeaea);background-repeat:repeat-x;border-radius:3px;border:1px solid #ddd;border-bottom-color:#c5c5c5;box-shadow:0 1px 3px rgba(0,0,0,0.075);vertical-align:baseline;cursor:pointer;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;outline:0;padding:7px 15px;margin-top:10px}button:hover,button:active{color:#fff;text-decoration:none;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#3072b3;background-image:linear-gradient(#599bcd,#3072b3);background-repeat:repeat-x}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.fn-clear:before,.fn-clear:after{display:table;content:""}.fn-clear:after{clear:both}.fn-left{float:left}.fn-right{float:right}.none{display:none}.solo{color:orangered;font-weight:bold}.logo{float:left;padding:142px 12px 0;width:217px;text-align:center}.wrap{border-top:5px solid #e6e5d9;padding:110px 0;background-color:#f3f1e5}.content{background-color:#fff;margin:0 auto;width:760px}.main{border-left:1px solid #e6e5d9;float:right;font-size:15px;padding:20px;width:470px;min-height:360px}.main a{text-decoration:none}.main li{margin:6px 0 6px 16px}.footerWrapper{background-color:#fff;border-top:1px solid #e6e5d9;padding:12px 0;text-align:center}.footerWrapper a{text-decoration:none}.article-pwd>div,.article-pwd>form{margin:0 20px}.article-pwd>div{margin-bottom:10px;max-height:264px;overflow:auto;word-wrap:break-word}.a-error{text-align:right}.img-error{max-width:100%;margin:20px auto;padding:0;display:block}.kill img{position:absolute;right:40px;top:200px}.kill ul{margin-bottom:50px}.kill p{margin:12px 20px}.kill span{margin-left:20px}#init{position:absolute;width:470px}#init input,.register input{margin:5px 0;padding:5px 8px}.register{height:400px}#sys p{height:206px}#sys{padding:0 20px}#initButton{margin-right:10px}#tip{color:#21759b;font-weight:bold;margin-left:10px}.content-reset{font-family:"Helvetica Neue","Luxi Sans","DejaVu Sans",Tahoma,"Hiragino Sans GB","Microsoft Yahei",sans-serif;word-wrap:break-word;overflow:auto;line-height:1.5;font-size:13px;word-break:break-all;color:#545454}.content-reset ul,.content-reset ol{padding-left:2em;margin-top:0;margin-bottom:16px}.content-reset li{margin-top:.25em}.content-reset h1,.content-reset h2,.content-reset h3,.content-reset h4,.content-reset h5,.content-reset h6{margin-top:24px;margin-bottom:16px;font-weight:600;line-height:1.25}.content-reset h1{padding-bottom:.3em;font-size:2em;border-bottom:1px solid #eee}.content-reset h2{padding-bottom:.3em;font-size:1.5em;border-bottom:1px solid #eee}.content-reset h3{font-size:1.25em}.content-reset h4{font-size:1em}.content-reset h5{font-size:.875em}.content-reset h6{font-size:.85em}.content-reset hr{height:2px;padding:0;margin:5px 0;background-color:#e7e7e7;border:0}.content-reset p{margin-top:0;margin-bottom:0}.content-reset blockquote{padding:0 1em;color:#777;border-left:.25em solid #ddd;margin-bottom:16px}.content-reset blockquote p{margin:0}.content-reset iframe{border:1px solid #ccc}.content-reset table{width:100%;border:1px solid #dedede;margin:15px auto;border-collapse:collapse;empty-cells:show}.content-reset thead{text-align:center}.content-reset td,.content-reset th{height:35px;border:1px solid #dedede;padding:0 10px}.content-reset th{font-weight:bold;text-align:center !important;background:rgba(158,188,226,0.2)}.content-reset tbody tr:nth-child(2n){background:rgba(158,188,226,0.12)}.content-reset tr:hover{background:#efefef}.content-reset code{padding:.2em .4em;margin:0;font-size:85%;background-color:rgba(252,41,41,0.12);border-radius:3px;color:#d23f31;font-family:mononoki,Consolas,"Liberation Mono",Menlo,Courier,monospace}.content-reset pre>code{padding:.5em;border-radius:0;color:#333;background-color:rgba(0,0,0,0.04);background-size:20px 20px;border-radius:5px}.content-reset kbd{display:inline-block;padding:3px 5px;font:11px Consolas,"Liberation Mono",Menlo,Courier,monospace;line-height:10px;color:#555;vertical-align:middle;background-color:#fcfcfc;border:solid 1px #ccc;border-bottom-color:#bbb;border-radius:3px;box-shadow:inset 0 -1px 0 #bbb}.search{border-top:5px solid #e6e5d9;background-color:#f3f1e5;padding:20px 0 20px 84px;min-height:480px}.search__header{margin:20px}.search__header a{line-height:44px}.search__input input{margin:0 10px 0 20px;height:32px;line-height:32px;float:left;font-size:16px;padding:5px 10px}.search__input button{height:44px;margin:0;float:left}.search__articles{width:600px}.search__articles header h1{margin:0}.search__articles header h1>a{font-size:18px;text-decoration:none;font-weight:normal}.search__articles .meta{font-size:14px;color:#999}.search__articles footer{margin-bottom:30px}.search__articles footer a{text-decoration:none;font-size:13px}.search__articles footer a:hover,.search__articles header h1>a:hover,.search__pagination a:hover{text-decoration:underline}.search__pagination a{color:#4285f4;text-decoration:none}.search__pagination a,.search__pagination span{margin-right:5px}@media(max-width:780px){.wrap{padding:40px 0}.content{width:auto}.logo,.search__header img,.search__header>.fn-right{display:none}.main{border:0;float:none;width:auto}input{width:100%;box-sizing:border-box;display:block}.a-500,.a-403,.a-404{margin:0 20px 0 0}#init{width:100%;padding:0 20px;box-sizing:border-box;left:0}.search__input{float:none}.search__input input{margin:0}.search__input button{position:absolute;right:20px;height:32px;line-height:16px}.search{padding:20px;width:100%;min-height:auto;box-sizing:border-box}.search__articles{width:auto}}
\ No newline at end of file
...@@ -693,7 +693,7 @@ Util.processClipBoard = function (clipboardData, cm) { ...@@ -693,7 +693,7 @@ Util.processClipBoard = function (clipboardData, cm) {
}; };
Util.initUploadFile = function (obj) { Util.initUploadFile = function (obj) {
var isImg = false; var cursor;
$('#' + obj.id).fileupload({ $('#' + obj.id).fileupload({
multipart: true, multipart: true,
pasteZone: obj.pasteZone, pasteZone: obj.pasteZone,
...@@ -701,6 +701,7 @@ Util.initUploadFile = function (obj) { ...@@ -701,6 +701,7 @@ Util.initUploadFile = function (obj) {
url: latkeConfig.servePath + "/upload", url: latkeConfig.servePath + "/upload",
paramName: "file[]", paramName: "file[]",
add: function (e, data) { add: function (e, data) {
obj.uploadingLabel = '';
data.submit(); data.submit();
}, },
submit: function (e, data) { submit: function (e, data) {
...@@ -712,12 +713,11 @@ Util.initUploadFile = function (obj) { ...@@ -712,12 +713,11 @@ Util.initUploadFile = function (obj) {
obj.uploadingLabel += '[' + item.name.replace(/\W/g, '') + '](Uploading...)'; obj.uploadingLabel += '[' + item.name.replace(/\W/g, '') + '](Uploading...)';
} }
}); });
var cursor = obj.editor.getCursor(); cursor = obj.editor.getCursor();
obj.editor.replaceRange(obj.uploadingLabel, cursor, cursor); obj.editor.replaceRange(obj.uploadingLabel, cursor, cursor);
} }
}, },
done: function (e, data) { done: function (e, data) {
var cursor = obj.editor.getCursor();
if (!data.result.sc) { if (!data.result.sc) {
var msg = ''; var msg = '';
data.files.forEach(function (item) { data.files.forEach(function (item) {
...@@ -729,7 +729,7 @@ Util.initUploadFile = function (obj) { ...@@ -729,7 +729,7 @@ Util.initUploadFile = function (obj) {
}); });
obj.editor.replaceRange(msg, obj.editor.replaceRange(msg,
CodeMirror.Pos(cursor.line, cursor.ch - obj.uploadingLabel.length), cursor); cursor, CodeMirror.Pos(cursor.line, cursor.ch + obj.uploadingLabel.length));
return; return;
} }
...@@ -737,25 +737,22 @@ Util.initUploadFile = function (obj) { ...@@ -737,25 +737,22 @@ Util.initUploadFile = function (obj) {
Object.keys(data.result.data.succMap).forEach(function (key) { Object.keys(data.result.data.succMap).forEach(function (key) {
var isImage = false; var isImage = false;
data.files.forEach(function (item) { data.files.forEach(function (item) {
if (item.name.replace(/\W/g, '') === key) {
isImage = item.type.indexOf('image') > -1 isImage = item.type.indexOf('image') > -1
}
}); });
resultMsg += (isImage ? '![' : '[') + resultMsg += (isImage ? '![' : '[') +
key.replace(/\W/g, '') + '](' + data.result.data.succMap[key] + ') \n\n'; key.replace(/\W/g, '') + '](' + data.result.data.succMap[key] + ') \n\n';
}); });
data.result.data.errFiles.forEach(function (name) { data.result.data.errFiles.forEach(function (name) {
var isImage = false; var isImage = false;
data.files.forEach(function (item) { data.files.forEach(function (item) {
if (item.name.replace(/\W/g, '') === key) {
isImage = item.type.indexOf('image') > -1 isImage = item.type.indexOf('image') > -1
}
}); });
resultMsg += (isImage ? '![' : '[') + resultMsg += (isImage ? '![' : '[') +
'[' + name.replace(/\W/g, '')+ '](Error)'; '[' + name.replace(/\W/g, '')+ '](Error)';
}); });
obj.editor.replaceRange(resultMsg, obj.editor.replaceRange(resultMsg,
CodeMirror.Pos(cursor.line, cursor.ch - obj.uploadingLabel.length), cursor); cursor, CodeMirror.Pos(cursor.line, cursor.ch + obj.uploadingLabel.length));
}, },
fail: function (e, data) { fail: function (e, data) {
if (obj.editor.replaceRange) { if (obj.editor.replaceRange) {
...@@ -767,9 +764,8 @@ Util.initUploadFile = function (obj) { ...@@ -767,9 +764,8 @@ Util.initUploadFile = function (obj) {
msg += '[' + item.name.replace(/\W/g, '') + '](' + data.errorThrown + ')'; msg += '[' + item.name.replace(/\W/g, '') + '](' + data.errorThrown + ')';
} }
}); });
var cursor = obj.editor.getCursor(); obj.editor.replaceRange(msg,
obj.editor.replaceRange('[' + item.name.replace(/\W/g, '') + '](' + data.errorThrown + ')', cursor, CodeMirror.Pos(cursor.line, cursor.ch + obj.uploadingLabel.length));
CodeMirror.Pos(cursor.line, cursor.ch - obj.uploadingLabel.length), cursor);
} }
} }
}); });
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -57,7 +57,9 @@ var Util = { ...@@ -57,7 +57,9 @@ var Util = {
return isArticle; return isArticle;
}, },
/** /**
* pjax * 初始化 Pjax
* @param cb 除文章和自定义页面外的其他页面加载回调
* @param articelCB 文章页面加载后的回调
*/ */
initPjax: function (cb, articelCB) { initPjax: function (cb, articelCB) {
if ($('#pjax').length === 1) { if ($('#pjax').length === 1) {
......
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment