hexo-theme-particlex 2.5.4 → 2.5.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,7 @@
8
8
  <% } %>
9
9
  <div id="timeline-wrap" ref="timeline">
10
10
  <% posts.reverse().forEach((post, id) => { %>
11
- <div class="timeline" data-title="<%- post.title.toLowerCase().replace(/\s+/gm, "") %>">
11
+ <div class="timeline" data-title="<%- post.title.toLowerCase().replace(/\s+/g, "") %>">
12
12
  <div class="timeline-tail"></div>
13
13
  <div class="timeline-content">
14
14
  <div class="item-time"><%= date(post.date, "YYYY/M/D") %></div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hexo-theme-particlex",
3
- "version": "2.5.4",
3
+ "version": "2.5.5",
4
4
  "description": "A concise Hexo theme, based on Particle.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,9 +1,10 @@
1
1
  mixins.highlight = {
2
2
  data() {
3
- return { copying: false, renderers: [this.highlight] };
3
+ return { copying: false };
4
4
  },
5
5
  created() {
6
6
  hljs.configure({ ignoreUnescapedHTML: true });
7
+ this.renderers.push(this.highlight);
7
8
  },
8
9
  methods: {
9
10
  highlight() {
@@ -1,6 +1,6 @@
1
1
  mixins.math = {
2
- data() {
3
- return { renderers: [this.math] };
2
+ created() {
3
+ this.renderers.push(this.math);
4
4
  },
5
5
  methods: {
6
6
  math() {
@@ -1,6 +1,9 @@
1
1
  mixins.preview = {
2
2
  data() {
3
- return { previewShow: false, renderers: [this.preview] };
3
+ return { previewShow: false };
4
+ },
5
+ created() {
6
+ this.renderers.push(this.preview);
4
7
  },
5
8
  methods: {
6
9
  preview() {
@@ -19,7 +19,7 @@ mixins.search = {
19
19
  },
20
20
  computed: {
21
21
  search() {
22
- return this.rawSearch.toLowerCase().replace(/s+/gm, "");
22
+ return this.rawSearch.toLowerCase().replace(/\s+/g, "");
23
23
  },
24
24
  },
25
25
  };
package/source/js/main.js CHANGED
@@ -1,7 +1,7 @@
1
1
  const app = Vue.createApp({
2
2
  mixins: Object.values(mixins),
3
3
  data() {
4
- return { loading: true, showMenu: false, barLocal: 0 };
4
+ return { loading: true, showMenu: false, barLocal: 0, renderers: [] };
5
5
  },
6
6
  created() {
7
7
  window.addEventListener("load", () => {