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
5,311 changes: 2,661 additions & 2,650 deletions frontend/package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
},
"dependencies": {
"@ant-design/icons": "^6.3.4",
"antd": "^5.24.5",
"antd": "^6.6.5",
"dayjs": "^1.11.23",
"react": "^18.3.1",
"react-dom": "^18.3.1",
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/AppErrorBoundary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export default class AppErrorBoundary extends Component<Props, State> {
: "界面运行时发生异常,请重新加载后再试。"
}
extra={
<Space direction="vertical" size={8} style={{ width: "100%" }}>
<Space orientation="vertical" size={8} style={{ width: "100%" }}>
<Button type="primary" onClick={this.reload}>
重新加载
</Button>
Expand Down
8 changes: 4 additions & 4 deletions frontend/src/components/AtsCheckPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export default function AtsCheckPanel({ resumeId }: Props) {
}, [data]);

return (
<Space direction="vertical" style={{ width: "100%" }} size="middle">
<Space orientation="vertical" style={{ width: "100%" }} size="middle">
<Space.Compact style={{ width: "100%" }}>
<Input.TextArea
rows={2}
Expand All @@ -64,11 +64,11 @@ export default function AtsCheckPanel({ resumeId }: Props) {
</Button>
</Space.Compact>

{error && <Alert type="error" showIcon message={error} />}
{error && <Alert type="error" showIcon title={error} />}

{data && !loading && (
<>
<Alert type="info" showIcon message={data.disclaimer} />
<Alert type="info" showIcon title={data.disclaimer} />
<Space wrap align="center">
<Typography.Text strong>ATS 参考分</Typography.Text>
<Progress
Expand Down Expand Up @@ -129,7 +129,7 @@ export default function AtsCheckPanel({ resumeId }: Props) {
</Space>
}
>
<Space direction="vertical" style={{ width: "100%" }} size="small">
<Space orientation="vertical" style={{ width: "100%" }} size="small">
{group.issues.map((issue, index) => (
<div
key={index}
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/ExportOptionsModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export default function ExportOptionsModal({ recordId, open, initialPageLimit, o
width="min(560px, 92vw)"
destroyOnHidden
>
<Space direction="vertical" style={{ width: "100%" }} size="middle">
<Space orientation="vertical" style={{ width: "100%" }} size="middle">
<div>
<Typography.Text strong>格式</Typography.Text>
<div style={{ marginTop: 8 }}>
Expand Down
18 changes: 10 additions & 8 deletions frontend/src/components/GenerateResumeModal.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,17 @@ import GenerateResumeModal from "./GenerateResumeModal";
const notices: { title: string; modal?: boolean; confirmLabel?: string }[] = [];

const fakeNotifyHost = {
// antd 6 起通知卡片的标题参数由 message 改名 title(见 utils/taskNotify.ts),
// 假宿主按新形状记录。
notification: {
success: (config: { message: unknown }) =>
notices.push({ title: String(config.message), modal: false }),
warning: (config: { message: unknown }) =>
notices.push({ title: String(config.message), modal: false }),
error: (config: { message: unknown }) =>
notices.push({ title: String(config.message), modal: false }),
info: (config: { message: unknown }) =>
notices.push({ title: String(config.message), modal: false }),
success: (config: { title: unknown }) =>
notices.push({ title: String(config.title), modal: false }),
warning: (config: { title: unknown }) =>
notices.push({ title: String(config.title), modal: false }),
error: (config: { title: unknown }) =>
notices.push({ title: String(config.title), modal: false }),
info: (config: { title: unknown }) =>
notices.push({ title: String(config.title), modal: false }),
},
modal: {
info: (config: { message: unknown; okText?: unknown }) =>
Expand Down
10 changes: 5 additions & 5 deletions frontend/src/components/GenerateResumeModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -377,14 +377,14 @@ export default function GenerateResumeModal({ job, open, initialTitle = "", onCl
type="warning"
showIcon
style={{ marginBottom: 16 }}
message="尚未配置大模型 API,请先到「设置」页完成配置(支持 DeepSeek / 豆包 / Kimi / OpenAI 等)"
title="尚未配置大模型 API,请先到「设置」页完成配置(支持 DeepSeek / 豆包 / Kimi / OpenAI 等)"
/>
) : (
<Alert
type="info"
showIcon
style={{ marginBottom: 16 }}
message={`当前模型:${modelName || "未知"}。生成过程约需 1-2 分钟,生成在后台进行,期间可关闭弹窗,完成后会自动提醒。`}
title={`当前模型:${modelName || "未知"}。生成过程约需 1-2 分钟,生成在后台进行,期间可关闭弹窗,完成后会自动提醒。`}
description={
job
? "系统会根据目标岗位的 JD,从完整个人资料与经历总结文件中筛选并排序相关信息;原始资料不会被修改。"
Expand All @@ -406,7 +406,7 @@ export default function GenerateResumeModal({ job, open, initialTitle = "", onCl
</div>
)}
<Typography.Title level={5}>{job ? "岗位适配与内容美化" : "内容美化"}</Typography.Title>
<Space direction="vertical" size={14} style={{ width: "100%" }}>
<Space orientation="vertical" size={14} style={{ width: "100%" }}>
<Space size={10}>
<Switch checked={enhance} onChange={setEnhance} />
<Typography.Text strong>
Expand Down Expand Up @@ -492,7 +492,7 @@ export default function GenerateResumeModal({ job, open, initialTitle = "", onCl
type="info"
showIcon
style={{ marginBottom: 16 }}
message="生成已在后台开始:现在关闭弹窗不会中断,完成后会自动提醒并打开结果。"
title="生成已在后台开始:现在关闭弹窗不会中断,完成后会自动提醒并打开结果。"
/>
<div style={{ marginTop: 16, textAlign: "right" }}>
<Space>
Expand Down Expand Up @@ -542,7 +542,7 @@ export default function GenerateResumeModal({ job, open, initialTitle = "", onCl
<Alert
type="error"
showIcon
message={errorMsg || "生成失败"}
title={errorMsg || "生成失败"}
style={{ marginBottom: 24 }}
/>
<Space>
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/components/InterviewExperiencePanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ export default function InterviewExperiencePanel({ jobOptions }: Props) {
};

return (
<Space direction="vertical" style={{ width: "100%" }} size="middle">
<Space orientation="vertical" style={{ width: "100%" }} size="middle">
<Card size="small" title="面经知识库">
<Space wrap>
<Input.Search
Expand Down Expand Up @@ -212,7 +212,7 @@ export default function InterviewExperiencePanel({ jobOptions }: Props) {
</Space>
}
description={
<Space direction="vertical" size={2} style={{ width: "100%" }}>
<Space orientation="vertical" size={2} style={{ width: "100%" }}>
<Typography.Text type="secondary">
{item.company}
{item.position ? ` · ${item.position}` : ""}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ describe("InterviewReviewPanel 自动保存与历史富还原", () => {
// 选简历后点击「反向优化简历」。
const resumeSelect = screen
.getByText("关联简历(反向优化必选)")
.closest(".ant-select-selector");
.closest(".ant-select-content");
fireEvent.mouseDown(resumeSelect!);
fireEvent.click(await screen.findByText("我的简历"));

Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/InterviewReviewPanel.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ describe("InterviewReviewPanel", () => {
// 选简历后再次点击:产出建议列表。
const resumeSelect = screen
.getByText("关联简历(反向优化必选)")
.closest(".ant-select-selector");
.closest(".ant-select-content");
fireEvent.mouseDown(resumeSelect!);
fireEvent.click(await screen.findByText("我的简历"));

Expand Down
22 changes: 9 additions & 13 deletions frontend/src/components/InterviewReviewPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ export default function InterviewReviewPanel({
</Space>
),
children: (
<Space direction="vertical" style={{ width: "100%" }}>
<Space orientation="vertical" style={{ width: "100%" }}>
{review.questions.length > 0 && (
<>
<Typography.Text strong>真实问题</Typography.Text>
Expand Down Expand Up @@ -275,12 +275,12 @@ export default function InterviewReviewPanel({
}));

return (
<Space direction="vertical" style={{ width: "100%" }} size="middle">
<Space orientation="vertical" style={{ width: "100%" }} size="middle">
{record && (
<Alert
type="info"
showIcon
message={`正在查看历史复盘 #${record.id}(${record.created_at.replace("T", " ").slice(0, 16)})`}
title={`正在查看历史复盘 #${record.id}(${record.created_at.replace("T", " ").slice(0, 16)})`}
action={
onCloseRecord && (
<Button size="small" onClick={onCloseRecord}>
Expand All @@ -293,7 +293,7 @@ export default function InterviewReviewPanel({

{!record && (
<Card size="small" title="面试复盘">
<Space direction="vertical" style={{ width: "100%" }} size={8}>
<Space orientation="vertical" style={{ width: "100%" }} size={8}>
<Input.TextArea
value={question}
autoSize={{ minRows: 2, maxRows: 4 }}
Expand Down Expand Up @@ -410,7 +410,7 @@ export default function InterviewReviewPanel({
<Alert
type="warning"
showIcon
message="此为旧版记录,仅可查看"
title="此为旧版记录,仅可查看"
description="旧版历史以纯文本保存,无法还原为结构化复盘,仅展示原始内容。"
/>
<Typography.Paragraph style={{ marginTop: 8, whiteSpace: "pre-wrap" }}>
Expand All @@ -421,11 +421,7 @@ export default function InterviewReviewPanel({
viewSuggestions.length > 0 && (
<Card size="small" title="简历改进建议">
{viewSuggestions.length === 0 ? (
<Alert
type="info"
showIcon
message="没有产出建议,试试补充更多面试暴露的短板或追问"
/>
<Alert type="info" showIcon title="没有产出建议,试试补充更多面试暴露的短板或追问" />
) : (
<List
dataSource={viewSuggestions}
Expand All @@ -440,7 +436,7 @@ export default function InterviewReviewPanel({
</Space>
}
description={
<Space direction="vertical" size={2} style={{ width: "100%" }}>
<Space orientation="vertical" size={2} style={{ width: "100%" }}>
<span>
<BulbOutlined /> {item.suggestion}
</span>
Expand Down Expand Up @@ -475,9 +471,9 @@ export default function InterviewReviewPanel({
}
>
{reviews.loading && !reviews.data ? (
<Alert type="info" showIcon message="加载中…" />
<Alert type="info" showIcon title="加载中…" />
) : reviews.error ? (
<Alert type="error" showIcon message={reviews.error} />
<Alert type="error" showIcon title={reviews.error} />
) : (reviews.data ?? []).length === 0 ? (
<Empty image={Empty.PRESENTED_IMAGE_SIMPLE} description="还没有保存过复盘" />
) : (
Expand Down
10 changes: 5 additions & 5 deletions frontend/src/components/JobAnalysisModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ export default function JobAnalysisModal({ job, onClose }: Props) {
destroyOnHidden
>
{error ? (
<Space direction="vertical" style={{ width: "100%" }}>
<Alert type="error" showIcon message={error} />
<Space orientation="vertical" style={{ width: "100%" }}>
<Alert type="error" showIcon title={error} />
<Button
aria-label="重新生成解读"
icon={<ReloadOutlined />}
Expand All @@ -104,7 +104,7 @@ export default function JobAnalysisModal({ job, onClose }: Props) {
type="info"
showIcon
style={{ marginTop: 12 }}
message="生成期间可以关掉这个弹窗去做别的,完成后会提醒你(弹窗 + 提示音)。"
title="生成期间可以关掉这个弹窗去做别的,完成后会提醒你(弹窗 + 提示音)。"
/>
<div style={{ marginTop: 12, textAlign: "right" }}>
<Button
Expand Down Expand Up @@ -146,7 +146,7 @@ export default function JobAnalysisModal({ job, onClose }: Props) {
const priority = PRIORITY_META[item.priority];
return (
<List.Item>
<Space direction="vertical" size={5} style={{ width: "100%" }}>
<Space orientation="vertical" size={5} style={{ width: "100%" }}>
<Space wrap>
<Tag color={priority.color}>{priority.label}</Tag>
{item.category && <Tag>{item.category}</Tag>}
Expand All @@ -170,7 +170,7 @@ export default function JobAnalysisModal({ job, onClose }: Props) {
dataSource={data.advice}
renderItem={(item) => (
<List.Item>
<Space direction="vertical" size={4}>
<Space orientation="vertical" size={4}>
<Typography.Text strong>{item.title}</Typography.Text>
<Typography.Text>{item.action}</Typography.Text>
{item.rationale && (
Expand Down
6 changes: 3 additions & 3 deletions frontend/src/components/JobDetailDrawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export default function JobDetailDrawer({
return (
<Drawer
title="岗位详情"
width="min(640px, 100vw)"
size="min(640px, 100vw)"
open={!!job}
onClose={onClose}
// 操作栏交给抽屉的 footer 插槽:它由抽屉布局常驻底部,内容不足一屏时
Expand Down Expand Up @@ -176,7 +176,7 @@ export default function JobDetailDrawer({
type="info"
showIcon
style={{ marginTop: 12 }}
message="这个岗位不能用投递台自动投递"
title="这个岗位不能用投递台自动投递"
description={
<Typography.Text type="secondary">
投递台只能自动投递<Typography.Text strong>招聘网站上的岗位</Typography.Text>
Expand All @@ -202,7 +202,7 @@ export default function JobDetailDrawer({

{job.keywords.length > 0 && (
<>
<Divider orientation="left" plain style={{ margin: "8px 0" }}>
<Divider titlePlacement="start" plain style={{ margin: "8px 0" }}>
岗位技能标签
</Divider>
<SkillTags tags={job.keywords} max={20} />
Expand Down
6 changes: 3 additions & 3 deletions frontend/src/components/JobFormModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ export default function JobFormModal({
confirmLoading={submitting}
okButtonProps={{ disabled: parsing || submitting }}
cancelButtonProps={{ disabled: submitting }}
maskClosable={!submitting}
mask={{ closable: !submitting }}
closable={!submitting}
width={720}
styles={{
Expand Down Expand Up @@ -430,7 +430,7 @@ export default function JobFormModal({
<Alert
type="warning"
showIcon
message={parseWarnings.join(";")}
title={parseWarnings.join(";")}
style={{ marginBottom: 16 }}
/>
)}
Expand Down Expand Up @@ -500,7 +500,7 @@ export default function JobFormModal({
/>
</Form.Item>
<Form.Item label={`备注图片(选填,最多 ${MAX_NOTE_IMAGES} 张)`}>
<Space direction="vertical" style={{ width: "100%" }}>
<Space orientation="vertical" style={{ width: "100%" }}>
<Space wrap>
<Upload
accept="image/jpeg,image/png,image/webp"
Expand Down
14 changes: 7 additions & 7 deletions frontend/src/components/JobMatchBatchPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ function ConditionList({ conditions }: { conditions: MatchCondition[] }) {
const meta = MATCH_STATUS_META[condition.status];
return (
<List.Item>
<Space direction="vertical" size={2} style={{ width: "100%" }}>
<Space orientation="vertical" size={2} style={{ width: "100%" }}>
<Space size={6} wrap>
<Tag color={meta.color}>{meta.label}</Tag>
<Typography.Text strong>{condition.label}</Typography.Text>
Expand All @@ -97,7 +97,7 @@ function MatchDetail({ item }: { item: JobMatchBatchItem }) {
if (!result) return null;
const admission = ADMISSION_META[result.admission];
return (
<Space direction="vertical" size="small" style={{ width: "100%" }}>
<Space orientation="vertical" size="small" style={{ width: "100%" }}>
<Space wrap>
<Tag color={admission.color}>准入:{admission.label}</Tag>
<Tag>
Expand All @@ -123,7 +123,7 @@ function BatchItemCard({ item }: { item: JobMatchBatchItem }) {
if (item.status === "failed") {
return (
<Card size="small" title={`${item.job_title}${item.company ? ` · ${item.company}` : ""}`}>
<Alert type="error" showIcon message={item.error || "本岗位分析失败"} />
<Alert type="error" showIcon title={item.error || "本岗位分析失败"} />
</Card>
);
}
Expand All @@ -150,7 +150,7 @@ function BatchItemCard({ item }: { item: JobMatchBatchItem }) {
percent={score}
format={(value) => <span>{value}</span>}
/>
<Space direction="vertical" size={2}>
<Space orientation="vertical" size={2}>
<Typography.Text strong>匹配度参考分:{score}</Typography.Text>
<Typography.Text type="secondary">
{item.result ? `准入:${ADMISSION_META[item.result.admission].label}` : "暂无结论"}
Expand Down Expand Up @@ -269,11 +269,11 @@ export default function JobMatchBatchPanel({
loading && !batch ? (
<Skeleton active paragraph={{ rows: 8 }} />
) : batch ? (
<Space direction="vertical" size="middle" style={{ width: "100%" }}>
<Space orientation="vertical" size="middle" style={{ width: "100%" }}>
<Alert
type={batch.failed_count > 0 ? "warning" : "success"}
showIcon
message={`已完成 ${batch.completed_count} 个岗位,${batch.failed_count} 个岗位失败`}
title={`已完成 ${batch.completed_count} 个岗位,${batch.failed_count} 个岗位失败`}
description={`结果已保存,可在「历史记录」中回看;已按匹配度参考分从高到低排列。${batch.model ? `本批使用模型:${batch.model}` : "本批未配置模型,使用本地降级结果。"}`}
/>
<List
Expand Down Expand Up @@ -339,7 +339,7 @@ export default function JobMatchBatchPanel({
</Space>
}
>
{error ? <Alert type="error" showIcon message={error} style={{ marginBottom: 12 }} /> : null}
{error ? <Alert type="error" showIcon title={error} style={{ marginBottom: 12 }} /> : null}
<Tabs
activeKey={activeTab}
onChange={setActiveTab}
Expand Down
Loading
Loading