eli-video-interview 1.2.41-alpha.13 → 1.2.41-alpha.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. package/esm/enum/ai-report.d.ts +12 -0
  2. package/esm/enum/ai-report.js +12 -0
  3. package/esm/modules/ai-ability/components/AbilityFormItem/index.js +3 -3
  4. package/esm/modules/ai-report/components/ScoreReport/Bar.js +1 -1
  5. package/esm/modules/ai-report/components/ScoreReport/Failed.d.ts +1 -1
  6. package/esm/modules/ai-report/components/ScoreReport/Failed.js +8 -4
  7. package/esm/modules/ai-report/components/ScoreReport/Score.js +3 -14
  8. package/esm/modules/ai-report/components/ScoreReport/index.js +1 -2
  9. package/esm/modules/ai-report/components/ScoreReport/interface.d.ts +1 -0
  10. package/esm/modules/ai-report/components/WorkPlaces/WorkPlace.d.ts +1 -0
  11. package/esm/modules/ai-report/components/WorkPlaces/WorkPlace.js +2 -1
  12. package/esm/modules/ai-report/components/WorkPlaces/index.js +2 -1
  13. package/esm/services/ai-report.d.ts +1 -0
  14. package/lib/enum/ai-report.d.ts +12 -0
  15. package/lib/enum/ai-report.js +13 -1
  16. package/lib/modules/ai-ability/components/AbilityFormItem/index.js +3 -3
  17. package/lib/modules/ai-report/components/ScoreReport/Bar.js +1 -1
  18. package/lib/modules/ai-report/components/ScoreReport/Failed.d.ts +1 -1
  19. package/lib/modules/ai-report/components/ScoreReport/Failed.js +9 -5
  20. package/lib/modules/ai-report/components/ScoreReport/Score.js +6 -17
  21. package/lib/modules/ai-report/components/ScoreReport/index.js +1 -2
  22. package/lib/modules/ai-report/components/ScoreReport/interface.d.ts +1 -0
  23. package/lib/modules/ai-report/components/WorkPlaces/WorkPlace.d.ts +1 -0
  24. package/lib/modules/ai-report/components/WorkPlaces/WorkPlace.js +2 -1
  25. package/lib/modules/ai-report/components/WorkPlaces/index.js +2 -1
  26. package/lib/services/ai-report.d.ts +1 -0
  27. package/package.json +1 -1
@@ -25,3 +25,15 @@ export declare enum COMPLETED_STATUS {
25
25
  NOT_COMPLETED = 2,
26
26
  COMPLETED = 3
27
27
  }
28
+ export declare const BackgroundImage: {
29
+ pro: string;
30
+ standard: string;
31
+ };
32
+ export declare const Colors: {
33
+ pro: string;
34
+ standard: string;
35
+ };
36
+ export declare const SwitchTitle: {
37
+ standard: string;
38
+ pro: string;
39
+ };
@@ -28,3 +28,15 @@ export var COMPLETED_STATUS;
28
28
  COMPLETED_STATUS[COMPLETED_STATUS["NOT_COMPLETED"] = 2] = "NOT_COMPLETED";
29
29
  COMPLETED_STATUS[COMPLETED_STATUS["COMPLETED"] = 3] = "COMPLETED";
30
30
  })(COMPLETED_STATUS || (COMPLETED_STATUS = {}));
31
+ export var BackgroundImage = {
32
+ pro: 'https://webcdn.fbmms.cn/assets/DPXE/Oj-k12zdt9HuOrcEECDsm',
33
+ standard: 'https://webcdn.fbmms.cn/assets/S3uM/nAU25qJa6bVmZVHpcb11G',
34
+ };
35
+ export var Colors = {
36
+ pro: '#86350F',
37
+ standard: '#4caf50',
38
+ };
39
+ export var SwitchTitle = {
40
+ standard: '升级为高级版',
41
+ pro: '切换为标准版',
42
+ };
@@ -148,9 +148,9 @@ var AbilityFormItem = function (_a) {
148
148
  }
149
149
  }, [item]);
150
150
  return (_jsxs(Stack, { children: [_jsxs(Stack, __assign({ style: { marginBottom: '18px' }, direction: "row", alignItems: "center", justifyContent: "space-between" }, { children: [_jsx(Typography, __assign({ variant: "body2", fontWeight: "medium" }, { children: title })), canReplace && (_jsx(Button, __assign({ loading: loading, onClick: handleReplace, variant: "outlined", color: "inherit", size: "small", icon: _jsx(RefreshIcon, {}) }, { children: loading ? '生成中' : '换一换' })))] })), internalMode === 'edit' && (_jsx(Box, __assign({ width: 1 }, { children: _jsx(FieldArray, __assign({ name: "workPlaceItems[".concat(index, "].items") }, { children: function (_a) {
151
- var _b;
152
- var pushEmail = _a.push, removeEmail = _a.remove;
153
- return (_jsxs(Stack, __assign({ mb: 5 }, { children: [(_b = item === null || item === void 0 ? void 0 : item.items) === null || _b === void 0 ? void 0 : _b.map(function (email, emailIndex) { return (_jsx(Stack, __assign({ direction: "row", alignItems: "center", spacing: 1 }, { children: [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) ? (_jsxs(_Fragment, { children: [_jsx(FormItem, { name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: 512 }, max: maxTextLength }), _jsx(IconButton, __assign({ onClick: function () { return removeEmail(emailIndex); }, sx: { alignSelf: 'flex-start', mt: 0.5 } }, { children: _jsx(CloseIcon, {}) }))] })) : (_jsx(FormItem, { multiline: true, rows: 3, max: maxTextLength, name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: '100%' } })) }), emailIndex)); }), [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) && (_jsx(Button, __assign({ startIcon: _jsx(AddIcon, {}), type: "button", onClick: function () { return pushEmail(''); }, variant: "outlined", color: "inherit", sx: { alignSelf: 'flex-start' } }, { children: { 4: '评分关键点', 5: '面试题目' }[item.type] })))] })));
151
+ var _b, _c;
152
+ var pushItem = _a.push, removeItem = _a.remove;
153
+ return (_jsxs(Stack, __assign({ mb: 5 }, { children: [(_b = item === null || item === void 0 ? void 0 : item.items) === null || _b === void 0 ? void 0 : _b.map(function (email, emailIndex) { return (_jsx(Stack, __assign({ direction: "row", alignItems: "center", spacing: 1 }, { children: [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) ? (_jsxs(_Fragment, { children: [_jsx(FormItem, { name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: 512 }, max: maxTextLength }), _jsx(IconButton, __assign({ onClick: function () { return removeItem(emailIndex); }, sx: { alignSelf: 'flex-start', mt: 0.5 } }, { children: _jsx(CloseIcon, {}) }))] })) : (_jsx(FormItem, { multiline: true, rows: 3, max: maxTextLength, name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: '100%' } })) }), emailIndex)); }), [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) && (_jsx(Button, __assign({ sx: { alignSelf: 'flex-start', display: "".concat(((_c = item === null || item === void 0 ? void 0 : item.items) === null || _c === void 0 ? void 0 : _c.length) >= 3 ? 'none' : 'flex') }, startIcon: _jsx(AddIcon, {}), type: "button", onClick: function () { return pushItem(''); }, variant: "outlined", color: "inherit" }, { children: { 5: '评分关键点', 4: '面试题目' }[item.type] })))] })));
154
154
  } })) }))), internalMode === 'show' && (_jsx(Box, __assign({ style: { marginTop: '-8px', marginBottom: '32px' } }, { children: _jsx(Typography, __assign({ variant: "body2", sx: { whiteSpace: 'pre-wrap', color: 'RGBA(0, 0, 0, 0.56)' } }, { children: content })) })))] }));
