mirror of
https://github.com/typecho/typecho.git
synced 2025-04-21 02:01:52 +02:00
修正一些细节
This commit is contained in:
parent
58afc7fc0c
commit
ea3d5585a8
@ -160,7 +160,7 @@ $(document).ready(function () {
|
||||
src = src.substring(0, src.length - 1);
|
||||
}
|
||||
|
||||
return '<div style="background: #ddd; height: 40px; line-height: 40px; text-align: center; font-size: 12px; color: #777">'
|
||||
return '<div style="background: #ddd; height: 40px; overflow: hidden; line-height: 40px; text-align: center; font-size: 12px; color: #777">'
|
||||
+ tag + ' : ' + $.trim(src) + '</div>';
|
||||
});
|
||||
|
||||
|
@ -141,12 +141,18 @@
|
||||
|
||||
if (checked) {
|
||||
$(s.rowEl, table).each(function () {
|
||||
$(s.checkEl, this).prop('checked', true);
|
||||
}).addClass('checked');
|
||||
var t = $(this), el = $(s.checkEl, this).prop('checked', true);
|
||||
if (el.length > 0) {
|
||||
t.addClass('checked');
|
||||
}
|
||||
});
|
||||
} else {
|
||||
$(s.rowEl, table).each(function () {
|
||||
$(s.checkEl, this).prop('checked', false);
|
||||
}).removeClass('checked');
|
||||
var t = $(this), el = $(s.checkEl, this).prop('checked', false);
|
||||
if (el.length > 0) {
|
||||
t.removeClass('checked');
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -149,26 +149,9 @@ class Widget_Abstract_Contents extends Widget_Abstract
|
||||
protected function ___summary()
|
||||
{
|
||||
$content = $this->content;
|
||||
$parts = preg_split("/<\/\s*(?:p|blockquote|q|pre|table)\s*>/i", $content, 2);
|
||||
$parts = preg_split("/(<\/\s*(?:p|blockquote|q|pre|table)\s*>)/i", $content, 2, PREG_SPLIT_DELIM_CAPTURE);
|
||||
if (!empty($parts)) {
|
||||
preg_match("/<\s*(?:p|blockquote|q|pre|table)\s*>/i", $parts[0], $tags);
|
||||
switch ($tags[0]) {
|
||||
case '<pre>':
|
||||
$content = $parts[0] . '</pre>';
|
||||
break;
|
||||
case '<blockquote>':
|
||||
$content = $parts[0] . '</blockquote>';
|
||||
break;
|
||||
case '<q>':
|
||||
$content = $parts[0] . '</q>';
|
||||
break;
|
||||
case '<table>':
|
||||
$content = $parts[0] . '</table>';
|
||||
break;
|
||||
default:
|
||||
$content = $parts[0] . '</p>';
|
||||
break;
|
||||
}
|
||||
$content = $parts[0] . $parts[1];
|
||||
}
|
||||
|
||||
return $content;
|
||||
@ -940,3 +923,4 @@ class Widget_Abstract_Contents extends Widget_Abstract
|
||||
echo $this->author->{$item};
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user