Skip to content

Commit

Permalink
delete: 删除大部分插件的使用
Browse files Browse the repository at this point in the history
feature: 迁移主题至reco
AyalaKaguya committed Mar 13, 2024
1 parent 6158863 commit 715dadd
Showing 11 changed files with 97 additions and 157 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -13,7 +13,7 @@ node_modules/
npm-debug.log

# Compiled site
/dist/
src/.vuepress/dist/

# Ignore Visual Studio Code files
*.code-workspace
8 changes: 4 additions & 4 deletions src/.vuepress/components/DownloadButtons.vue
Original file line number Diff line number Diff line change
@@ -82,12 +82,12 @@ const getDownloadPath = (release, fallbackUrl) => {
}
.stable {
background-color: #3eaf7c;
border-color: #3eaf7c;
background-color: rgb(93 103 232 / var(--tw-bg-opacity));
border-color: rgb(93 103 232 / var(--tw-bg-opacity));
&:hover {
background-color: lighten(#3eaf7c, 10%);
border-color: lighten(#3eaf7c, 10%);
background-color: lighten(rgb(93 103 232), 10%);
border-color: lighten(rgb(93 103 232), 10%);
}
}
8 changes: 3 additions & 5 deletions src/.vuepress/components/ExtensionItem.vue
Original file line number Diff line number Diff line change
@@ -94,9 +94,8 @@ export default {
padding-top: .5rem;
padding-bottom: .3rem;
border-radius: 4px;
color: white;
background-color: #3eaf7c;
border: 1px solid #3eaf7c;
color: rgb(93 103 232 / var(--tw-bg-opacity));
border: 1px solid rgb(93 103 232 / var(--tw-bg-opacity));
font-weight: 700;
line-height: 24px;
@@ -105,8 +104,7 @@ export default {
}
&:hover {
background-color: white;
color: #3eaf7c;
background-color: lighten(rgb(93 103 232), 20%);
text-decoration: none;
.material-icons {
167 changes: 54 additions & 113 deletions src/.vuepress/config.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import { recoTheme } from 'vuepress-theme-reco'
// import { googleAnalyticsPlugin } from '@vuepress/plugin-google-analytics'
// import { searchPlugin } from '@vuepress/plugin-search'
// import { getDirname, path } from '@vuepress/utils'

// const __dirname = getDirname(import.meta.url)

export default defineUserConfig({
@@ -22,136 +22,77 @@ export default defineUserConfig({
// 基本配置
style: "@vuepress-reco/style-default",
logo: "/icons/logo.ico",
repo: "easybangumiorg/easybangumi",
repo: "easybangumiorg/website",
sourceDir: "src",
// 协同编辑
docsRepo: "https://github.com/easybangumiorg/website",
docsBranch: 'main',
docsDir: "src",

editLink: true,
// 上次编辑
lastUpdated: true,
// 合作者
contributors: true,
// 侧边栏
sidebar: 'auto',

// 主题多语言设置
locales: {
'/en/': { // 英语设置
selectLanguageName: 'English',
editLinkText: "Help us improve this page",
lastUpdatedText: "Last updated",
contributorsText: "Contributors",
series: { // 系列文章
'/docs/reference': [
{
text: '常见问题',
children: [
'/docs/reference/faq',
]
},
{
text: '用户指南',
children: [
'/docs/reference/getting-started',
]

},
{
text: '开发',
children: [
'/docs/reference/contribution',
'/docs/reference/extension-example',
'/docs/reference/extension-utils',
]
},
]
},

navbar: [
{ text: "Home", link: "/en/" },
navbar: [ // 顶部导航栏
{ text: "主页", link: "/" },
{
text: "下载",
children: [
{ text: "本体", link: "/download/" },
{ text: "扩展", link: "/extensions/" },
]
},
{
text: "参考",
children: [
{
text: "Download",
children: [
{ text: "EasyBangumi", link: "/en/download/" },
{ text: "Extensions", link: "/en/extensions/" },
]
text: "常见问题",
link: "/docs/reference/faq",
},
],
},
'/': { // 简体中文设置
selectLanguageName: '简体中文',
editLinkText: "帮助我们改善此页",
lastUpdatedText: "上次更新",
contributorsText: "贡献者",

navbar: [ // 顶部导航栏
{ text: "主页", link: "/" },
{
text: "下载",
text: "用户指南",
children: [
{ text: "本体", link: "/download/" },
{ text: "扩展", link: "/extensions/" },
]
'/docs/reference/getting-started'
],
},
{
text: "帮助",
text: "开发",
children: [
{
text: "常见问题",
link: "/guide/faq/",
},
{
text: "用户指南",
children: [
'/guide/user-manual/getting-started.md'
],
},
{
text: "开发",
children: [
'/guide/contribution/noumenon.md',
'/guide/contribution/extension-example.md',
'/guide/contribution/extension-utils.md'
],
},
]
'/docs/reference/contribution',
'/docs/reference/extension-example',
'/docs/reference/extension-utils'
],
},
],

sidebar: { // 个别页面的侧边栏
'/guide/': [
{
text: '常见问题',
collapsible: true,
link: '/guide/faq/',
}, {
text: '用户指南',
collapsible: true,
children: [
'/guide/user-manual/getting-started.md',
],
}, {
text: '开发',
collapsible: true,
children: [
'/guide/contribution/noumenon.md',
'/guide/contribution/extension-example.md',
'/guide/contribution/extension-utils.md'
],
},
],
},

// 简体中文的额外设置
selectLanguageText: '选择语言',
selectLanguageAriaLabel: '选择语言',
tip: '提示',
warning: '注意',
danger: '警告',
notFound: [
'这里什么都没有',
'我们怎么到这来了?',
'这是一个 404 页面',
'看起来我们进入了错误的链接',
],
backToHome: '返回首页',
openInNewWindow: '在新窗口打开',
toggleColorMode: '切换颜色模式',
toggleSidebar: '切换侧边栏',
]
},
},
],
}),

// 网站多语言支持
locales: {
'/en/': {
lang: 'en-US',
title: 'EasyBangumi',
description: 'Free and open source animation player for Android',
},
'/': {
lang: 'zh-CN',
title: '纯纯看番',
description: '免费且开源的安卓动漫播放器',
},
},
title: '纯纯看番',
description: '免费且开源的安卓动漫播放器',

// 插件
plugins: [
32 changes: 0 additions & 32 deletions src/.vuepress/store/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { createStore } from 'vuex'

const RELEASE_API = "https://api.github.com/repos/easybangumiorg/EasyBangumi/releases/latest"
const NIGHTLY_API = "https://api.github.com/repos/easybangumiorg/EasyBangumi-nightly/releases/latest"

const worker = (function () {
const networkMap = new Map()
@@ -63,17 +62,6 @@ const worker = (function () {
})
})
},
getNightlyData(store, name) {
return new Promise((resolve, reject) => {
_getData(store, name, "setNightlyReleaseData", NIGHTLY_API)
.then(() => {
resolve(store.state.nightly.data)
})
.catch((reason) => {
reject(reason)
})
})
},
}
})()

@@ -84,10 +72,6 @@ export default createStore({
updated: null,
data: null,
},
nightly: {
updated: null,
data: null,
},
}
},
mutations: {
@@ -97,12 +81,6 @@ export default createStore({
data: data,
}
},
setNightlyReleaseData(state, data) {
state.nightly = {
updated: new Date().getTime(),
data: data,
}
},
},
actions: {
getStableReleaseData() {
@@ -115,15 +93,5 @@ export default createStore({

return worker.getStableData(this, "stable")
},
getNightlyReleaseData() {
const { updated } = this.state.nightly;
const now = new Date().getTime();

if (updated != null && now - updated <= 60 * 60 * 24 * 1000) {
return Promise.resolve(this.state.nightly.data);
}

return worker.getNightlyData(this, "nightly")
},
},
})
37 changes: 35 additions & 2 deletions src/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
---
home: true
modules: # 指定首页展示模块
- BannerBrand
- MdContent
- Features
- Footer

bannerBrand:
title: 纯纯看番
description: 使用 Compose 开发的看番软件,支持多番剧源。
tagline: 纯纯看番5.x版本,提供追番的强大动力,支持番剧搜索、首页推荐、番剧收藏(追番)、番剧分类、多主题、倍速播放、播放历史、投屏功能、番剧下载、弹幕、插件化、插件市场。
buttons:
- { text: 下载, link: "/download/" }
- { text: 浏览插件, link: "/extensions/", type: "plain" }
socialLinks:
- { icon: "LogoGithub", link: "https://github.com/easybangumiorg/EasyBangumi" }
- { icon: "Telegram", link: "https://t.me/easybangumi" }

features:
- title: 插件化
details: 系统的插件化框架,通过安装插件来获取更多的番剧源。
- title: 追番
details: 纯纯看番会自动管理你追的番剧,确保第一时间获得更新。
- title: 自定义
details: 纯纯看番具有相当多的主题选项,也可以跟随系统自动设置暗黑模式。

footer:
record: Apache-2.0 Licensed
recordLink: https://easybangumi.org
startYear: 2022
---

<!-- ---
home: true
meta:
- name: keywords
content: 纯纯看番, EasyBangumi, Animation, Android app
@@ -15,10 +48,10 @@ actions:
type: secondary
features:
- title: 插件化
details: 比较系统的插件化框架,通过安装插件来获取更多的源。
details: 系统的插件化框架,通过安装插件来获取更多的源。
- title: 追番
details: 每次打开纯纯看番,你都可以接收到来自多个番剧源的番剧更新提示。
- title: 自定义
details: 纯纯看番具有相当多的主题选项,也可以跟随系统自动设置暗黑模式。
footer: Apache-2.0 Licensed | Copyright © 2022-present EasyBangumi.org
---
--- -->
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 715dadd

Please sign in to comment.