155
155
  };
156
156
  export default AbilityFormItem;
@@ -60,7 +60,7 @@ var Bar = function (_a) {
60
60
  width: "".concat((endRankProportion - startRankProportion) * 100, "%"),
61
61
  height: currentRank === rank ? 'calc(100% + 4px)' : '100%',
62
62
  background: (_b = scoreRankIntervalModeColors === null || scoreRankIntervalModeColors === void 0 ? void 0 : scoreRankIntervalModeColors[model]) === null || _b === void 0 ? void 0 : _b[index],
63
- border: '1px solid rgb(255, 255, 255)',
63
+ border: '2px solid rgb(255, 255, 255)',
64
64
  } }, rank),
65
65
  ];
66
66
  }) }))] }));
@@ -1,4 +1,4 @@
1
- import { FC } from 'react';
2
1
  import { FailedProps } from './interface';
2
+ import { FC } from 'react';
3
3
  declare const Failed: FC<FailedProps>;
4
4
  export default Failed;
@@ -10,13 +10,17 @@ var __assign = (this && this.__assign) || function () {
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
12
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
- import { Box, Button, CancelIcon, RefreshIcon, Typography } from 'fbm-ui';
13
+ import { BackgroundImage } from "../../../../enum/ai-report";
14
14
  import { INTERVIEW_STATUS } from "../../../../enum/ai-report";
15
+ import { Box, Button, CancelIcon, RefreshIcon, Typography } from 'fbm-ui';
15
16
  var FAILED = INTERVIEW_STATUS.FAILED;
16
17
  var Failed = function (_a) {
17
- var loading = _a.loading, status = _a.status, onRefresh = _a.onRefresh;
18
- return (_jsxs(Box, __assign({ loading: loading, display: "flex", alignItems: "center", padding: "32px 24px" }, { children: [status === FAILED && (_jsx(CancelIcon, { style: {
19
- background: 'white',
18
+ var loading = _a.loading, status = _a.status, onRefresh = _a.onRefresh, _b = _a.model, model = _b === void 0 ? 'standard' : _b;
19
+ return (_jsxs(Box, __assign({ loading: loading, display: "flex", alignItems: "center", padding: "32px 24px", sx: {
20
+ px: 3,
21
+ height: 280,
22
+ background: "url('".concat(BackgroundImage[model], "') no-repeat center center / contain"),
23
+ } }, { children: [status === FAILED && (_jsx(CancelIcon, { style: {
20
24
  color: '#ff6c6c',
21
25
  width: '24px',
22
26
  height: '24px',
@@ -31,6 +31,7 @@ import Bar from './Bar';
31
31
  import RecommendIcon from './RecommendIcon';
32
32
  import { RefreshIconRoot, ScoreTypography, ScoreUnitTypography } from './styled';
33
33
  import Tips from './Tips';
34
+ import { BackgroundImage, Colors, SwitchTitle } from "../../../../enum/ai-report";
34
35
  import { useAiReportStore } from "../../../../store/ai-report/global-store";
35
36
  import { formatScore } from "../../../../utils/utils";
36
37
  import dayjs from 'dayjs';
@@ -38,18 +39,6 @@ import { SwitchIcon } from 'fbm-icons';
38
39
  import { Box, Button, DownloadIcon, InfoOutlineIcon, Popover, Typography } from 'fbm-ui';
39
40
  import { Stack } from 'fbm-ui/lib/mui';
40
41
  import { useEffect, useState } from 'react';
41
- var BackgroundImage = {
42
- pro: 'https://webcdn.fbmms.cn/assets/DPXE/Oj-k12zdt9HuOrcEECDsm',
43
- standard: 'https://webcdn.fbmms.cn/assets/S3uM/nAU25qJa6bVmZVHpcb11G',
44
- };
45
- var Colors = {
46
- pro: '#86350F',
47
- standard: '#4caf50',
48
- };
49
- var SwitchTitle = {
50
- standard: '升级为高级版',
51
- pro: '切换为标准版',
52
- };
53
42
  var Score = function (_a) {
54
43
  var customScore = _a.customScore, loading = _a.loading, onRefresh = _a.onRefresh, onSwitchReportModel = _a.onSwitchReportModel, _b = _a.model, model = _b === void 0 ? 'standard' : _b;
55
44
  var _c = __read(useState(false), 2), openRankingRange = _c[0], setOpenRankingRange = _c[1];
@@ -85,13 +74,13 @@ var Score = function (_a) {
85
74
  '&:hover': {
86
75
  borderColor: 'inherit',
87
76
  },
88
- }, onClick: onExportReportClick }, { children: "\u5BFC\u51FA\u62A5\u544A" })), _jsx(Button, __assign({ variant: "outlined", size: "small", icon: _jsx(SwitchIcon, {}), sx: {
77
+ }, onClick: onExportReportClick }, { children: "\u5BFC\u51FA\u62A5\u544A" })), _jsx(Button, __assign({ variant: "outlined", size: "small", loading: loading, icon: _jsx(SwitchIcon, {}), sx: {
89
78
  ml: 1,
90
79
  color: 'inherit',
91
80
  borderColor: 'inherit',
92
81
  '&:hover': {
93
82
  borderColor: 'inherit',
94
83
  },
95
- }, onClick: onSwitchReportModel }, { children: SwitchTitle[model] })), _jsx(Popover, __assign({ arrow: false, content: Tips }, { children: _jsx(InfoOutlineIcon, { htmlColor: "inherit", sx: { cursor: 'pointer' } }) }))] })) })), _jsxs(Box, __assign({ display: "flex", alignItems: "center", height: 80, color: Colors[model] }, { children: [_jsxs(Stack, __assign({ direction: "row", alignItems: "center" }, { children: [_jsx(ScoreTypography, __assign({ color: "inherit" }, { children: formatScore(feScore || 0) })), _jsx(ScoreUnitTypography, __assign({ color: "inherit", sx: { alignSelf: 'flex-end' } }, { children: "\u5206" }))] })), _jsx(Box, __assign({ width: 200, ml: 5, color: Colors[model] }, { children: _jsx(Bar, { model: model }) }))] })), _jsxs(Stack, __assign({ direction: "row", justifyContent: "space-between", color: Colors[model] }, { children: [_jsxs(Box, __assign({ display: "flex", alignItems: "center", mt: 1, sx: { alignSelf: 'flex-start' } }, { children: [(operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('refresh')) && (_jsx(Popover, __assign({ open: openRefresh, content: content, onClickAway: function () { return setOpenRefresh(false); } }, { children: _jsx(RefreshIconRoot, { htmlColor: "inherit", onClick: function () { return setOpenRefresh(true); } }) }))), _jsxs(Typography, __assign({ variant: "caption", color: "inherit", ml: 0.5 }, { children: ["\u62A5\u544A\u751F\u6210\u4E8E ", dayjs(createTime && createTime * 1000).format('YYYY-MM-DD HH:mm')] })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('scoreRank')) && (_jsx(Typography, __assign({ color: "inherit", sx: { textDecoration: 'underline', cursor: 'pointer', ml: 1.5 }, onClick: function () { return setOpenRankingRange(true); } }, { children: "\u6392\u540D\u533A\u95F4\u8BBE\u7F6E" })))] })), _jsx(Box, __assign({ width: 120, height: 120, sx: { marginTop: -3 } }, { children: !!feScore && feScore >= 80 && _jsx(RecommendIcon, { size: 120, sx: { width: 120, height: 120 }, htmlColor: Colors[model] }) }))] }))] })));
84
+ }, onClick: onSwitchReportModel }, { children: SwitchTitle[model] })), _jsx(Popover, __assign({ arrow: false, content: Tips, trigger: "hover" }, { children: _jsx(InfoOutlineIcon, { htmlColor: "inherit", sx: { cursor: 'pointer' } }) }))] })) })), _jsxs(Box, __assign({ display: "flex", alignItems: "center", height: 80, color: Colors[model] }, { children: [_jsxs(Stack, __assign({ direction: "row", alignItems: "center" }, { children: [_jsx(ScoreTypography, __assign({ color: "inherit" }, { children: formatScore(feScore || 0) })), _jsx(ScoreUnitTypography, __assign({ color: "inherit", sx: { alignSelf: 'flex-end' } }, { children: "\u5206" }))] })), _jsx(Box, __assign({ width: 200, ml: 5, color: Colors[model] }, { children: _jsx(Bar, { model: model }) }))] })), _jsxs(Stack, __assign({ direction: "row", justifyContent: "space-between", color: Colors[model] }, { children: [_jsxs(Box, __assign({ display: "flex", alignItems: "center", mt: 1, sx: { alignSelf: 'flex-start' } }, { children: [(operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('refresh')) && (_jsx(Popover, __assign({ open: openRefresh, content: content, onClickAway: function () { return setOpenRefresh(false); } }, { children: _jsx(RefreshIconRoot, { htmlColor: "inherit", onClick: function () { return setOpenRefresh(true); } }) }))), _jsxs(Typography, __assign({ variant: "caption", color: "inherit", ml: 0.5 }, { children: ["\u62A5\u544A\u751F\u6210\u4E8E ", dayjs(createTime && createTime * 1000).format('YYYY-MM-DD HH:mm')] })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('scoreRank')) && (_jsx(Typography, __assign({ color: "inherit", sx: { textDecoration: 'underline', cursor: 'pointer', ml: 1.5 }, onClick: function () { return setOpenRankingRange(true); } }, { children: "\u6392\u540D\u533A\u95F4\u8BBE\u7F6E" })))] })), _jsx(Box, __assign({ width: 120, height: 120, sx: { marginTop: -3 } }, { children: !!feScore && feScore >= 80 && _jsx(RecommendIcon, { size: 120, sx: { width: 120, height: 120 }, htmlColor: Colors[model] }) }))] }))] })));
96
85
  };
