Skip to content

Commit

Permalink
修改代码显示自动换行
Browse files Browse the repository at this point in the history
修正高亮代码插件问题
升级到1.5.0
  • Loading branch information
awinds committed Sep 27, 2024
1 parent 7aa5997 commit fc222ce
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 11 deletions.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,12 @@

Github:[https://github.com/awinds/xaink][1]

说明:[https://xiaoa.me/archives/theme_xaink.html][5]

Demo:[https://www.xa.ink][2]

作者blog:[https://xiaoa.me][6]

![主题界面][3]

![主题界面][4]
Expand All @@ -25,7 +29,7 @@ Demo:[https://www.xa.ink][2]
- Sitemap插件,可生成网站地图
- Stat插件,可显示文章浏览人数
- CodeHighlighter插件,可高亮代码
- Sticky插件,可置顶文章,需做以下修改配合(使用plugins下面带的插件已修改)
- Sticky插件,可置顶文章,需做以下修改配合(使用plugins下面带的插件已修改)
> ```php
> //增加字段,外面可以自定义判断
> $sticky_post['istop'] = 1;
Expand All @@ -48,6 +52,10 @@ Open sourced under the MIT license.
保留Theme by Xaink,谢谢!
# 更新说明
## 1.5.0
1. 修改代码过长没自动换行的问题。
2. 如果使用高亮插件,要解决换行问题,要改插件中样式`pre[class*="language-"]`中`white-space`值为`pre-wrap`。
3. 修正暗样式问题。
## 1.4.9
1. 增加友链的页面插件下载地址。
2. 打包配套插件到github,目录plugins,可选择使用。
Expand Down Expand Up @@ -103,3 +111,5 @@ Open sourced under the MIT license.
[2]: https://www.xa.ink
[3]: https://raw.githubusercontent.com/awinds/xaink/main/screenshot.png
[4]: https://raw.githubusercontent.com/awinds/xaink/main/screenshot2.png
[5]: https://xiaoa.me/archives/theme_xaink.html
[6]: https://xiaoa.me
15 changes: 9 additions & 6 deletions assets/css/xa-ink-post.css
Original file line number Diff line number Diff line change
Expand Up @@ -720,8 +720,9 @@
.xa-post-content pre > code {
padding: 0;
margin: 0;
word-break: normal;
white-space: pre;
word-break: break-all;
word-wrap: break-word;
white-space: pre-wrap;
background: transparent;
border: 0;
}
Expand Down Expand Up @@ -753,7 +754,8 @@
margin: 0;
overflow: visible;
line-height: inherit;
word-wrap: normal;
word-wrap: break-word;
word-break: break-all;
background-color: transparent;
border: 0;
}
Expand Down Expand Up @@ -1021,7 +1023,7 @@
color-scheme: dark;
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
margin: 0;
margin: 12px 0;
color: #c9d1d9;
background-color: #0d1117;
font-size: 16px;
Expand Down Expand Up @@ -1729,8 +1731,9 @@
.dark .xa-post-content pre > code {
padding: 0;
margin: 0;
word-break: normal;
white-space: pre;
word-break: break-all;
word-wrap: break-word;
white-space: pre-wrap;
background: transparent;
border: 0;
}
Expand Down
5 changes: 2 additions & 3 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@
'tag' => _t('标签 %s 下的文章'),
'author' => _t('%s 发布的文章')
), '', ' - '); ?><?php $this->options->title(); ?><?php if($this->_currentPage>1) echo ' - 第 '.$this->_currentPage.''; ?></title>
<link rel="shoucut icon" href="<?php $this->options->siteUrl . "favicon.ico" ?>">
<?php $this->header("description=&generator=&pingback=&template=&xmlrpc=&wlw=&commentReply=&keywords="); ?>
<link rel="shoucut icon" href="<?php echo($this->options->siteUrl . "favicon.ico"); ?>">
<!-- <link rel="preload" href="--><?php //$this->options->themeUrl("assets/css/fonts/tabler-icons.woff2") ?><!--" as="font" type="font/woff2" crossorigin />-->
<link href="<?php $this->options->themeUrl("assets/css/tailwind.min.css?v=" . xaGetVersion()); ?>" rel="stylesheet" />
<link href="<?php $this->options->themeUrl("assets/css/tabler-icons.min.css"); ?>" rel="stylesheet"/>
<link href="<?php $this->options->themeUrl("assets/js/OwO/OwO.min.css?v=" . xaGetVersion()); ?>" rel="stylesheet" />
<link href="<?php $this->options->themeUrl("assets/css/outline.min.css?v=" . xaGetVersion()); ?>" rel="stylesheet" />
<link href="<?php $this->options->themeUrl("assets/css/xa-ink.css?v=" . xaGetVersion()); ?>" rel="stylesheet" />
<link href="<?php $this->options->themeUrl("assets/css/xa-ink-post.css?v=" . xaGetVersion()); ?>" rel="stylesheet" />
<?php $this->header("description=&generator=&pingback=&template=&xmlrpc=&wlw=&commentReply=&keywords="); ?>
<script type="text/javascript" src="<?php $this->options->themeUrl("assets/js/jquery.min.js?v=" . xaGetVersion()); ?>"></script>
<script type="text/javascript" src="<?php $this->options->themeUrl("assets/js/jquery.lazyload.min.js?v=" . xaGetVersion()); ?>"></script>
<script type="text/javascript" src="<?php $this->options->themeUrl("assets/js/jquery.sticky-sidebar.min.js?v=" . xaGetVersion()); ?>"></script>
Expand All @@ -64,7 +64,6 @@
var siteUrl = '<?php $this->options->siteUrl() ?>';
</script>
<script type="text/javascript" src="<?php $this->options->themeUrl("assets/js/xa-ink.js?v=" . xaGetVersion()); ?>"></script>

</head>
<body>
<!-- 头部导航栏 -->
Expand Down
2 changes: 1 addition & 1 deletion index.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* @package XaInk
* @author XiaoA
* @version 1.4.9
* @version 1.5.0
* @link https://www.xa.ink/
*/
if (!defined('__TYPECHO_ROOT_DIR__')) exit;
Expand Down

0 comments on commit fc222ce

Please sign in to comment.