Skip to content

Commit 88da486

Browse files
authored
docs(readme): Sync README.zh-CN.md (iorate#543)
* Update README.zh-CN.md * Update README.zh-CN.md 根据维基百科中的用词,我使用了ISO语言「代码」而不是「代号」
1 parent 9b7a8cb commit 88da486

File tree

1 file changed

+31
-19
lines changed

1 file changed

+31
-19
lines changed

README.zh-CN.md

+31-19
Original file line numberDiff line numberDiff line change
@@ -2,59 +2,71 @@
22

33
[English](README.md)
44

5-
屏蔽指定的网站防止其显示在 Google 以及其他搜索引擎中
5+
在搜索结果中屏蔽指定的网站
66

77
[Chrome 应用商店](https://chrome.google.com/webstore/detail/ublacklist/pncfbmialoiaghdehhbnbhkkgmjanfhe) / [Firefox 扩展](https://addons.mozilla.org/en-US/firefox/addon/ublacklist/) / [App Store](https://apps.apple.com/us/app/ublacklist-for-safari/id1547912640) (支持 macOS 和 iOS,特别鸣谢 [Group-Leafy](https://github.com/HoneyLuka/uBlacklist/tree/safari-port/safari-project))
88

99
## 介绍
1010

1111
此扩展可防止您指定的网站出现在 Google 和其他的一些搜索引擎中。
1212

13-
您可以为搜索结果添加规则或点击工具栏图标以屏蔽指定的网站。规则可以通过以下方式指定:[匹配模式](https://developer.mozilla.org/zh-CN/docs/mozilla/add-ons/webextensions/match_patterns) (示例: `*://*.example.com/*`,这样的话会屏蔽 example.org 网站) 或使用[正则表达式](https://developer.mozilla.org/zh-CN/docs/web/javascript/guide/regular_expressions) (示例: `/example\.(net|org)/`,这样的话可以屏蔽 example.net 和 example.org 两个网站).
13+
您可以为搜索结果添加规则或点击工具栏图标以屏蔽指定的网站。规则可以通过以下方式指定:[匹配模式](https://developer.mozilla.org/zh-CN/docs/mozilla/add-ons/webextensions/match_patterns) (示例:`*://*.example.com/*`) 或使用[正则表达式](https://developer.mozilla.org/zh-CN/docs/web/javascript/guide/regular_expressions) (示例:`/example\.(net|org)/`).
1414

15-
您可以通过云存储跨设备同步规则集。 目前,支持 Google Drive 和 Dropbox。
15+
您可以通过云存储跨设备同步规则集。目前,支持 Google Drive 和 Dropbox。
1616

17-
您还可以订阅公共规则集。 该网站列出了一些订阅:https://iorate.github.io/ublacklist/subscriptions
17+
您还可以订阅公共规则集。该网站列出了一些订阅:
18+
https://iorate.github.io/ublacklist/subscriptions
1819

1920
## 支持的搜索引擎
2021

21-
此扩展支持以下搜索引擎
22+
此扩展支持以下搜索引擎
2223

2324
| | 网页 | 图片 | 视频 | 新闻 |
2425
| ------------ | ------------------ | ------------------ | ------------------ | ------------------ |
2526
| Google | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
26-
| Bing | \*1 | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
27-
| Brave | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
27+
| Bing | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
28+
| Brave \*3 | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
2829
| DuckDuckGo | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
2930
| Ecosia | :heavy_check_mark: | | | |
30-
| Qwant | :heavy_check_mark: | :heavy_check_mark: | \*2 | :heavy_check_mark: |
31-
| SearX \*3 | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
31+
| Kagi | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
32+
| Qwant | :heavy_check_mark: | :heavy_check_mark: | \*1 | :heavy_check_mark: |
33+
| SearX \*2 | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
3234
| Startpage | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |
3335
| Yahoo! JAPAN | :heavy_check_mark: | | | |
3436
| Yandex | :heavy_check_mark: | | | |
3537

36-
\*1 仅当 "Always play videos on Qwant.com" 关闭时<br>
37-
\*2 仅支持某些公共实例,如果您想将自己的 SearX/SearXNG 添加到支持列表,你需要前往`src/common/search-engines.ts`,并手动将您的搜索引擎添加到列表中,然后手动进行构建。
38+
\*1 仅当 "Always play videos on Qwant.com" 关闭时。<br>
39+
\*2 仅支持某些公共实例,如果您想将自己的 SearX/SearXNG 添加到支持列表,你需要前往`src/common/search-engines.ts`,并手动将您的搜索引擎添加到列表中,然后手动进行构建。<br>
40+
\*3 由于获取图片链接的完整 URL 有困难,此扩展在 Brave 图片搜索上不支持子域名屏蔽。(例如,如果链接指向 "www.example.com",扩展会屏蔽整个 "example.com"。)
3841

3942
## 发布订阅
4043

4144
要将规则集发布为订阅,请将以 UTF-8 编码的规则集文件放在合适的 HTTP(S) 服务器上,然后发布 URL。 这是托管在 GitHub 上的示例:<br>
4245
https://raw.githubusercontent.com/iorate/ublacklist-example-subscription/master/uBlacklist.txt
4346

44-
_Chrome_ 浏览器中且 uBlacklist >=6.6.0 ,订阅链接是有效的。为 `name` `url` 添加订阅, 以下 URL 可用作选项页面的快捷方式:
47+
你可以在规则集前放置 YAML frontmatter。建议设定 `name` 变量。
4548

4649
```
47-
https://iorate.github.io/ublacklist/subscribe?name={urlEncode(name)}&url={urlEncode(url)}
50+
---
51+
name: Your ruleset name
52+
---
53+
*://*.example.com/*
54+
```
55+
56+
_Chrome_ 浏览器上的 uBlacklist >=6.6.0 中,订阅链接是有效的。要添加 `url` 为订阅, 以下 URL 可用作选项页面的快捷方式:
57+
58+
```
59+
https://iorate.github.io/ublacklist/subscribe?url={urlEncode(url)}
4860
```
4961

5062
对于上面的示例:<br>
51-
https://iorate.github.io/ublacklist/subscribe?name=Example&url=https%3A%2F%2Fraw.githubusercontent.com%2Fiorate%2Fublacklist-example-subscription%2Fmaster%2FuBlacklist.txt
63+
https://iorate.github.io/ublacklist/subscribe?url=https%3A%2F%2Fraw.githubusercontent.com%2Fiorate%2Fublacklist-example-subscription%2Fmaster%2FuBlacklist.txt
5264

5365
## 开发者
5466

5567
### 构建
5668

57-
为了构建这个扩展,你需要下载并安装 [pnpm](https://pnpm.io/)>=9.7.0 or [corepack](https://github.com/nodejs/corepack) (currently distributed with Node.js)。
69+
为了构建这个扩展,你需要下载并安装 [pnpm](https://pnpm.io/)>=9.7.0 [corepack](https://github.com/nodejs/corepack) (目前 Node.js 安装时自带)。
5870

5971
```shell
6072
# If you use corepack
@@ -70,7 +82,7 @@ pnpm install
7082
pnpm build
7183
```
7284

73-
在您提交`Pull Request`之前,您需要确保`pnpm check`通过测试,否则可能会影响 github actions 自动构建
85+
在您提交 Pull Request 之前,您需要确保 `pnpm check` 通过测试
7486

7587
```shell
7688
pnpm check
@@ -88,11 +100,11 @@ GOOGLE_DRIVE_API_KEY=...
88100
GOOGLE_DRIVE_API_SECRET=...
89101
```
90102

91-
### 语言
103+
### 本地化
92104

93-
添加一个语言,
105+
要添加一个语言,
94106

95-
1. 定义一个 ISO 语言代码,例如`en`指的是 [kLanguageInfoTable](https://src.chromium.org/viewvc/chrome/trunk/src/third_party/cld/languages/internal/languages.cc).
107+
1. 确定所要添加语言的 ISO 代码,例如 `en`,参见 [kLanguageInfoTable](https://src.chromium.org/viewvc/chrome/trunk/src/third_party/cld/languages/internal/languages.cc).
96108
1. 复制 `src/_locales/en/messages.json.ts``src/_locales/${languageCode}/messages.json.ts` 并翻译条目.
97109
1. 打开 `src/scripts/dayjs-locales.ts` 并导入 dayjs 语言环境.
98110
1. 要本地化网上商店的描述和屏幕截图,请创建 `web-store-assets/${languageCode}/` 并添加文件。

0 commit comments

Comments
 (0)