Skip to content

Commit

Permalink
chore: rename from CC98-Evolved to yacu
Browse files Browse the repository at this point in the history
  • Loading branch information
CoolSpring8 committed Jan 12, 2022
1 parent 61f3fad commit 7d30111
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,6 @@ jobs:

- uses: ncipollo/release-action@v1
with:
artifacts: "dist/cc98-evolved.userscript.js"
artifacts: "dist/yacu.userscript.js"
generateReleaseNotes: true
token: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"plugins": ["prettier-plugin-svelte"]
"plugins": ["./node_modules/prettier-plugin-svelte"]
}
21 changes: 17 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,20 @@
# CC98-Evolved
# yacu: Yet another CC98 userscript

CC98 增强脚本
又一个 CC98 增强脚本

## 命名
<https://greasyfork.org/zh-CN/scripts/438399>

Copy 自 [the1812/Bilibili-Evolved:强大的哔哩哔哩增强脚本](https://github.com/the1812/Bilibili-Evolved)
## What problem does it solve? How?

集思广益版有许多前辈提出了有意思的需求,或广泛或小众。由于种种因素所限,可能站务组决定不予采纳,或者技术组选择暂不实现。这个脚本期望作为第三方,为喜欢折腾的用户提供一种~~折腾~~自定义的体验。

在实现上,传统的用户脚本大多基于对页面元素的直接操作,对单页面应用则需配合 setTimeout / setInterval 以等待完全加载和应对翻页情况。近年来前端技术发展迅速,为开发提供了便利,因此项目设计时完全放弃了旧浏览器的兼容性以及用户脚本管理器提供的 API,选择实践现代浏览器提供的新的原生特性(另一方面也是为了锻炼自己去学习更多新知识)。

- 模块化开发、工程化开发,拓展方便。(Rollup+esbuild+TypeScript+Babel+Svelte+Tailwind)
- ES6 Proxy 拦截 Fetch、History 等,实现精准操作。

## 功能

- 每个楼层的风评操作统计
- 屏蔽用户(新帖列表的主题帖、主题帖下的回复帖)
- ...
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "cc98-evolved",
"name": "yacu",
"version": "1.0.0",
"description": "CC98 增强脚本",
"homepage": "https://github.com/CoolSpring8/CC98-Evolved",
"homepage": "https://github.com/CoolSpring8/yacu",
"author": "CoolSpring8",
"type": "module",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export default (async () =>
defineConfig({
input: "src/main.ts",
output: {
file: "dist/cc98-evolved.userscript.js",
file: "dist/yacu.userscript.js",
/**
* 不要在 main.ts 里导出
* 这样设置只是因为没有必要创建 IIFE
Expand Down
9 changes: 6 additions & 3 deletions src/meta.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
{
"name": "CC98 Evolved",
"namespace": "https://github.com/CoolSpring8/CC98-Evolved",
"match": "*://www.cc98.org/*",
"name": "yacu: Yet another CC98 userscript.",
"namespace": "https://github.com/CoolSpring8/",
"match": [
"*://www.cc98.org/*",
"*://www-cc98-org-s.webvpn.zju.edu.cn:8001/*"
],
"run-at": "document-idle",
"grant": "none"
}
2 changes: 1 addition & 1 deletion src/utils/error.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export class BasicError extends Error {
constructor(message?: string) {
super(`[CC98-Evolved] ${message}`);
super(`[yacu] ${message}`);
}
}

0 comments on commit 7d30111

Please sign in to comment.