97
86
  export default Score;
@@ -17,7 +17,6 @@ import { PostAiInterviewRefresh } from "../../../../services/ai-report";
17
17
  import { useAiReportStore } from "../../../../store/ai-report/global-store";
18
18
  import { useRequest } from 'ahooks';
19
19
  import { Box, Message } from 'fbm-ui';
20
- import { Paper } from 'fbm-ui/lib/mui';
21
20
  var FAILED = INTERVIEW_STATUS.FAILED, IN_CALCULATION = INTERVIEW_STATUS.IN_CALCULATION;
22
21
  var ScoreReport = function (_a) {
23
22
  var customScore = _a.customScore, onRefreshSuccess = _a.onRefreshSuccess, onSwitchReportModel = _a.onSwitchReportModel;
@@ -31,7 +30,7 @@ var ScoreReport = function (_a) {
31
30
  },
32
31
  }), run = _e.run, loading = _e.loading;
33
32
  if ([FAILED, IN_CALCULATION].includes(status)) {
34
- return (_jsx(Paper, __assign({ id: "report-score", variant: "outlined" }, { children: _jsx(Failed, { status: status, loading: loading, onRefresh: run }) })));
33
+ return (_jsx(Box, __assign({ id: "report-score" }, { children: _jsx(Failed, { status: status, loading: loading, onRefresh: run }) })));
35
34
  }
