feat: add CI pipeline with ESLint, refactor deploy with rollback + Telegram
Some checks failed
CI / Lint, Test & Build (push) Failing after 5m28s
Deploy to Production / Build and Deploy (push) Has been cancelled

- Add eslint.config.mjs (flat config, eslint-config-next@16 + TypeScript)
- Add .gitea/workflows/ci.yaml (lint, test:unit, build on all branches)
- Refactor deploy.yaml: needs: [ci] gate, Docker rollback tag, Telegram notifications
- Fix 3 pre-existing lint errors (empty interfaces, ts-ignore, require imports)
This commit is contained in:
Antigravity
2026-05-16 21:56:25 +00:00
parent bb75b2e763
commit 93c6bbca85
10 changed files with 4511 additions and 438 deletions

View File

@@ -197,6 +197,7 @@ export const NoteCard = memo(function NoteCard({
const sanitizedHtml = useMemo(() => {
if (note.type !== 'richtext' || !note.content) return ''
if (typeof window !== 'undefined') {
// eslint-disable-next-line @typescript-eslint/no-require-imports
return require('isomorphic-dompurify').sanitize(note.content)
}
return note.content

View File

@@ -85,6 +85,7 @@ function VersionPreview({ entry, language }: { entry: NoteHistoryEntry; language
<MarkdownContent content={entry.content || ''} />
</div>
) : isRt ? (
// eslint-disable-next-line @typescript-eslint/no-require-imports
<div dangerouslySetInnerHTML={{ __html: require('isomorphic-dompurify').sanitize(entry.content || '') }} />
) : (
<pre className="whitespace-pre-wrap font-sans">{entry.content || ''}</pre>

View File

@@ -1,7 +1,7 @@
import * as React from "react"
import { cn } from "@/lib/utils"
export interface LabelProps extends React.LabelHTMLAttributes<HTMLLabelElement> {}
export type LabelProps = React.LabelHTMLAttributes<HTMLLabelElement>
export function Label({ className, ...props }: LabelProps) {
return (