Skip to content

Commit 64376b4

Browse files
committed
feat: new style
Update rspress.config.ts
1 parent d13c392 commit 64376b4

32 files changed

Lines changed: 231 additions & 164 deletions

assets/styles/global.css

Lines changed: 0 additions & 67 deletions
This file was deleted.

docs/public/rspress-dark-logo.png

-6.15 KB
Binary file not shown.

docs/public/rspress-icon.png

-100 KB
Binary file not shown.

docs/public/rspress-light-logo.png

-6.23 KB
Binary file not shown.

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@
88
"preview": "rspress preview"
99
},
1010
"dependencies": {
11-
"@iringo/doc-ui": "^2.0.0",
12-
"rehype-urls": "^1.2.0",
11+
"@iringo/doc-ui": "^2.0.2",
12+
"remark-github": "^12.0.0",
1313
"rspress": "^1.37.2",
1414
"rspress-plugin-changelog": "^1.1.2",
15-
"rspress-plugin-font-open-sans": "^1.0.0",
1615
"rspress-plugin-sitemap": "^1.1.1"
1716
},
1817
"devDependencies": {
1918
"@biomejs/biome": "^1.9.4",
2019
"@rspress/shared": "^1.37.4",
2120
"@types/node": "^16.18.121",
22-
"remark-github": "^12.0.0"
21+
"@types/react": "^18.3.11",
22+
"typescript": "^5.7.2"
2323
},
2424
"repository": {
2525
"type": "git",

pnpm-lock.yaml

Lines changed: 21 additions & 64 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rspress.config.ts

Lines changed: 3 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
import fs from 'node:fs';
22
import path from 'node:path';
3-
import type { UrlWithStringQuery } from 'node:url';
43
import { pluginChangelog } from 'rspress-plugin-changelog';
54
import type { ChangelogPluginOptions } from 'rspress-plugin-changelog';
6-
import { pluginFontOpenSans } from 'rspress-plugin-font-open-sans';
75
import pluginSitemap from 'rspress-plugin-sitemap';
86
import { defineConfig } from 'rspress/config';
97

@@ -22,17 +20,18 @@ export default defineConfig({
2220
description: '双语及增强字幕生成工具',
2321
icon: 'https://avatars.githubusercontent.com/u/100578089?s=200&v=4',
2422
logo: 'https://avatars.githubusercontent.com/u/100578089?s=80&v=4',
23+
logoText: 'DualSubs',
2524
// logo: {
2625
// light: '/rspress-light-logo.png',
2726
// dark: '/rspress-dark-logo.png',
2827
// },
29-
globalStyles: path.resolve('./assets/styles/global.css'),
3028
head: [
3129
['link', { ref: 'preconnect', href: '//ipolyfill.edge-byted.com' }],
3230
['link', { ref: 'dns-prefetch', href: '//ipolyfill.edge-byted.com' }],
33-
['script', { src: '//ipolyfill.edge-byted.com/0.0.24/polyfill.min.js', crossorigin: '' }],
31+
['script', { src: '//ipolyfill.edge-byted.com/0.0.25/polyfill.min.js', crossorigin: '' }],
3432
],
3533
themeConfig: {
34+
lastUpdated: true,
3635
socialLinks: [
3736
{ icon: 'github', mode: 'link', content: 'https://github.com/DualSubs' },
3837
{
@@ -52,28 +51,8 @@ export default defineConfig({
5251
markdown: {
5352
mdxRs: false,
5453
remarkPlugins: [[require('remark-github')]],
55-
rehypePlugins: [
56-
[
57-
require('rehype-urls'),
58-
(url: UrlWithStringQuery, node: any) => {
59-
switch (url.host) {
60-
case 't.me':
61-
case 'github.com':
62-
node.properties.target = '_blank';
63-
break;
64-
case null:
65-
//console.log(url);
66-
break;
67-
default:
68-
//console.log(url);
69-
break;
70-
}
71-
},
72-
],
73-
],
7454
},
7555
plugins: [
76-
pluginFontOpenSans(),
7756
pluginSitemap({
7857
domain: siteUrl,
7958
}),
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)