Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,14 @@ jobs:
- name: Build
run: yarn install --immutable && yarn build

- name: Check Internal Links and Anchors
run: yarn exec blume audit --only LINK_TO_BROKEN,ANCHOR_BROKEN --strict

- name: Upload Build Artifacts
uses: actions/upload-artifact@v4
with:
name: dist-files
path: build/
path: dist/
retention-days: 1

deploy-eo:
Expand All @@ -44,16 +47,16 @@ jobs:
uses: actions/download-artifact@v4
with:
name: dist-files
path: build/
path: dist/

- name: Deploy to QCloud Pages
id: deploy
run: |
npm install -g edgeone
if [ "${{ github.ref }}" = "refs/heads/main" ]; then
edgeone pages deploy ./build -n fcc-docs -t ${{ secrets.QCLOUD_PAGES_TOKEN }} 2>&1 | tee deploy.log
edgeone pages deploy ./dist -n fcc-docs -t ${{ secrets.QCLOUD_PAGES_TOKEN }} 2>&1 | tee deploy.log
else
edgeone pages deploy ./build -n fcc-docs -e preview -t ${{ secrets.QCLOUD_PAGES_TOKEN }} 2>&1 | tee deploy.log
edgeone pages deploy ./dist -n fcc-docs -e preview -t ${{ secrets.QCLOUD_PAGES_TOKEN }} 2>&1 | tee deploy.log
fi

- name: Extract Preview URL
Expand Down
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ dist
# Docusaurus cache and generated files
.docusaurus

# Blume generated runtime
.blume

# Serverless directories
.serverless/

Expand All @@ -131,6 +134,7 @@ dist

# Production
/build
/dist

# Generated files
.docusaurus
Expand All @@ -142,3 +146,4 @@ dist
.env.development.local
.env.test.local
.env.production.local
.blume-verify/
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
lts/krypton
24
6 changes: 5 additions & 1 deletion .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
nodeLinker: node-modules
progressBarStyle: hogsfather
nodeLinker: node-modules
approvedGitRepositories:
- "**"
enableScripts: true
npmMinimalAgeGate: 1440
41 changes: 22 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,36 @@
# 兽展日历 文档
# 兽展日历文档

