style(格式化): 改成单引号、一行最长 160,全仓重新格式化
Deploy / deploy (push) Canceled after 0s

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
xuyueandClaude Opus 5.5 committed 2026-10-26 13:52:24 +08:00
1 parent 530e1a3d5d
commit 195069450f
480 files changed
+15507 -24650

No files matched your search

+5 -7
View File
@@ -1,9 +1,9 @@
import { and, asc, eq, inArray, isNull, sql } from "drizzle-orm"
import { and, asc, eq, inArray, isNull, sql } from 'drizzle-orm'
import { db, schema } from "../db"
import { db, schema } from '../db'
/** 「去做几道题」里优先推荐、要标出来的那批题挂的标签 */
export const MUST_DO_TAG = "必会题"
export const MUST_DO_TAG = '必会题'
const PROJECT_RE = /\*\*所属项目[::]\s*([^*\n]+)\*\*/
@@ -12,7 +12,7 @@ const PROJECT_RE = /\*\*所属项目[::]\s*([^*\n]+)\*\*/
* 和 0031 迁移回填用的是同一个写法;发布脚本不传 `project` 时靠它。
*/
export function projectFromContent(content: string) {
return (content.match(PROJECT_RE)?.[1] ?? "").trim().slice(0, 64)
return (content.match(PROJECT_RE)?.[1] ?? '').trim().slice(0, 64)
}
/**
@@ -61,9 +61,7 @@ export async function tutorialProblems(tutorialIds: number[], publicOnly: boolea
.where(
and(
inArray(schema.tutorialProblem.tutorialId, tutorialIds),
publicOnly
? and(eq(schema.problem.visible, true), isNull(schema.problem.contestId))
: undefined,
publicOnly ? and(eq(schema.problem.visible, true), isNull(schema.problem.contestId)) : undefined,
),
)
.orderBy(asc(schema.tutorialProblem.tutorialId), asc(schema.tutorialProblem.order))