36
35
  else {
37
36
  return (_jsx(Box, { children: _jsx(Score, { model: model, customScore: customScore, loading: loading, onRefresh: run, onSwitchReportModel: onSwitchReportModel }) }));
@@ -15,4 +15,5 @@ export interface ScoreProps {
15
15
  }
16
16
  export interface FailedProps extends ScoreProps {
17
17
  status?: number;
18
+ model?: 'pro' | 'standard';
18
19
  }
@@ -6,6 +6,7 @@ interface WorkplaceProps {
6
6
  bgcolor?: string;
7
7
  mode?: Mode;
8
8
  canEdit?: boolean;
9
+ thirdOrderID: string;
9
10
  }
10
11
  declare const Evaluate: React.FC<WorkplaceProps>;
11
12
  export default Evaluate;
@@ -31,7 +31,7 @@ import { Button, confirm, EditIcon, FormItem, IconButton, Typography } from 'fbm
31
31
  import { Box, Stack } from 'fbm-ui/lib/mui';
32
32
  import { useCallback, useEffect, useState } from 'react';
33
33
  var Evaluate = function (_a) {
34
- var answer = _a.answer, token = _a.token, bgcolor = _a.bgcolor, _b = _a.mode, mode = _b === void 0 ? 'show' : _b, _c = _a.canEdit, canEdit = _c === void 0 ? 'true' : _c;
34
+ var answer = _a.answer, token = _a.token, thirdOrderID = _a.thirdOrderID, bgcolor = _a.bgcolor, _b = _a.mode, mode = _b === void 0 ? 'show' : _b, _c = _a.canEdit, canEdit = _c === void 0 ? 'true' : _c;
35
35
  var _d = __read(useState(answer), 2), content = _d[0], setContent = _d[1];
36
36
  var _e = __read(useState('show'), 2), internalMode = _e[0], setInternalMode = _e[1];
37
37
  var handleChange = useCallback(function (e) {
@@ -54,6 +54,7 @@ var Evaluate = function (_a) {
54
54
  var onClose = _a.onClose;
55
55
  var data = {
56
56
  token: token,
57
+ thirdOrderID: thirdOrderID,
57
58
  answer: content,
58
59
  };
59
60
  PostAiInterviewWorkplace(data).then(handleModeChange).then(onClose).catch(console.log);
@@ -60,10 +60,11 @@ var ColorIndexMap = {
60
60
  var Index = function () {
61
61
  var _a;
62
62
  var _b = useAiReportStore(function (store) { return [store.reportResult, store.operableButtons]; }), reportResult = _b.reportResult, showAiDimension = _b.showAiDimension, canEditAiDimension = _b.canEditAiDimension;
63
+ var _c = (reportResult || {}).orderToken, orderToken = _c === void 0 ? '' : _c;
63
64
  if (!showAiDimension)
64
65
  return null;
65
66
  return (_jsxs(Box, __assign({ id: "report-workplace", px: 2, mt: 2 }, { children: [_jsx(Stack, __assign({ direction: "row", height: 56, alignItems: "center", spacing: 1, marginBottom: 1 }, { children: _jsx(AiHeaderTitle, { name: "\u804C\u573A\u80FD\u529B\u8868\u73B0" }) })), _jsx(Collapse, __assign({ in: true }, { children: (_a = reportResult === null || reportResult === void 0 ? void 0 : reportResult.workplaces) === null || _a === void 0 ? void 0 : _a.map(function (v, idx) {
66
- return (_jsxs(Box, __assign({ mb: 2, pb: 2, pr: 2 }, { children: [_jsxs(Box, __assign({ display: "flex", mb: 2, mt: 1, justifyContent: "space-between", alignItems: "center" }, { children: [_jsxs(Box, __assign({ display: "flex", alignItems: "center", maxWidth: "calc(100% - 90px)" }, { children: [_jsx(TagTitle, __assign({ bgcolor: ColorIndexMap[idx % 3][200] }, { children: _jsx(Typography, __assign({ variant: "subtitle1", fontWeight: "medium", style: { lineHeight: '32px', color: '#fff', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis' } }, { children: v.dimensionName })) })), v.dimensionType === 3 && _jsx(Chip, { color: 'primary', label: '自定义', size: "small", sx: { ml: 1 } })] })), _jsx(Tooltip, __assign({ title: _jsxs("span", { children: ["\u9AD8\u5206\u8868\u73B0\uFF1A", v.abilityExpression.good, _jsx("br", {}), "\u4F4E\u5206\u8868\u73B0\uFF1A", v.abilityExpression.bad] }) }, { children: _jsxs(Box, __assign({ display: "flex", alignItems: "center" }, { children: [_jsx(Typography, __assign({ variant: "body2", style: { lineHeight: '32px' }, mr: 1 }, { children: "\u4F18\u6B21\u8868\u73B0" })), _jsx(InfoOutlineIcon, { sx: { fontSize: '16px' } })] })) }))] })), _jsx(Typography, __assign({ variant: "body2", color: "secondary", ml: 2, style: { background: '#F5F5F5', borderRadius: 4, padding: 8 } }, { children: v.define })), _jsxs(Stack, __assign({ pl: 2 }, { children: [_jsx(Box, __assign({ mt: 2 }, { children: _jsx(ScoreSlider, { width: "100%", isShowLabel: true, score: v.score, scoreText: v.scoreText, scoreLevel: v.scoreLevel }) })), _jsx(Stack, __assign({ spacing: 2 }, { children: _jsx(WorkPlace, { token: v.token, canEdit: canEditAiDimension, answer: v.answer, mode: "show", bgcolor: ColorIndexMap[idx % 3][50] }) }))] }))] }), v.token));
67
+ return (_jsxs(Box, __assign({ mb: 2, pb: 2, pr: 2 }, { children: [_jsxs(Box, __assign({ display: "flex", mb: 2, mt: 1, justifyContent: "space-between", alignItems: "center" }, { children: [_jsxs(Box, __assign({ display: "flex", alignItems: "center", maxWidth: "calc(100% - 90px)" }, { children: [_jsx(TagTitle, __assign({ bgcolor: ColorIndexMap[idx % 3][200] }, { children: _jsx(Typography, __assign({ variant: "subtitle1", fontWeight: "medium", style: { lineHeight: '32px', color: '#fff', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis' } }, { children: v.dimensionName })) })), v.dimensionType === 3 && _jsx(Chip, { color: 'primary', label: '自定义', size: "small", sx: { ml: 1 } })] })), _jsx(Tooltip, __assign({ title: _jsxs("span", { children: ["\u9AD8\u5206\u8868\u73B0\uFF1A", v.abilityExpression.good, _jsx("br", {}), "\u4F4E\u5206\u8868\u73B0\uFF1A", v.abilityExpression.bad] }) }, { children: _jsxs(Box, __assign({ display: "flex", alignItems: "center" }, { children: [_jsx(Typography, __assign({ variant: "body2", style: { lineHeight: '32px' }, mr: 1 }, { children: "\u4F18\u6B21\u8868\u73B0" })), _jsx(InfoOutlineIcon, { sx: { fontSize: '16px' } })] })) }))] })), _jsx(Typography, __assign({ variant: "body2", color: "secondary", ml: 2, style: { background: '#F5F5F5', borderRadius: 4, padding: 8 } }, { children: v.define })), _jsxs(Stack, __assign({ pl: 2 }, { children: [_jsx(Box, __assign({ mt: 2 }, { children: _jsx(ScoreSlider, { width: "100%", isShowLabel: true, score: v.score, scoreText: v.scoreText, scoreLevel: v.scoreLevel }) })), _jsx(Stack, __assign({ spacing: 2 }, { children: _jsx(WorkPlace, { thirdOrderID: orderToken, token: v.token, canEdit: canEditAiDimension, answer: v.answer, mode: "show", bgcolor: ColorIndexMap[idx % 3][50] }) }))] }))] }), v.token));
67
68
  }) }))] })));
68
69
  };
69
70
  export default Index;
@@ -7,6 +7,7 @@ interface PostAiInterviewEvaluationData {
7
7
  }
8
8
  export declare const PostAiInterviewEvaluation: <R>(data: PostAiInterviewEvaluationData) => import("axios").AxiosPromise<R>;
9
9
  interface PostAiInterviewWorkplaceData {
10
+ thirdOrderID: string;
10
11
  token: string;
11
12
  answer?: string;
12
13
  }
@@ -25,3 +25,15 @@ export declare enum COMPLETED_STATUS {
25
25
  NOT_COMPLETED = 2,
26
26
  COMPLETED = 3
27
27
  }
28
+ export declare const BackgroundImage: {
29
+ pro: string;
30
+ standard: string;
31
+ };
32
+ export declare const Colors: {
33
+ pro: string;
34
+ standard: string;
35
+ };
36
+ export declare const SwitchTitle: {
37
+ standard: string;
38
+ pro: string;
39
+ };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.COMPLETED_STATUS = exports.INTERVIEW_STEP_STATUS = exports.INTERVIEW_STATUS = void 0;
3
+ exports.SwitchTitle = exports.Colors = exports.BackgroundImage = exports.COMPLETED_STATUS = exports.INTERVIEW_STEP_STATUS = exports.INTERVIEW_STATUS = void 0;
4
4
  /**
5
5
  * AI面试状态(本场面试的状态)
6
6
  */
@@ -31,3 +31,15 @@ var COMPLETED_STATUS;
31
31
  COMPLETED_STATUS[COMPLETED_STATUS["NOT_COMPLETED"] = 2] = "NOT_COMPLETED";
32
32
  COMPLETED_STATUS[COMPLETED_STATUS["COMPLETED"] = 3] = "COMPLETED";
33
33
  })(COMPLETED_STATUS = exports.COMPLETED_STATUS || (exports.COMPLETED_STATUS = {}));
34
+ exports.BackgroundImage = {
35
+ pro: 'https://webcdn.fbmms.cn/assets/DPXE/Oj-k12zdt9HuOrcEECDsm',
36
+ standard: 'https://webcdn.fbmms.cn/assets/S3uM/nAU25qJa6bVmZVHpcb11G',
37
+ };
38
+ exports.Colors = {
39
+ pro: '#86350F',
40
+ standard: '#4caf50',
41
+ };
42
+ exports.SwitchTitle = {
43
+ standard: '升级为高级版',
44
+ pro: '切换为标准版',
45
+ };
@@ -150,9 +150,9 @@ var AbilityFormItem = function (_a) {
150
150
  }
151
151
  }, [item]);
152
152
  return ((0, jsx_runtime_1.jsxs)(mui_1.Stack, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ style: { marginBottom: '18px' }, direction: "row", alignItems: "center", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", fontWeight: "medium" }, { children: title })), canReplace && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ loading: loading, onClick: handleReplace, variant: "outlined", color: "inherit", size: "small", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.RefreshIcon, {}) }, { children: loading ? '生成中' : '换一换' })))] })), internalMode === 'edit' && ((0, jsx_runtime_1.jsx)(mui_1.Box, __assign({ width: 1 }, { children: (0, jsx_runtime_1.jsx)(formik_1.FieldArray, __assign({ name: "workPlaceItems[".concat(index, "].items") }, { children: function (_a) {
153
- var _b;
154
- var pushEmail = _a.push, removeEmail = _a.remove;
155
- return ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ mb: 5 }, { children: [(_b = item === null || item === void 0 ? void 0 : item.items) === null || _b === void 0 ? void 0 : _b.map(function (email, emailIndex) { return ((0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row", alignItems: "center", spacing: 1 }, { children: [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: 512 }, max: maxTextLength }), (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ onClick: function () { return removeEmail(emailIndex); }, sx: { alignSelf: 'flex-start', mt: 0.5 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.CloseIcon, {}) }))] })) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { multiline: true, rows: 3, max: maxTextLength, name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: '100%' } })) }), emailIndex)); }), [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ startIcon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}), type: "button", onClick: function () { return pushEmail(''); }, variant: "outlined", color: "inherit", sx: { alignSelf: 'flex-start' } }, { children: { 4: '评分关键点', 5: '面试题目' }[item.type] })))] })));
153
+ var _b, _c;
154
+ var pushItem = _a.push, removeItem = _a.remove;
155
+ return ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ mb: 5 }, { children: [(_b = item === null || item === void 0 ? void 0 : item.items) === null || _b === void 0 ? void 0 : _b.map(function (email, emailIndex) { return ((0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row", alignItems: "center", spacing: 1 }, { children: [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: 512 }, max: maxTextLength }), (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ onClick: function () { return removeItem(emailIndex); }, sx: { alignSelf: 'flex-start', mt: 0.5 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.CloseIcon, {}) }))] })) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { multiline: true, rows: 3, max: maxTextLength, name: "workPlaceItems[".concat(index, "].items[").concat(emailIndex, "]"), sx: { width: '100%' } })) }), emailIndex)); }), [4, 5].includes(item === null || item === void 0 ? void 0 : item.type) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ sx: { alignSelf: 'flex-start', display: "".concat(((_c = item === null || item === void 0 ? void 0 : item.items) === null || _c === void 0 ? void 0 : _c.length) >= 3 ? 'none' : 'flex') }, startIcon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}), type: "button", onClick: function () { return pushItem(''); }, variant: "outlined", color: "inherit" }, { children: { 5: '评分关键点', 4: '面试题目' }[item.type] })))] })));
156
156
  } })) }))), internalMode === 'show' && ((0, jsx_runtime_1.jsx)(mui_1.Box, __assign({ style: { marginTop: '-8px', marginBottom: '32px' } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", sx: { whiteSpace: 'pre-wrap', color: 'RGBA(0, 0, 0, 0.56)' } }, { children: content })) })))] }));
157
157
  };
158
158
  exports.default = AbilityFormItem;
@@ -62,7 +62,7 @@ var Bar = function (_a) {
62
62
  width: "".concat((endRankProportion - startRankProportion) * 100, "%"),
63
63
  height: currentRank === rank ? 'calc(100% + 4px)' : '100%',
64
64
  background: (_b = ai_report_1.scoreRankIntervalModeColors === null || ai_report_1.scoreRankIntervalModeColors === void 0 ? void 0 : ai_report_1.scoreRankIntervalModeColors[model]) === null || _b === void 0 ? void 0 : _b[index],
65
- border: '1px solid rgb(255, 255, 255)',
65
+ border: '2px solid rgb(255, 255, 255)',
66
66
  } }, rank),
67
67
  ];
68
68
  }) }))] }));
@@ -1,4 +1,4 @@
1
- import { FC } from 'react';
2
1
  import { FailedProps } from './interface';
2
+ import { FC } from 'react';
3
3
  declare const Failed: FC<FailedProps>;
4
4
  export default Failed;
@@ -12,13 +12,17 @@ var __assign = (this && this.__assign) || function () {
12
12
  };
13
13
  Object.defineProperty(exports, "__esModule", { value: true });
14
14
  var jsx_runtime_1 = require("react/jsx-runtime");
15
- var fbm_ui_1 = require("fbm-ui");
16
15
  var ai_report_1 = require("../../../../enum/ai-report");
17
- var FAILED = ai_report_1.INTERVIEW_STATUS.FAILED;
16
+ var ai_report_2 = require("../../../../enum/ai-report");
17
+ var fbm_ui_1 = require("fbm-ui");
18
+ var FAILED = ai_report_2.INTERVIEW_STATUS.FAILED;
18
19
  var Failed = function (_a) {
19
- var loading = _a.loading, status = _a.status, onRefresh = _a.onRefresh;
20
- return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ loading: loading, display: "flex", alignItems: "center", padding: "32px 24px" }, { children: [status === FAILED && ((0, jsx_runtime_1.jsx)(fbm_ui_1.CancelIcon, { style: {
21
- background: 'white',
20
+ var loading = _a.loading, status = _a.status, onRefresh = _a.onRefresh, _b = _a.model, model = _b === void 0 ? 'standard' : _b;
21
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ loading: loading, display: "flex", alignItems: "center", padding: "32px 24px", sx: {
22
+ px: 3,
23
+ height: 280,
24
+ background: "url('".concat(ai_report_1.BackgroundImage[model], "') no-repeat center center / contain"),
25
+ } }, { children: [status === FAILED && ((0, jsx_runtime_1.jsx)(fbm_ui_1.CancelIcon, { style: {
22
26
  color: '#ff6c6c',
23
27
  width: '24px',
24
28
  height: '24px',
@@ -36,6 +36,7 @@ var Bar_1 = __importDefault(require("./Bar"));
36
36
  var RecommendIcon_1 = __importDefault(require("./RecommendIcon"));
37
37
  var styled_1 = require("./styled");
38
38
  var Tips_1 = __importDefault(require("./Tips"));
39
+ var ai_report_1 = require("../../../../enum/ai-report");
39
40
  var global_store_1 = require("../../../../store/ai-report/global-store");
40
41
  var utils_1 = require("../../../../utils/utils");
41
42
  var dayjs_1 = __importDefault(require("dayjs"));
@@ -43,18 +44,6 @@ var fbm_icons_1 = require("fbm-icons");
43
44
  var fbm_ui_1 = require("fbm-ui");
44
45
  var mui_1 = require("fbm-ui/lib/mui");
45
46
  var react_1 = require("react");
46
- var BackgroundImage = {
47
- pro: 'https://webcdn.fbmms.cn/assets/DPXE/Oj-k12zdt9HuOrcEECDsm',
48
- standard: 'https://webcdn.fbmms.cn/assets/S3uM/nAU25qJa6bVmZVHpcb11G',
49
- };
50
- var Colors = {
51
- pro: '#86350F',
52
- standard: '#4caf50',
53
- };
54
- var SwitchTitle = {
55
- standard: '升级为高级版',
56
- pro: '切换为标准版',
57
- };
58
47
  var Score = function (_a) {
59
48
  var customScore = _a.customScore, loading = _a.loading, onRefresh = _a.onRefresh, onSwitchReportModel = _a.onSwitchReportModel, _b = _a.model, model = _b === void 0 ? 'standard' : _b;
60
49
  var _c = __read((0, react_1.useState)(false), 2), openRankingRange = _c[0], setOpenRankingRange = _c[1];
@@ -76,27 +65,27 @@ var Score = function (_a) {
76
65
  return ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ display: "flex", sx: {
77
66
  px: 3,
78
67
  height: 280,
79
- background: "url('".concat(BackgroundImage[model], "') no-repeat center center / contain"),
68
+ background: "url('".concat(ai_report_1.BackgroundImage[model], "') no-repeat center center / contain"),
80
69
  } }, { children: [model === 'pro' && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", justifyContent: "center", width: 92, height: 30, sx: {
81
70
  position: 'absolute',
82
71
  top: 0,
83
72
  left: 0,
84
- backgroundColor: Colors[model],
73
+ backgroundColor: ai_report_1.Colors[model],
85
74
  borderBottomRightRadius: 16,
86
- } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", fontWeight: "medium", color: "white" }, { children: "\u9AD8\u7CBE\u51C6\u5EA6" })) }))), (0, jsx_runtime_1.jsx)(RankingRange_1.default, { open: openRankingRange, onClose: function () { return setOpenRankingRange(false); } }), (0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row", py: 2, justifyContent: "flex-end", spacing: 1, alignContent: "center", color: Colors[model] }, { children: (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('export')) && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", size: "small", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.DownloadIcon, {}), sx: {
75
+ } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", fontWeight: "medium", color: "white" }, { children: "\u9AD8\u7CBE\u51C6\u5EA6" })) }))), (0, jsx_runtime_1.jsx)(RankingRange_1.default, { open: openRankingRange, onClose: function () { return setOpenRankingRange(false); } }), (0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row", py: 2, justifyContent: "flex-end", spacing: 1, alignContent: "center", color: ai_report_1.Colors[model] }, { children: (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('export')) && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", size: "small", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.DownloadIcon, {}), sx: {
87
76
  ml: 1,
88
77
  color: 'inherit',
89
78
  borderColor: 'inherit',
90
79
  '&:hover': {
91
80
  borderColor: 'inherit',
92
81
  },
93
- }, onClick: onExportReportClick }, { children: "\u5BFC\u51FA\u62A5\u544A" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", size: "small", icon: (0, jsx_runtime_1.jsx)(fbm_icons_1.SwitchIcon, {}), sx: {
82
+ }, onClick: onExportReportClick }, { children: "\u5BFC\u51FA\u62A5\u544A" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", size: "small", loading: loading, icon: (0, jsx_runtime_1.jsx)(fbm_icons_1.SwitchIcon, {}), sx: {
94
83
  ml: 1,
95
84
  color: 'inherit',
96
85
  borderColor: 'inherit',
97
86
  '&:hover': {
98
87
  borderColor: 'inherit',
99
88
  },
100
- }, onClick: onSwitchReportModel }, { children: SwitchTitle[model] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ arrow: false, content: Tips_1.default }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoOutlineIcon, { htmlColor: "inherit", sx: { cursor: 'pointer' } }) }))] })) })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 80, color: Colors[model] }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(styled_1.ScoreTypography, __assign({ color: "inherit" }, { children: (0, utils_1.formatScore)(feScore || 0) })), (0, jsx_runtime_1.jsx)(styled_1.ScoreUnitTypography, __assign({ color: "inherit", sx: { alignSelf: 'flex-end' } }, { children: "\u5206" }))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 200, ml: 5, color: Colors[model] }, { children: (0, jsx_runtime_1.jsx)(Bar_1.default, { model: model }) }))] })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", justifyContent: "space-between", color: Colors[model] }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", mt: 1, sx: { alignSelf: 'flex-start' } }, { children: [(operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('refresh')) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: openRefresh, content: content, onClickAway: function () { return setOpenRefresh(false); } }, { children: (0, jsx_runtime_1.jsx)(styled_1.RefreshIconRoot, { htmlColor: "inherit", onClick: function () { return setOpenRefresh(true); } }) }))), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "inherit", ml: 0.5 }, { children: ["\u62A5\u544A\u751F\u6210\u4E8E ", (0, dayjs_1.default)(createTime && createTime * 1000).format('YYYY-MM-DD HH:mm')] })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('scoreRank')) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ color: "inherit", sx: { textDecoration: 'underline', cursor: 'pointer', ml: 1.5 }, onClick: function () { return setOpenRankingRange(true); } }, { children: "\u6392\u540D\u533A\u95F4\u8BBE\u7F6E" })))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 120, height: 120, sx: { marginTop: -3 } }, { children: !!feScore && feScore >= 80 && (0, jsx_runtime_1.jsx)(RecommendIcon_1.default, { size: 120, sx: { width: 120, height: 120 }, htmlColor: Colors[model] }) }))] }))] })));
89
+ }, onClick: onSwitchReportModel }, { children: ai_report_1.SwitchTitle[model] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ arrow: false, content: Tips_1.default, trigger: "hover" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoOutlineIcon, { htmlColor: "inherit", sx: { cursor: 'pointer' } }) }))] })) })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 80, color: ai_report_1.Colors[model] }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(styled_1.ScoreTypography, __assign({ color: "inherit" }, { children: (0, utils_1.formatScore)(feScore || 0) })), (0, jsx_runtime_1.jsx)(styled_1.ScoreUnitTypography, __assign({ color: "inherit", sx: { alignSelf: 'flex-end' } }, { children: "\u5206" }))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 200, ml: 5, color: ai_report_1.Colors[model] }, { children: (0, jsx_runtime_1.jsx)(Bar_1.default, { model: model }) }))] })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", justifyContent: "space-between", color: ai_report_1.Colors[model] }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", mt: 1, sx: { alignSelf: 'flex-start' } }, { children: [(operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('refresh')) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: openRefresh, content: content, onClickAway: function () { return setOpenRefresh(false); } }, { children: (0, jsx_runtime_1.jsx)(styled_1.RefreshIconRoot, { htmlColor: "inherit", onClick: function () { return setOpenRefresh(true); } }) }))), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "inherit", ml: 0.5 }, { children: ["\u62A5\u544A\u751F\u6210\u4E8E ", (0, dayjs_1.default)(createTime && createTime * 1000).format('YYYY-MM-DD HH:mm')] })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('scoreRank')) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ color: "inherit", sx: { textDecoration: 'underline', cursor: 'pointer', ml: 1.5 }, onClick: function () { return setOpenRankingRange(true); } }, { children: "\u6392\u540D\u533A\u95F4\u8BBE\u7F6E" })))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 120, height: 120, sx: { marginTop: -3 } }, { children: !!feScore && feScore >= 80 && (0, jsx_runtime_1.jsx)(RecommendIcon_1.default, { size: 120, sx: { width: 120, height: 120 }, htmlColor: ai_report_1.Colors[model] }) }))] }))] })));
101
90
  };
