no message
Former-commit-id: 666caeae181eff9a6ab6e8ff81db442e8d0d3d89 Former-commit-id: e1df8e45d78d8d226b2543d8a00c863c2ff21534 Former-commit-id: fc2eafbfac803deb16c778afbfd94fa9eebc8cab
This commit is contained in:
@@ -93,14 +93,30 @@ export default {
|
||||
}
|
||||
$baidupanHeight: 40px;
|
||||
.baidupan {
|
||||
height: $baidupanHeight;
|
||||
overflow: hidden;
|
||||
margin-bottom: 16px;
|
||||
.l {
|
||||
float: left;
|
||||
}
|
||||
.r {
|
||||
.container {
|
||||
height: $baidupanHeight + 10px;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #dfe2e5;
|
||||
padding: 5px;
|
||||
padding-right: 15px;
|
||||
float: left;
|
||||
.icon {
|
||||
float: left;
|
||||
height: $baidupanHeight;
|
||||
text-align: center;
|
||||
width: 50px;
|
||||
img {
|
||||
width: 40px;
|
||||
margin-top: 4px;
|
||||
}
|
||||
}
|
||||
.url {
|
||||
float: left;
|
||||
height: $baidupanHeight;
|
||||
line-height: $baidupanHeight;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -4,13 +4,15 @@ export default (quote) => {
|
||||
const bdShareUrlPwd = /^链接: https:\/\/pan\.baidu\.com\/s\/[a-z0-9]+ 密码: [a-z0-9]{4}$/i
|
||||
if (bdShareUrl.test(_quote)) {
|
||||
return `<div class="baidupan">
|
||||
<div class="l">
|
||||
<img src="/static/image/baidu-pan-logo.png">
|
||||
</div>
|
||||
<div class="r">
|
||||
<a href="${_quote}">${_quote}</a>
|
||||
</div>
|
||||
</div>`
|
||||
<div class="container">
|
||||
<div class="icon">
|
||||
<img src="/static/image/baidu-pan-logo.png">
|
||||
</div>
|
||||
<div class="url">
|
||||
<a href="${_quote}">${_quote}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>`
|
||||
} else if (bdShareUrlPwd.test(_quote)) {
|
||||
const url = _quote.match(/https:\/\/pan\.baidu\.com\/s\/[a-z0-9]+/i)
|
||||
const pwd = _quote.match(/[a-z0-9]{4}$/i)
|
||||
|
||||
Reference in New Issue
Block a user