feat(阶段1): 搬入 ojnext 为 apps/web,未改业务代码

This commit is contained in:
xuyue committed 2026-08-06 21:18:16 -06:00
1 parent 3c975e85ee
commit ae1fb329b5
258 files changed
+40490 -91

No files matched your search

+24
View File
@@ -0,0 +1,24 @@
import { getWebsiteConfig } from "oj/api"
import type { WebsiteConfig } from "utils/types"
export const useConfigStore = defineStore("config", () => {
const config = ref<WebsiteConfig>({
website_base_url: "",
website_name: "",
website_name_shortcut: "",
website_footer: "",
submission_list_show_all: true,
allow_register: false,
class_list: [],
enable_maxkb: true,
})
async function getConfig() {
const res = await getWebsiteConfig()
config.value = res.data
document.title = res.data.website_name
}
return {
config,
getConfig,
}
})