102
91
  exports.default = Score;
@@ -22,7 +22,6 @@ var ai_report_2 = require("../../../../services/ai-report");
22
22
  var global_store_1 = require("../../../../store/ai-report/global-store");
23
23
  var ahooks_1 = require("ahooks");
24
24
  var fbm_ui_1 = require("fbm-ui");
25
- var mui_1 = require("fbm-ui/lib/mui");
26
25
  var FAILED = ai_report_1.INTERVIEW_STATUS.FAILED, IN_CALCULATION = ai_report_1.INTERVIEW_STATUS.IN_CALCULATION;
27
26
  var ScoreReport = function (_a) {
28
27
  var customScore = _a.customScore, onRefreshSuccess = _a.onRefreshSuccess, onSwitchReportModel = _a.onSwitchReportModel;
@@ -36,7 +35,7 @@ var ScoreReport = function (_a) {
36
35
  },
37
36
  }), run = _e.run, loading = _e.loading;
38
37
  if ([FAILED, IN_CALCULATION].includes(status)) {
39
- return ((0, jsx_runtime_1.jsx)(mui_1.Paper, __assign({ id: "report-score", variant: "outlined" }, { children: (0, jsx_runtime_1.jsx)(Failed_1.default, { status: status, loading: loading, onRefresh: run }) })));
38
+ return ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ id: "report-score" }, { children: (0, jsx_runtime_1.jsx)(Failed_1.default, { status: status, loading: loading, onRefresh: run }) })));
40
39
  }