[![Netlify Status](https://api.netlify.com/api/v1/badges/21dc501c-7ab3-4a96-a230-be6812dad552/deploy-status)](https://app.netlify.com/sites/deluxe-griffin-ee110e/deploys)
[![Build](https://github.com/FurCoder/furry-event-china-docs/actions/workflows/deploy.yaml/badge.svg)](https://github.com/FurCoder/furry-event-china-docs/actions/workflows/deploy.yaml)

This website is built using [Docusaurus](https://docusaurus.io/), and deploy on Netlify for now.
## 环境要求

### Installation
- Node.js 24
- Yarn 4(通过 Corepack)

We use Yarn>=2

```
```bash
corepack enable
yarn install
```

```
$ yarn install
```

### Local Development
## 本地开发

```
$ yarn start
```bash
yarn dev
```

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
开发文档统一发布在 `/docs`,概览包含接入前言,接口详情在开发和构建时直接读取[线上 OpenAPI](https://api.furrycons.cn/open/docs/openapi.json)。

### Build
## 检查与构建

```bash
yarn check
yarn validate
yarn build
```
$ yarn build
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.
生产静态文件会输出到 `dist/`。

旧路径重定向统一维护在 `blume.config.ts`。`yarn build` 在 Blume 构建完成后,
从 `dist/vercel.json` 的重定向规则生成 `dist/edgeone.json`,随产物上传到 EdgeOne Pages。

配置格式见 [EdgeOne 文档](https://pages.edgeone.ai/document/edgeone-json)。
3 changes: 0 additions & 3 deletions babel.config.js

This file was deleted.

15 changes: 10 additions & 5 deletions blog/2023-01-27-the-beginning.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
---
slug: the-beginning
slug: blog/the-beginning
title: 起点
authors: paiji
description: 兽展日历从一个闲置域名开始的故事。
type: blog
date: 2023-01-27
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 6
---
关于我们的起源。
<!-- truncate -->
Expand All @@ -18,6 +26,3 @@ authors: paiji
>
>— 《瞎看什么》




12 changes: 10 additions & 2 deletions blog/2023-12-01-about.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
---
slug: about
slug: blog/about
title: 关于我们
authors: paiji
description: 了解兽展日历的项目定位、信息来源与免责说明。
type: blog
date: 2023-12-01
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 5
---

<!-- truncate -->
Expand Down
14 changes: 11 additions & 3 deletions blog/2023-12-26-infra.md → blog/2023-12-26-infra.mdx
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
---
slug: infra
slug: blog/infra
title: 我们的架构设计
authors: paiji
description: 兽展日历的访问入口、基础设施与技术架构。
type: blog
date: 2023-12-26
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 4
---
如果你对于我们的技术细节感兴趣,看这篇。
<!-- truncate -->

FCC 的所有入口均只支持 HTTPS 访问,所有的 HTTP 访问将会收到 301/307 重定向。尽管我们将全力保证重定向的正常工作,但还是请访客务必使用现代浏览器访问我们的网站。

同时,我们的裸域解析 `@.furryeventchina.com` 和 `@.furrycons.cn` 访问也会 302 重定向至 `www.furryeventchina.com` 和 `www.furrycons.cn`。
Expand Down
12 changes: 10 additions & 2 deletions blog/2024-01-01-brand.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
---
slug: brand
slug: blog/brand
title: 品牌资源
authors: paiji
description: 下载兽展日历的 Logo、Banner 并了解品牌资源使用协议。
type: blog
date: 2024-01-01
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 2
---

想要使用我们的 LOGO 或者 Banner,请参考本文。
Expand Down
12 changes: 10 additions & 2 deletions blog/2024-01-01-thanks.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
---
slug: thanks
slug: blog/thanks
title: 鸣谢&合作伙伴
authors: paiji
description: 感谢帮助兽展日历持续运营的品牌、朋友与社区伙伴。
type: blog
date: 2024-01-01
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 3
---

FCC 在运营过程中得到了以下朋友的帮助,你可以在网站的友情链接处找到他们!
Expand Down
5 changes: 0 additions & 5 deletions blog/authors.yml

This file was deleted.

12 changes: 10 additions & 2 deletions blog/contact-us.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
---
slug: contact-us
slug: blog/contact-us
title: 联系我们
authors: paiji
description: 通过 QQ、Discord、GitHub 或电子邮件联系兽展日历。
type: blog
date: 2024-12-18
authors:
- name: PaiJi
url: https://github.com/paiji
avatar: https://github.com/paiji.png
sidebar:
order: 1
---
有关我们的联系方式,请参考本文。
<!-- truncate -->
Expand Down
16 changes: 16 additions & 0 deletions blog/meta.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { defineMeta } from "blume";

export default defineMeta({
title: "博客",
icon: "newspaper",
order: 2,
collapsed: false,
pages: [
"contact-us",
"2024-01-01-brand",
"2024-01-01-thanks",
"2023-12-26-infra",
"2023-12-01-about",
"2023-01-27-the-beginning",
],
});
124 changes: 124 additions & 0 deletions blume.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
import { defineConfig } from "blume";
import { googleAnalytics } from "blume/analytics";
import { openapi } from "blume/reference";
import { orama } from "blume/search";

export default defineConfig({
title: "兽展日历文档",
description:
"兽展日历开放平台文档、项目动态与品牌资料,帮助开发者快速接入中国兽展数据。",
logo: {
image: "/logo.svg",
text: "兽展日历·文档",
href: "/",
},
content: {
root: ".",
include: ["docs/**/*.{md,mdx}", "blog/**/*.{md,mdx}"],
},
reference: [
openapi({
route: "/docs",
sources: [
{
label: "开发文档",
spec: "https://api.furrycons.cn/open/docs/openapi.json",
overlays: ["./overlays/production.yaml"],
seoDescriptionSuffix: false,
},
],
}),
],
github: {
owner: "FurCoder",
repo: "furry-event-china-docs",
branch: "main",
},
i18n: {
defaultLocale: "zh-CN",
locales: [
{
code: "zh-CN",
label: "简体中文",
},
],
hideDefaultLocalePrefix: true,
},
lastModified: "git",
feedback: false,
dateFormat: {
year: "numeric",
month: "2-digit",
day: "2-digit",
timeZone: "Asia/Shanghai",
},
theme: {
accent: {
light: "#ef5b68",
dark: "#ff8490",
},
action: "#e94859",
radius: "lg",
mode: "system",
},
navigation: {
tabs: [
{ label: "开发文档", path: "/docs", icon: "book-open" },
{ label: "博客", path: "/blog", icon: "newspaper" },
],
featured: [
{
label: "兽展日历",
href: "https://www.furrycons.cn",
icon: "calendar",
},
{
label: "开放平台",
href: "https://dashboard.furrycons.cn",
icon: "layout-dashboard",
},
{
label: "开发者反馈群",
href: "https://qm.qq.com/q/Q59CdSxP0S",
icon: "message-circle",
},
],
sidebar: {
display: "group",
},
},
search: orama(),
analytics: [googleAnalytics({ id: "G-SBEQ5GHN20" })],
markdown: {
imageZoom: true,
code: {
icons: true,
wrap: false,
},
},
agents: {
llmsTxt: true,
},
seo: {
og: { enabled: true },
rss: { enabled: true, types: ["blog"] },
sitemap: true,
robots: true,
structuredData: true,
},
deployment: {
site: "https://docs.furrycons.cn",
},
redirects: [
{ from: "/docs/intro", to: "/docs", status: 308 },
{ from: "/docs/api/event/list", to: "/docs/活动/list-open-events", status: 308 },
{ from: "/docs/api/event/recent", to: "/docs/活动/list-recent-open-events", status: 308 },
{ from: "/docs/api/event/detail", to: "/docs/活动/get-open-event", status: 308 },
{ from: "/docs/api/event/recent_old", to: "/docs/legacy/recent", status: 308 },
{ from: "/reference", to: "/docs", status: 308 },
{ from: "/reference/活动/list-open-events", to: "/docs/活动/list-open-events", status: 308 },
{ from: "/reference/活动/list-recent-open-events", to: "/docs/活动/list-recent-open-events", status: 308 },
{ from: "/reference/活动/get-open-event", to: "/docs/活动/get-open-event", status: 308 },
{ from: "/reference/组织/get-open-organization", to: "/docs/组织/get-open-organization", status: 308 },
],
});
Loading
Loading