41
40
  else {
42
41
  return ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, { children: (0, jsx_runtime_1.jsx)(Score_1.default, { model: model, customScore: customScore, loading: loading, onRefresh: run, onSwitchReportModel: onSwitchReportModel }) }));
@@ -15,4 +15,5 @@ export interface ScoreProps {
15
15
  }
16
16
  export interface FailedProps extends ScoreProps {
17
17
  status?: number;
18
+ model?: 'pro' | 'standard';
18
19
  }
@@ -6,6 +6,7 @@ interface WorkplaceProps {
6
6
  bgcolor?: string;
7
7
  mode?: Mode;
8
8
  canEdit?: boolean;
9
+ thirdOrderID: string;
9
10
  }
10
11
  declare const Evaluate: React.FC<WorkplaceProps>;
11
12
  export default Evaluate;
@@ -33,7 +33,7 @@ var fbm_ui_1 = require("fbm-ui");
33
33
  var mui_1 = require("fbm-ui/lib/mui");
34
34
  var react_1 = require("react");
35
35
  var Evaluate = function (_a) {
36
- var answer = _a.answer, token = _a.token, bgcolor = _a.bgcolor, _b = _a.mode, mode = _b === void 0 ? 'show' : _b, _c = _a.canEdit, canEdit = _c === void 0 ? 'true' : _c;
36
+ var answer = _a.answer, token = _a.token, thirdOrderID = _a.thirdOrderID, bgcolor = _a.bgcolor, _b = _a.mode, mode = _b === void 0 ? 'show' : _b, _c = _a.canEdit, canEdit = _c === void 0 ? 'true' : _c;
37
37
  var _d = __read((0, react_1.useState)(answer), 2), content = _d[0], setContent = _d[1];
38
38
  var _e = __read((0, react_1.useState)('show'), 2), internalMode = _e[0], setInternalMode = _e[1];
39
39
  var handleChange = (0, react_1.useCallback)(function (e) {
@@ -56,6 +56,7 @@ var Evaluate = function (_a) {
56
56
  var onClose = _a.onClose;
57
57
  var data = {
58
58
  token: token,
59
+ thirdOrderID: thirdOrderID,
59
60
  answer: content,
60
61
  };
61
62
  (0, ai_report_1.PostAiInterviewWorkplace)(data).then(handleModeChange).then(onClose).catch(console.log);
@@ -65,10 +65,11 @@ var ColorIndexMap = {
65
65
  var Index = function () {
66
66
  var _a;
67
67
  var _b = (0, global_store_1.useAiReportStore)(function (store) { return [store.reportResult, store.operableButtons]; }), reportResult = _b.reportResult, showAiDimension = _b.showAiDimension, canEditAiDimension = _b.canEditAiDimension;
68
+ var _c = (reportResult || {}).orderToken, orderToken = _c === void 0 ? '' : _c;
68
69
  if (!showAiDimension)
69
70
  return null;
70
71
  return ((0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ id: "report-workplace", px: 2, mt: 2 }, { children: [(0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row", height: 56, alignItems: "center", spacing: 1, marginBottom: 1 }, { children: (0, jsx_runtime_1.jsx)(AiHeaderTitle_1.default, { name: "\u804C\u573A\u80FD\u529B\u8868\u73B0" }) })), (0, jsx_runtime_1.jsx)(mui_1.Collapse, __assign({ in: true }, { children: (_a = reportResult === null || reportResult === void 0 ? void 0 : reportResult.workplaces) === null || _a === void 0 ? void 0 : _a.map(function (v, idx) {
71
- return ((0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ mb: 2, pb: 2, pr: 2 }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", mb: 2, mt: 1, justifyContent: "space-between", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", alignItems: "center", maxWidth: "calc(100% - 90px)" }, { children: [(0, jsx_runtime_1.jsx)(TagTitle, __assign({ bgcolor: ColorIndexMap[idx % 3][200] }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1", fontWeight: "medium", style: { lineHeight: '32px', color: '#fff', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis' } }, { children: v.dimensionName })) })), v.dimensionType === 3 && (0, jsx_runtime_1.jsx)(fbm_ui_1.Chip, { color: 'primary', label: '自定义', size: "small", sx: { ml: 1 } })] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: (0, jsx_runtime_1.jsxs)("span", { children: ["\u9AD8\u5206\u8868\u73B0\uFF1A", v.abilityExpression.good, (0, jsx_runtime_1.jsx)("br", {}), "\u4F4E\u5206\u8868\u73B0\uFF1A", v.abilityExpression.bad] }) }, { children: (0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", style: { lineHeight: '32px' }, mr: 1 }, { children: "\u4F18\u6B21\u8868\u73B0" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoOutlineIcon, { sx: { fontSize: '16px' } })] })) }))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", color: "secondary", ml: 2, style: { background: '#F5F5F5', borderRadius: 4, padding: 8 } }, { children: v.define })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ pl: 2 }, { children: [(0, jsx_runtime_1.jsx)(mui_1.Box, __assign({ mt: 2 }, { children: (0, jsx_runtime_1.jsx)(ScoreSlider_1.default, { width: "100%", isShowLabel: true, score: v.score, scoreText: v.scoreText, scoreLevel: v.scoreLevel }) })), (0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ spacing: 2 }, { children: (0, jsx_runtime_1.jsx)(WorkPlace_1.default, { token: v.token, canEdit: canEditAiDimension, answer: v.answer, mode: "show", bgcolor: ColorIndexMap[idx % 3][50] }) }))] }))] }), v.token));
72
+ return ((0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ mb: 2, pb: 2, pr: 2 }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", mb: 2, mt: 1, justifyContent: "space-between", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", alignItems: "center", maxWidth: "calc(100% - 90px)" }, { children: [(0, jsx_runtime_1.jsx)(TagTitle, __assign({ bgcolor: ColorIndexMap[idx % 3][200] }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1", fontWeight: "medium", style: { lineHeight: '32px', color: '#fff', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis' } }, { children: v.dimensionName })) })), v.dimensionType === 3 && (0, jsx_runtime_1.jsx)(fbm_ui_1.Chip, { color: 'primary', label: '自定义', size: "small", sx: { ml: 1 } })] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: (0, jsx_runtime_1.jsxs)("span", { children: ["\u9AD8\u5206\u8868\u73B0\uFF1A", v.abilityExpression.good, (0, jsx_runtime_1.jsx)("br", {}), "\u4F4E\u5206\u8868\u73B0\uFF1A", v.abilityExpression.bad] }) }, { children: (0, jsx_runtime_1.jsxs)(mui_1.Box, __assign({ display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", style: { lineHeight: '32px' }, mr: 1 }, { children: "\u4F18\u6B21\u8868\u73B0" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoOutlineIcon, { sx: { fontSize: '16px' } })] })) }))] })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", color: "secondary", ml: 2, style: { background: '#F5F5F5', borderRadius: 4, padding: 8 } }, { children: v.define })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ pl: 2 }, { children: [(0, jsx_runtime_1.jsx)(mui_1.Box, __assign({ mt: 2 }, { children: (0, jsx_runtime_1.jsx)(ScoreSlider_1.default, { width: "100%", isShowLabel: true, score: v.score, scoreText: v.scoreText, scoreLevel: v.scoreLevel }) })), (0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ spacing: 2 }, { children: (0, jsx_runtime_1.jsx)(WorkPlace_1.default, { thirdOrderID: orderToken, token: v.token, canEdit: canEditAiDimension, answer: v.answer, mode: "show", bgcolor: ColorIndexMap[idx % 3][50] }) }))] }))] }), v.token));
72
73
  }) }))] })));
73
74
  };
74
75
  exports.default = Index;
@@ -7,6 +7,7 @@ interface PostAiInterviewEvaluationData {
7
7
  }
8
8
  export declare const PostAiInterviewEvaluation: <R>(data: PostAiInterviewEvaluationData) => import("axios").AxiosPromise<R>;
9
9
  interface PostAiInterviewWorkplaceData {
10
+ thirdOrderID: string;
10
11
  token: string;
11
12
  answer?: string;
12
13
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eli-video-interview",
3
- "version": "1.2.41-alpha.13",
3
+ "version": "1.2.41-alpha.15",
4
4
  "description": "鳄梨科技 AI视频面试 React SDK",
5
5
  "author": "鳄梨科技",
6
6
  "license": "MIT",