eli-video-interview 1.2.29-beta.2 → 1.2.29-beta.4

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 (95) hide show
  1. package/esm/components/BigBallSvg/styled.d.ts +2 -2
  2. package/esm/components/ScoreBigBall/styled.d.ts +1 -1
  3. package/esm/components/ScrollDialogContent/index.d.ts +1 -1
  4. package/esm/components/VideoPreview/styled.d.ts +3 -3
  5. package/esm/index.d.ts +0 -1
  6. package/esm/index.js +0 -1
  7. package/esm/modules/ai-ability/Root.js +29 -17
  8. package/esm/modules/ai-ability/components/AbilityFormItem/index.d.ts +14 -0
  9. package/esm/modules/ai-ability/components/AbilityFormItem/index.js +128 -0
  10. package/esm/modules/ai-ability/components/AddAbility/index.d.ts +4 -0
  11. package/esm/modules/ai-ability/components/AddAbility/index.js +150 -0
  12. package/esm/modules/ai-ability/components/UpdateAbility/index.d.ts +2 -2
  13. package/esm/modules/ai-ability/components/UpdateAbility/index.js +91 -22
  14. package/esm/modules/ai-ability/const.d.ts +8 -0
  15. package/esm/modules/ai-ability/const.js +34 -0
  16. package/esm/modules/ai-ability/index.js +1 -1
  17. package/esm/modules/ai-ability/interface.d.ts +27 -0
  18. package/esm/modules/ai-ability/styled.d.ts +4 -1
  19. package/esm/modules/ai-ability/styled.js +5 -1
  20. package/esm/modules/ai-question/components/AiAnalysis/AnalysisItem.js +4 -4
  21. package/esm/modules/ai-question/components/AiAssessmentCriteria/styled.d.ts +1 -1
  22. package/esm/modules/ai-question/components/BaseAccordion/styled.d.ts +3 -3
  23. package/esm/modules/ai-question/components/BootVideo/styled.d.ts +4 -4
  24. package/esm/modules/ai-question/components/QuestionModel/styled.d.ts +1 -1
  25. package/esm/modules/ai-question/components/QuestionPreview/styled.d.ts +2 -2
  26. package/esm/modules/ai-question/components/QuestionUpdate/Form.js +3 -1
  27. package/esm/modules/ai-question/components/QuestionUpdate/index.js +2 -2
  28. package/esm/modules/ai-report/components/MenuAnchor/index.d.ts +3 -3
  29. package/esm/modules/ai-report/components/MenuAnchor/index.js +103 -8
  30. package/esm/modules/ai-report/components/RankingRange/styled.d.ts +2 -2
  31. package/esm/modules/ai-report/components/ScoreReport/styled.d.ts +5 -5
  32. package/esm/modules/ai-report/components/VideoQuestion/styled.d.ts +7 -7
  33. package/esm/modules/ai-report/components/WorkPlaces/index.js +2 -3
  34. package/esm/modules/ai-report/components/WorkPlaces/styled.d.ts +4 -4
  35. package/esm/modules/ai-report/index.js +1 -0
  36. package/esm/modules/ai-report/interface.d.ts +10 -0
  37. package/esm/modules/ai-template/components/TemplateHeader/index.js +1 -1
  38. package/esm/modules/ai-template/components/TemplateList/styled.d.ts +10 -10
  39. package/esm/modules/ai-template/components/TemplateMenu/styled.d.ts +4 -4
  40. package/esm/services/ai-ability.d.ts +12 -3
  41. package/esm/services/ai-ability.js +5 -2
  42. package/lib/components/BigBallSvg/styled.d.ts +2 -2
  43. package/lib/components/ScoreBigBall/styled.d.ts +1 -1
  44. package/lib/components/ScrollDialogContent/index.d.ts +1 -1
  45. package/lib/components/VideoPreview/styled.d.ts +3 -3
  46. package/lib/index.d.ts +0 -1
  47. package/lib/index.js +1 -3
  48. package/lib/modules/ai-ability/Root.js +29 -17
  49. package/lib/modules/ai-ability/components/AbilityFormItem/index.d.ts +14 -0
  50. package/lib/modules/ai-ability/components/AbilityFormItem/index.js +130 -0
  51. package/lib/modules/ai-ability/components/AddAbility/index.d.ts +4 -0
  52. package/lib/modules/ai-ability/components/AddAbility/index.js +155 -0
  53. package/lib/modules/ai-ability/components/UpdateAbility/index.d.ts +2 -2
  54. package/lib/modules/ai-ability/components/UpdateAbility/index.js +93 -21
  55. package/lib/modules/ai-ability/const.d.ts +8 -0
  56. package/lib/modules/ai-ability/const.js +37 -0
  57. package/lib/modules/ai-ability/index.js +1 -1
  58. package/lib/modules/ai-ability/interface.d.ts +27 -0
  59. package/lib/modules/ai-ability/styled.d.ts +4 -1
  60. package/lib/modules/ai-ability/styled.js +5 -1
  61. package/lib/modules/ai-question/components/AiAnalysis/AnalysisItem.js +2 -2
  62. package/lib/modules/ai-question/components/AiAssessmentCriteria/styled.d.ts +1 -1
  63. package/lib/modules/ai-question/components/BaseAccordion/styled.d.ts +3 -3
  64. package/lib/modules/ai-question/components/BootVideo/styled.d.ts +4 -4
  65. package/lib/modules/ai-question/components/QuestionModel/styled.d.ts +1 -1
  66. package/lib/modules/ai-question/components/QuestionPreview/styled.d.ts +2 -2
  67. package/lib/modules/ai-question/components/QuestionUpdate/Form.js +3 -1
  68. package/lib/modules/ai-question/components/QuestionUpdate/index.js +2 -2
  69. package/lib/modules/ai-report/components/MenuAnchor/index.d.ts +3 -3
  70. package/lib/modules/ai-report/components/MenuAnchor/index.js +101 -9
  71. package/lib/modules/ai-report/components/RankingRange/styled.d.ts +2 -2
  72. package/lib/modules/ai-report/components/ScoreReport/styled.d.ts +5 -5
  73. package/lib/modules/ai-report/components/VideoQuestion/styled.d.ts +7 -7
  74. package/lib/modules/ai-report/components/WorkPlaces/index.js +1 -2
  75. package/lib/modules/ai-report/components/WorkPlaces/styled.d.ts +4 -4
  76. package/lib/modules/ai-report/index.js +1 -0
  77. package/lib/modules/ai-report/interface.d.ts +10 -0
  78. package/lib/modules/ai-template/components/TemplateHeader/index.js +1 -1
  79. package/lib/modules/ai-template/components/TemplateList/styled.d.ts +10 -10
  80. package/lib/modules/ai-template/components/TemplateMenu/styled.d.ts +4 -4
  81. package/lib/services/ai-ability.d.ts +12 -3
  82. package/lib/services/ai-ability.js +9 -4
  83. package/package.json +1 -1
  84. package/esm/modules/ai-ability/components/UpdateAbility/interface.d.ts +0 -7
  85. package/esm/modules/ai-ability/components/UpdateAbility/interface.js +0 -1
  86. package/esm/modules/ai-report/components/MenuAnchor/MenuAnchor.d.ts +0 -4
  87. package/esm/modules/ai-report/components/MenuAnchor/MenuAnchor.js +0 -106
  88. package/esm/modules/ai-report/components/MenuAnchor/interface.d.ts +0 -10
  89. package/esm/modules/ai-report/components/MenuAnchor/interface.js +0 -1
  90. package/lib/modules/ai-ability/components/UpdateAbility/interface.d.ts +0 -7
  91. package/lib/modules/ai-ability/components/UpdateAbility/interface.js +0 -2
  92. package/lib/modules/ai-report/components/MenuAnchor/MenuAnchor.d.ts +0 -4
  93. package/lib/modules/ai-report/components/MenuAnchor/MenuAnchor.js +0 -108
  94. package/lib/modules/ai-report/components/MenuAnchor/interface.d.ts +0 -10
  95. package/lib/modules/ai-report/components/MenuAnchor/interface.js +0 -2
@@ -46,23 +46,49 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
46
46
  if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
47
47
  }
48
48
  };
49
+ var __importDefault = (this && this.__importDefault) || function (mod) {
50
+ return (mod && mod.__esModule) ? mod : { "default": mod };
51
+ };
49
52
  Object.defineProperty(exports, "__esModule", { value: true });
50
53
  var jsx_runtime_1 = require("react/jsx-runtime");
51
- var react_1 = require("react");
52
- var fbm_ui_1 = require("fbm-ui");
53
- var ahooks_1 = require("ahooks");
54
+ var const_1 = require("../../const");
55
+ var AbilityFormItem_1 = __importDefault(require("../AbilityFormItem"));
54
56
  var ai_ability_1 = require("../../../../services/ai-ability");
57
+ var ahooks_1 = require("ahooks");
58
+ var fbm_ui_1 = require("fbm-ui");
59
+ var react_1 = require("react");
55
60
  var UpdateAbility = function (props) {
56
- var open = props.open, _a = props.name, name = _a === void 0 ? '' : _a, token = props.token, onClose = props.onClose, onSuccess = props.onSuccess;
57
- var _b = (0, react_1.useState)(''), value = _b[0], setValue = _b[1];
58
- var _c = (0, ahooks_1.useRequest)(ai_ability_1.PostQuestionCollectionUpsert, {
61
+ var open = props.open, _a = props.type, type = _a === void 0 ? 1 : _a, isWorkplace = props.isWorkplace, _b = props.name, name = _b === void 0 ? '' : _b, token = props.token, onClose = props.onClose, onSuccess = props.onSuccess;
62
+ var _c = (0, react_1.useState)(''), value = _c[0], setValue = _c[1];
63
+ var _d = (0, react_1.useState)(1), step = _d[0], setStep = _d[1];
64
+ var _e = (0, react_1.useState)('show'), mode = _e[0], setMode = _e[1];
65
+ var firstLoad = (0, react_1.useRef)(true);
66
+ var _f = (0, react_1.useState)(false), showAiDefineDetail = _f[0], setShowAiDefineDetail = _f[1];
67
+ // const [submitDisabled, setSubmitDisabled] = useState<boolean>(true);
68
+ var _g = (0, react_1.useState)(const_1.InitialValues.workPlaceItems), workPlaceItems = _g[0], setWorkPlaceItems = _g[1];
69
+ var _h = (0, ahooks_1.useRequest)(ai_ability_1.PostQuestionCollectionUpsert, {
59
70
  manual: true,
60
71
  onSuccess: function () {
61
- fbm_ui_1.Message.success("".concat(token ? '编辑' : '新增', "\u80FD\u529B\u6210\u529F"));
72
+ fbm_ui_1.Message.success("\u7F16\u8F91\u80FD\u529B\u6210\u529F");
62
73
  onClose();
63
74
  onSuccess();
64
75
  },
65
- }), run = _c.run, loading = _c.loading;
76
+ }), run = _h.run, loading = _h.loading;
77
+ var getAbilityDetail = (0, ahooks_1.useRequest)(ai_ability_1.GetAbilityDetail, {
78
+ manual: true,
79
+ onSuccess: function (_a) {
80
+ var _b;
81
+ var list = _a.data.list;
82
+ if (list.length) {
83
+ var res = (_b = list[0]) === null || _b === void 0 ? void 0 : _b.workPlaceItems;
84
+ firstLoad.current = false;
85
+ if (res === null || res === void 0 ? void 0 : res.length) {
86
+ setWorkPlaceItems(res);
87
+ }
88
+ setShowAiDefineDetail(true);
89
+ }
90
+ },
91
+ }).run;
66
92
  var nameTextField = (0, fbm_ui_1.useTextField)({
67
93
  value: value,
68
94
  label: '能力名称',
@@ -70,48 +96,94 @@ var UpdateAbility = function (props) {
70
96
  rules: [
71
97
  {
72
98
  required: true,
73
- message: '请输入能力名称',
99
+ message: '能力名称不能为空',
74
100
  },
75
101
  ],
76
102
  onChange: function (e) { return setValue(e.target.value); },
77
103
  max: 7,
78
104
  sx: {
79
105
  height: '48px',
106
+ width: '320px',
107
+ marginTop: '16px',
80
108
  },
81
109
  });
110
+ var handleValue = (0, react_1.useCallback)(function (v) {
111
+ var index = workPlaceItems.findIndex(function (ele) { return ele.type === v.type; });
112
+ workPlaceItems.splice(index, 1, v);
113
+ var list = workPlaceItems;
114
+ setWorkPlaceItems(list);
115
+ }, [workPlaceItems]);
82
116
  var handleOk = (0, react_1.useCallback)(function () { return __awaiter(void 0, void 0, void 0, function () {
83
- var error, avocadoConfig;
117
+ var error, workPlaceItemsError, avocadoConfig;
84
118
  return __generator(this, function (_a) {
85
119
  switch (_a.label) {
86
120
  case 0: return [4 /*yield*/, nameTextField.handleValidate()];
87
121
  case 1:
88
122
  error = _a.sent();
123
+ workPlaceItemsError = workPlaceItems.some(function (v) { return v.items.length === 0; });
89
124
  if (!error) {
90
125
  avocadoConfig = window['AvocadoVideoInterviewConfig'];
91
- run({
92
- name: value,
93
- tag: value,
94
- token: token,
95
- mateData: {
96
- account: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.account,
97
- enterpriseId: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.enterpriseId,
98
- },
99
- });
126
+ // 旧自定义能力
127
+ if (type === 3 && !isWorkplace) {
128
+ run({
129
+ name: value,
130
+ tag: value,
131
+ token: token,
132
+ mateData: {
133
+ account: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.account,
134
+ enterpriseId: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.enterpriseId,
135
+ },
136
+ });
137
+ }
138
+ else if (!workPlaceItemsError) {
139
+ // 职场能力
140
+ run({
141
+ name: value,
142
+ tag: value,
143
+ token: token,
144
+ workPlaceItems: workPlaceItems,
145
+ mateData: {
146
+ account: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.account,
147
+ enterpriseId: avocadoConfig === null || avocadoConfig === void 0 ? void 0 : avocadoConfig.enterpriseId,
148
+ },
149
+ });
150
+ }
100
151
  }
101
152
  return [2 /*return*/];
102
153
  }
103
154
  });
104
- }); }, [nameTextField, run, token, value]);
155
+ }); }, [nameTextField, run, token, value, isWorkplace, type, workPlaceItems]);
156
+ var footer = (0, react_1.useCallback)(function () {
157
+ return step === 1 ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", padding: "12px 16px" }, { children: type === 1 ? ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {})) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", color: "inherit", onClick: function () { return setStep(2); } }, { children: "\u7F16\u8F91" }))) }))) : ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", justifyContent: "flex-end", padding: "12px 16px" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ sx: { mr: 1, fontWeight: 400 }, variant: "text", color: "inherit", onClick: onClose }, { children: "\u53D6\u6D88" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ loading: loading, onClick: handleOk }, { children: "\u4FDD\u5B58" }))] })));
158
+ }, [type, step, loading, setStep, handleOk, onClose]);
105
159
  (0, react_1.useEffect)(function () {
106
160
  setValue(name);
107
161
  }, [name]);
108
162
  (0, react_1.useEffect)(function () {
109
163
  if (!open) {
110
164
  setValue('');
165
+ setWorkPlaceItems([]);
166
+ setStep(1);
111
167
  nameTextField.setError();
112
168
  }
113
169
  // eslint-disable-next-line react-hooks/exhaustive-deps
114
170
  }, [open]);
115
- return ((0, jsx_runtime_1.jsx)(fbm_ui_1.Dialog, __assign({ title: token ? '编辑能力' : '新增能力', open: open, okText: token ? '保存' : '新建', okProps: { loading: loading }, onClose: onClose, onOk: handleOk }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.TextField, __assign({}, nameTextField)) })));
171
+ (0, react_1.useEffect)(function () {
172
+ setMode(step === 1 ? 'show' : 'edit');
173
+ }, [step]);
174
+ (0, react_1.useEffect)(function () {
175
+ if (type === 3 && !isWorkplace)
176
+ return;
177
+ if (token) {
178
+ setShowAiDefineDetail(false);
179
+ getAbilityDetail({ tokens: [token] });
180
+ }
181
+ // eslint-disable-next-line react-hooks/exhaustive-deps
182
+ }, [token, name]);
183
+ (0, react_1.useEffect)(function () {
184
+ setWorkPlaceItems(workPlaceItems);
185
+ }, [workPlaceItems, setWorkPlaceItems]);
186
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Drawer, __assign({ className: "abilityDrawer", title: '能力详情', open: open, footer: footer, onClose: onClose }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ style: { width: '556px' } }, { children: step === 1 ? ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: "medium" }, { children: ["\u80FD\u529B\u540D\u79F0\uFF1A", value] }))) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", color: "secondary" }, { children: "\u4F7F\u7528\u901A\u7528\u7684\u80FD\u529B\u540D\u79F0\uFF08\u4F8B\u5982\uFF1A\u9886\u5BFC\u529B\u3001\u5E94\u53D8\u80FD\u529B\u7B49\u5E38\u89C1\u8003\u6838\u9879\uFF09\u547D\u540D\u6709\u52A9\u4E8E\u63D0\u9AD8 AI \u8BC4\u4EF7\u53CA\u8BC4\u5206\u51C6\u786E\u6027\u3002" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.TextField, __assign({}, nameTextField))] })) })), !(type === 3 && !isWorkplace) && ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ style: { width: '556px' } }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Divider, { style: { margin: '24px 0' } }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: "medium", mb: 2 }, { children: "\u80FD\u529B\u6807\u51C6" })), showAiDefineDetail &&
187
+ workPlaceItems.map(function (v) { return ((0, jsx_runtime_1.jsx)(AbilityFormItem_1.default, { token: token, name: value, title: v.name, type: v.type, items: v.items, mode: mode, maxTextLength: v.type === 4 || v.type === 5 ? 300 : 100, canReplace: mode === 'edit' ? true : false, onChange: handleValue }, v.type)); })] })))] })));
116
188
  };
117
189
  exports.default = UpdateAbility;
@@ -0,0 +1,8 @@
1
+ export declare const InitialValues: {
2
+ workPlaceItems: {
3
+ name: string;
4
+ type: number;
5
+ items: never[];
6
+ maxTextLength: number;
7
+ }[];
8
+ };
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.InitialValues = void 0;
4
+ exports.InitialValues = {
5
+ workPlaceItems: [
6
+ {
7
+ name: '能力定义',
8
+ type: 1,
9
+ items: [],
10
+ maxTextLength: 100,
11
+ },
12
+ {
13
+ name: '优次表现-优秀表现',
14
+ type: 2,
15
+ items: [],
16
+ maxTextLength: 100,
17
+ },
18
+ {
19
+ name: '优次表现-较差表现',
20
+ type: 3,
21
+ items: [],
22
+ maxTextLength: 100,
23
+ },
24
+ {
25
+ name: '考察建议-面试题目',
26
+ type: 4,
27
+ items: [],
28
+ maxTextLength: 300,
29
+ },
30
+ {
31
+ name: '考察建议-评分关键点',
32
+ type: 5,
33
+ items: [],
34
+ maxTextLength: 300,
35
+ },
36
+ ],
37
+ };
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  var jsx_runtime_1 = require("react/jsx-runtime");
7
- var RootProvider_1 = __importDefault(require("../../components/RootProvider"));
8
7
  var Root_1 = __importDefault(require("./Root"));
8
+ var RootProvider_1 = __importDefault(require("../../components/RootProvider"));
9
9
  var AiAbility = function () {
10
10
  return ((0, jsx_runtime_1.jsx)(RootProvider_1.default, { children: (0, jsx_runtime_1.jsx)(Root_1.default, {}) }));
11
11
  };
@@ -5,7 +5,10 @@ export interface QuestionCollectionList {
5
5
  type: 1 | 3;
6
6
  sort: number;
7
7
  updatedAt: number;
8
+ used: boolean;
8
9
  isWorkplace: boolean;
10
+ define?: string;
11
+ workPlaceItems?: AiDefineItem[];
9
12
  }
10
13
  export interface QuestionCollectionListData {
11
14
  list: QuestionCollectionList[];
@@ -14,3 +17,27 @@ export interface QuestionCollectionListData {
14
17
  export interface QuestionCollectionListRes {
15
18
  data: QuestionCollectionListData;
16
19
  }
20
+ export interface AbilityProps {
21
+ open: boolean;
22
+ type: number;
23
+ isWorkplace?: boolean;
24
+ name?: string;
25
+ token?: string;
26
+ onClose: () => void;
27
+ onSuccess: () => void;
28
+ }
29
+ export interface AiDefineItem {
30
+ name: string;
31
+ type: number;
32
+ items: string[];
33
+ }
34
+ export interface AiDefineData {
35
+ total: number;
36
+ list: AiDefineItem[];
37
+ }
38
+ export interface AiDefineRes {
39
+ data: AiDefineData;
40
+ }
41
+ export interface AbilityDetailRes {
42
+ data: AiDefineData;
43
+ }
@@ -1,4 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export declare const AbilityRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
+ export declare const AbilityDrawer: import("@emotion/styled").StyledComponent<import("fbm-ui").DrawerProps & {
6
+ children?: import("react").ReactNode;
7
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -1,9 +1,13 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.AbilityRoot = void 0;
3
+ exports.AbilityDrawer = exports.AbilityRoot = void 0;
4
4
  var fbm_ui_1 = require("fbm-ui");
5
5
  exports.AbilityRoot = (0, fbm_ui_1.styled)(fbm_ui_1.Box)({
6
6
  width: '100%',
7
7
  height: '100%',
8
8
  overflow: 'auto',
9
9
  });
10
+ exports.AbilityDrawer = (0, fbm_ui_1.styled)(fbm_ui_1.Drawer)({
11
+ boxSizing: 'border-box',
12
+ width: '588px',
13
+ });
@@ -29,7 +29,7 @@ var AnalysisItem = function (props) {
29
29
  var desc = props.desc || props.name;
30
30
  var NotUsedAilibity = ['英文能力', '游戏测评'];
31
31
  if (abilityType === 2 && !isWorkplace) {
32
- desc = "".concat(NotUsedAilibity.includes(name) ? name : '自定义能力', "\u4E0D\u80FD\u53C2\u4E0EAI\u5206\u6790");
32
+ desc = "".concat(NotUsedAilibity.includes(name) ? name : '该能力', "\u4E0D\u80FD\u53C2\u4E0EAI\u5206\u6790");
33
33
  }
34
34
  var handleRemove = (0, react_1.useCallback)(function () {
35
35
  removeAiAbilities(index);
@@ -44,6 +44,6 @@ var AnalysisItem = function (props) {
44
44
  var value = _a.target.value;
45
45
  updateAiAbilitiesWeight(value, index);
46
46
  }, [updateAiAbilitiesWeight, index]);
47
- return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, { children: [(0, jsx_runtime_1.jsxs)(mui_1.ListItem, __assign({ sx: { pl: 0, pr: 4 }, secondaryAction: (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ sx: { position: 'relative', left: 16 }, onClick: handleRemove }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.CloseIcon, {}) })) }, { children: [(0, jsx_runtime_1.jsx)(mui_1.ListItemText, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle2" }, { children: name })), abilityType === 2 && !isWorkplace ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", style: { color: 'RGBA(0, 0, 0, 0.26)', fontSize: 12 }, ml: 1 }, { children: desc }))) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "".concat(desc) }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))), type === 8 && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Select, { sx: { width: 150, ml: 1 }, options: const_1.willOrNotOptions, value: (_a = JSON.parse(extra)) === null || _a === void 0 ? void 0 : _a.expect, size: "small", onChange: handleWillOrNotChange }))] })) }), (abilityType === 1 || (abilityType === 2 && isWorkplace)) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Input, { sx: { width: 84, mr: 1 }, value: weight, disabled: index === aiAbilities.length - 1, size: "small", endAdornment: "%", onChange: handleWeightChange }))] })), type === 6 && (0, jsx_runtime_1.jsx)(MainPoints_1.default, { extra: extra, index: index })] }));
47
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, { children: [(0, jsx_runtime_1.jsxs)(mui_1.ListItem, __assign({ sx: { pl: 0, pr: 4 }, secondaryAction: (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ sx: { position: 'relative', left: 16 }, onClick: handleRemove }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.CloseIcon, {}) })) }, { children: [(0, jsx_runtime_1.jsx)(mui_1.ListItemText, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle2" }, { children: name })), abilityType === 2 && !isWorkplace ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", style: { color: 'RGBA(0, 0, 0, 0.26)', fontSize: 12 }, ml: 1 }, { children: desc }))) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [abilityType === 2 && isWorkplace && type === 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: "".concat(desc), placement: "right" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))] })), type === 8 && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Select, { sx: { width: 150, ml: 1 }, options: const_1.willOrNotOptions, value: (_a = JSON.parse(extra)) === null || _a === void 0 ? void 0 : _a.expect, size: "small", onChange: handleWillOrNotChange }))] })) }), (abilityType === 1 || (abilityType === 2 && isWorkplace)) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Input, { sx: { width: 84, mr: 1 }, value: weight, disabled: index === aiAbilities.length - 1, size: "small", endAdornment: "%", onChange: handleWeightChange }))] })), type === 6 && (0, jsx_runtime_1.jsx)(MainPoints_1.default, { extra: extra, index: index })] }));
48
48
  };
49
49
  exports.default = AnalysisItem;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  export declare const ListItem: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -1,10 +1,10 @@
1
1
  /// <reference types="react" />
2
2
  export declare const AccordionRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
5
  export declare const AccordionTitle: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
6
6
  children?: import("react").ReactNode;
7
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
7
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
8
8
  export declare const AccordionSubTitle: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
9
9
  children?: import("react").ReactNode;
10
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
10
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -1,13 +1,13 @@
1
1
  /// <reference types="react" />
2
2
  export declare const CustomUploadCardRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
5
  export declare const CustomUploadCardTitle: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
6
6
  children?: import("react").ReactNode;
7
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
7
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
8
8
  export declare const CustomUploadButtonRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
9
9
  children?: import("react").ReactNode;
10
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
10
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
11
11
  export declare const CustomUploadedImgRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
12
12
  children?: import("react").ReactNode;
13
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
13
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  export declare const QuestionModelRoot: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Box").BoxProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -4,8 +4,8 @@ export declare const PreviewRoot: import("@emotion/styled").StyledComponent<{
4
4
  classes?: Partial<import("fbm-ui/lib/mui").PaperClasses> | undefined;
5
5
  elevation?: number | undefined;
6
6
  square?: boolean | undefined;
7
- sx?: import("@mui/system").SxProps<import("fbm-ui/lib/mui").Theme> | undefined;
7
+ sx?: import("@mui/system/styleFunctionSx").SxProps<import("fbm-ui/lib/mui").Theme> | undefined;
8
8
  variant?: "elevation" | "outlined" | undefined;
9
9
  } & import("@mui/material/OverridableComponent").CommonProps & Omit<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>> & {
10
10
  ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
11
- }, "children" | keyof import("@mui/material/OverridableComponent").CommonProps | "sx" | "elevation" | "variant" | "square"> & import("@mui/system").MUIStyledCommonProps<import("fbm-ui/lib/mui").Theme>, {}, {}>;
11
+ }, "children" | keyof import("@mui/material/OverridableComponent").CommonProps | "sx" | "elevation" | "variant" | "square"> & import("@mui/system/createStyled").MUIStyledCommonProps<import("fbm-ui/lib/mui").Theme>, {}, {}>;
@@ -96,12 +96,14 @@ var QuestionForm = (0, react_1.forwardRef)(function (props, ref) {
96
96
  onValuesChange === null || onValuesChange === void 0 ? void 0 : onValuesChange(form.values);
97
97
  }, [form.values, onValuesChange]);
98
98
  return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Form, __assign({}, form, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { required: true, disabled: preview, name: "name", label: "\u6807\u9898", placeholder: "\u6807\u9898\uFF08\u7528\u4E8E\u7CFB\u7EDF\u7BA1\u7406\uFF09", max: 15 }), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex" }, { children: [!preview && aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE && ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, __assign({ sx: { flex: '1 0', mr: 1 }, required: true, disabled: preview, name: "broadcastType", label: "\u64AD\u62A5\u65B9\u5F0F" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Select, { placeholder: "\u64AD\u62A5\u65B9\u5F0F", options: const_1.broadcastModeOptions }) }))), !preview && ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, __assign({ style: { flex: '1 0' }, disabled: preview, name: "category", label: "\u8003\u5BDF\u80FD\u529B" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Autocomplete, { placeholder: "\u8003\u5BDF\u80FD\u529B", options: questionCollectionList.map(function (_a) {
99
- var tag = _a.tag, token = _a.token, isWorkplace = _a.isWorkplace;
99
+ var tag = _a.tag, token = _a.token, isWorkplace = _a.isWorkplace, define = _a.define, type = _a.type;
100
100
  return ({
101
101
  label: tag,
102
102
  value: tag,
103
103
  name: tag,
104
+ type: type,
104
105
  token: token,
106
+ define: define,
105
107
  isWorkplace: isWorkplace,
106
108
  });
107
109
  }), onChange: handleCategoryChange }) })))] })), form.values.broadcastType === 1 || preview ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { required: true, disabled: preview, name: "desc", label: "\u9762\u8BD5\u5185\u5BB9", max: 300, placeholder: "\u9762\u8BD5\u5185\u5BB9\uFF08\u7CFB\u7EDF\u5C06\u6839\u636E\u6B64\u5185\u5BB9\u5411\u5019\u9009\u4EBA\u8FDB\u884C\u8BED\u97F3\u64AD\u62A5\uFF09" })) : ((0, jsx_runtime_1.jsx)(VideoVoice_1.default, {})), aiShowType === ai_question_1.ADD_QUESTION_TYPE.LANGUAGE && ((0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { sx: { height: 'auto', mb: 2 }, required: true, name: "readText", label: "\u6717\u8BFB\u5185\u5BB9", max: 240, InputProps: {
@@ -107,7 +107,7 @@ var QuestionUpdate = function () {
107
107
  (_a = formRef === null || formRef === void 0 ? void 0 : formRef.current) === null || _a === void 0 ? void 0 : _a.setFormValues({ broadcastType: const_1.defaultQuestionParams.broadcastType });
108
108
  updateQuestionState({ aiShowType: ai_question_1.ADD_QUESTION_TYPE.LANGUAGE });
109
109
  } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u8DDF\u8BFB\u80FD\u529B" })) }))] }));
110
- return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1" }, { children: aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE ? '自由作答' : '跟读能力' })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
110
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ ml: 3, variant: "subtitle1" }, { children: aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE ? '自由作答' : '跟读能力' })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
111
111
  };
112
112
  var getModelParams = (0, react_1.useCallback)(function (values, isSubmit) {
113
113
  return new Promise(function (resolve, reject) {
@@ -215,7 +215,7 @@ var QuestionUpdate = function () {
215
215
  var CurWorkplace = questionCollectionList.find(function (v) { return v.name === curSelectWorkPlace.label; }) || {};
216
216
  var CurWorkPlaceAiAbility = __assign(__assign(__assign({}, curSelectWorkPlace), CurWorkplace), { abilityType: 2, weight: 0, sort: 0 });
217
217
  inInit = workplaceTypeIndex === -1;
218
- CurWorkPlaceAiAbility.desc = CurWorkPlaceAiAbility.name;
218
+ CurWorkPlaceAiAbility.desc = CurWorkPlaceAiAbility.define ? CurWorkPlaceAiAbility.define : CurWorkPlaceAiAbility.name;
219
219
  // console.log('CurWorkPlaceAiAbility', CurWorkPlaceAiAbility);
220
220
  // 添加和修改
221
221
  if (workplaceTypeIndex > -1) {
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
2
- import { MenuAnchorProps } from './interface';
3
- declare const _default: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<MenuAnchorProps & import("react").RefAttributes<any>>>;
1
+ import { MenuAnchorProps } from '../../interface';
2
+ import React from 'react';
3
+ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<MenuAnchorProps & React.RefAttributes<any>>>;
4
4
  export default _default;
@@ -10,16 +10,108 @@ var __assign = (this && this.__assign) || function () {
10
10
  };
11
11
  return __assign.apply(this, arguments);
12
12
  };
13
- var __importDefault = (this && this.__importDefault) || function (mod) {
14
- return (mod && mod.__esModule) ? mod : { "default": mod };
15
- };
16
13
  Object.defineProperty(exports, "__esModule", { value: true });
17
14
  var jsx_runtime_1 = require("react/jsx-runtime");
18
- var MenuAnchor_1 = __importDefault(require("./MenuAnchor"));
19
- var RootProvider_1 = __importDefault(require("../../../../components/RootProvider"));
15
+ var ai_report_1 = require("../../../../constants/ai-report");
16
+ var ai_report_2 = require("../../../../services/ai-report");
17
+ var global_store_1 = require("../../../../store/ai-report/global-store");
18
+ var ahooks_1 = require("ahooks");
19
+ var fbm_ui_1 = require("fbm-ui");
20
+ var mui_1 = require("fbm-ui/lib/mui");
20
21
  var react_1 = require("react");
21
- var ReportMenuAnchor = (0, react_1.forwardRef)(function (props, ref) {
22
- return ((0, jsx_runtime_1.jsx)(RootProvider_1.default, { children: (0, jsx_runtime_1.jsx)(MenuAnchor_1.default, __assign({}, props)) }));
22
+ var MenuAnchor = (0, react_1.forwardRef)(function (props) {
23
+ var _a = (0, react_1.useState)(null), anchorEl = _a[0], setAnchorEl = _a[1];
24
+ var open = Boolean(anchorEl);
25
+ // 接口请求
26
+ var token = props.token, showAiDimension = props.showAiDimension;
27
+ var firstLoad = (0, react_1.useRef)(true);
28
+ var _b = (0, react_1.useState)([]), list = _b[0], setList = _b[1];
29
+ var _c = (0, global_store_1.useAiReportStore)(), reportResult = _c.reportResult, updateState = _c.updateState, updateReportResult = _c.updateReportResult;
30
+ var postAiInterviewResult = (0, ahooks_1.useRequest)(function () { return (0, ai_report_2.PostAiInterviewResult)([token]); }, {
31
+ manual: true,
32
+ onSuccess: function (_a) {
33
+ var list = _a.data.list;
34
+ var result = list[0];
35
+ updateReportResult(result);
36
+ if (firstLoad.current) {
37
+ firstLoad.current = false;
38
+ handleMenuList(result);
39
+ }
40
+ },
41
+ }).run;
42
+ (0, react_1.useEffect)(function () {
43
+ firstLoad.current = true;
44
+ postAiInterviewResult();
45
+ // eslint-disable-next-line react-hooks/exhaustive-deps
46
+ }, [token]);
47
+ (0, react_1.useEffect)(function () {
48
+ updateState(props);
49
+ // eslint-disable-next-line react-hooks/exhaustive-deps
50
+ }, [props]);
51
+ // 处理菜单数据
52
+ var handleMenuList = function (reportResult) {
53
+ if (!reportResult.status) {
54
+ return;
55
+ }
56
+ var resList = [ai_report_1.REPORT_MODULE_MAP['videoQuestion']];
57
+ var _a = reportResult.collection, collection = _a === void 0 ? [] : _a, _b = reportResult.workplaces, workplaces = _b === void 0 ? [] : _b, _c = reportResult.suggestion, suggestion = _c === void 0 ? { show: false } : _c, _d = reportResult.evaluations, evaluations = _d === void 0 ? [] : _d;
58
+ if (showAiDimension) {
59
+ if (suggestion === null || suggestion === void 0 ? void 0 : suggestion.show) {
60
+ resList.unshift(ai_report_1.REPORT_MODULE_MAP['suggestion']);
61
+ }
62
+ if (collection.length > 0 && evaluations.length > 0) {
63
+ resList.unshift(ai_report_1.REPORT_MODULE_MAP['evaluate']);
64
+ }
65
+ if (workplaces.length > 0) {
66
+ resList.unshift(ai_report_1.REPORT_MODULE_MAP['workplace']);
67
+ }
68
+ }
69
+ if (collection.length > 0) {
70
+ resList.unshift(ai_report_1.REPORT_MODULE_MAP['score']);
71
+ }
72
+ console.log(resList);
73
+ setList(resList);
74
+ };
75
+ var handlePopoverOpen = function (event) {
76
+ setAnchorEl(event.currentTarget);
77
+ };
78
+ var handlePopoverClose = function () {
79
+ setAnchorEl(null);
80
+ };
81
+ var scrollToAnchor = (0, react_1.useCallback)(function (id) {
82
+ if (id) {
83
+ var anchorEle = document.getElementById(id);
84
+ if (anchorEle) {
85
+ anchorEle.scrollIntoView({ block: 'start', behavior: 'smooth' });
86
+ }
87
+ }
88
+ }, []);
89
+ var content = (0, react_1.useMemo)(function () {
90
+ return ((0, jsx_runtime_1.jsx)(mui_1.List, __assign({ style: { minWidth: 150 }, onMouseLeave: handlePopoverClose }, { children: list.map(function (_a) {
91
+ var name = _a.name, id = _a.id;
92
+ return ((0, jsx_runtime_1.jsx)(mui_1.ListItem, __assign({ disablePadding: true }, { children: (0, jsx_runtime_1.jsx)(mui_1.ListItemButton, __assign({ onClick: function () { return scrollToAnchor(id); } }, { children: (0, jsx_runtime_1.jsx)(mui_1.ListItemText, { primary: name }) })) }), id));
93
+ }) })));
94
+ }, [scrollToAnchor, list]);
95
+ return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(reportResult === null || reportResult === void 0 ? void 0 : reportResult.status) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ style: {
96
+ display: 'flex',
97
+ alignItems: 'center',
98
+ justifyContent: 'center',
99
+ position: 'absolute',
100
+ top: 20,
101
+ right: -10,
102
+ zIndex: 999,
103
+ height: 32,
104
+ width: 32,
105
+ backgroundColor: '#fff',
106
+ borderRadius: 4,
107
+ boxShadow: '0px 2px 4px rgba(0,0,0, 0.08)',
108
+ }, "aria-owns": open ? 'menu-anchor-popover' : undefined, "aria-haspopup": "true", onClick: handlePopoverOpen, onMouseEnter: handlePopoverOpen }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.MenuIcon, {}) }))), (0, jsx_runtime_1.jsx)(mui_1.Popover, __assign({ id: "menu-anchor-popover", open: open, anchorEl: anchorEl, anchorOrigin: {
109
+ vertical: 'bottom',
110
+ horizontal: 'right',
111
+ }, transformOrigin: {
112
+ vertical: -8,
113
+ horizontal: 'right',
114
+ }, onClose: handlePopoverClose }, { children: content }))] }));
23
115
  });
24
- ReportMenuAnchor.displayName = 'AiReport';
25
- exports.default = (0, react_1.memo)(ReportMenuAnchor);
116
+ MenuAnchor.displayName = 'MenuAnchor';
117
+ exports.default = (0, react_1.memo)(MenuAnchor);
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export declare const RangeInput: import("@emotion/styled").StyledComponent<import("fbm-ui").BaseInputProps & import("@mui/material").OutlinedInputProps & import("@mui/material").InputProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
5
  export declare const RangeTypography: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
6
6
  children?: import("react").ReactNode;
7
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
7
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
@@ -1,22 +1,22 @@
1
1
  /// <reference types="react" />
2
2
  export declare const ScoreTypography: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
3
3
  children?: import("react").ReactNode;
4
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
4
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
5
  export declare const ScoreUnitTypography: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
6
6
  children?: import("react").ReactNode;
7
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
7
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
8
8
  export declare const RefreshIconRoot: import("@emotion/styled").StyledComponent<{
9
9
  children?: import("react").ReactNode;
10
10
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
11
- color?: "inherit" | "disabled" | "action" | "error" | "warning" | "success" | "info" | "secondary" | "primary" | undefined;
11
+ color?: "inherit" | "disabled" | "action" | "primary" | "secondary" | "success" | "error" | "info" | "warning" | undefined;
12
12
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
13
13
  htmlColor?: string | undefined;
14
14
  shapeRendering?: string | undefined;
15
- sx?: import("@mui/system").SxProps<import("@mui/material").Theme> | undefined;
15
+ sx?: import("@mui/system/styleFunctionSx").SxProps<import("@mui/material").Theme> | undefined;
16
16
  titleAccess?: string | undefined;
17
17
  viewBox?: string | undefined;
18
18
  } & import("@mui/material/OverridableComponent").CommonProps & Omit<Pick<import("react").SVGProps<SVGSVGElement>, "string" | "seed" | "children" | "style" | "clipPath" | "filter" | "mask" | "path" | "d" | "y" | "name" | "type" | "onLoad" | "fill" | "values" | "className" | "display" | "overflow" | "visibility" | "order" | "color" | "width" | "height" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "letterSpacing" | "cursor" | "direction" | "fontSizeAdjust" | "fontStretch" | "fontVariant" | "imageRendering" | "opacity" | "paintOrder" | "pointerEvents" | "rotate" | "scale" | "textRendering" | "transform" | "unicodeBidi" | "wordSpacing" | "writingMode" | "offset" | "textDecoration" | "azimuth" | "clip" | "alignmentBaseline" | "baselineShift" | "clipRule" | "colorInterpolation" | "colorRendering" | "dominantBaseline" | "fillOpacity" | "fillRule" | "floodColor" | "floodOpacity" | "glyphOrientationVertical" | "lightingColor" | "markerEnd" | "markerMid" | "markerStart" | "shapeRendering" | "stopColor" | "stopOpacity" | "stroke" | "strokeDasharray" | "strokeDashoffset" | "strokeLinecap" | "strokeLinejoin" | "strokeMiterlimit" | "strokeOpacity" | "strokeWidth" | "textAnchor" | "vectorEffect" | "key" | "id" | "lang" | "tabIndex" | "role" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "end" | "max" | "media" | "method" | "min" | "target" | "crossOrigin" | "accentHeight" | "accumulate" | "additive" | "allowReorder" | "alphabetic" | "amplitude" | "arabicForm" | "ascent" | "attributeName" | "attributeType" | "autoReverse" | "baseFrequency" | "baseProfile" | "bbox" | "begin" | "bias" | "by" | "calcMode" | "capHeight" | "clipPathUnits" | "colorInterpolationFilters" | "colorProfile" | "contentScriptType" | "contentStyleType" | "cx" | "cy" | "decelerate" | "descent" | "diffuseConstant" | "divisor" | "dur" | "dx" | "dy" | "edgeMode" | "elevation" | "enableBackground" | "exponent" | "externalResourcesRequired" | "filterRes" | "filterUnits" | "focusable" | "format" | "fr" | "from" | "fx" | "fy" | "g1" | "g2" | "glyphName" | "glyphOrientationHorizontal" | "glyphRef" | "gradientTransform" | "gradientUnits" | "hanging" | "horizAdvX" | "horizOriginX" | "href" | "ideographic" | "in2" | "in" | "intercept" | "k1" | "k2" | "k3" | "k4" | "k" | "kernelMatrix" | "kernelUnitLength" | "kerning" | "keyPoints" | "keySplines" | "keyTimes" | "lengthAdjust" | "limitingConeAngle" | "local" | "markerHeight" | "markerUnits" | "markerWidth" | "maskContentUnits" | "maskUnits" | "mathematical" | "mode" | "numOctaves" | "operator" | "orient" | "orientation" | "origin" | "overlinePosition" | "overlineThickness" | "panose1" | "pathLength" | "patternContentUnits" | "patternTransform" | "patternUnits" | "points" | "pointsAtX" | "pointsAtY" | "pointsAtZ" | "preserveAlpha" | "preserveAspectRatio" | "primitiveUnits" | "r" | "radius" | "refX" | "refY" | "renderingIntent" | "repeatCount" | "repeatDur" | "requiredExtensions" | "requiredFeatures" | "restart" | "result" | "rx" | "ry" | "slope" | "spacing" | "specularConstant" | "specularExponent" | "speed" | "spreadMethod" | "startOffset" | "stdDeviation" | "stemh" | "stemv" | "stitchTiles" | "strikethroughPosition" | "strikethroughThickness" | "surfaceScale" | "systemLanguage" | "tableValues" | "targetX" | "targetY" | "textLength" | "to" | "u1" | "u2" | "underlinePosition" | "underlineThickness" | "unicode" | "unicodeRange" | "unitsPerEm" | "vAlphabetic" | "version" | "vertAdvY" | "vertOriginX" | "vertOriginY" | "vHanging" | "vIdeographic" | "viewBox" | "viewTarget" | "vMathematical" | "widths" | "x1" | "x2" | "x" | "xChannelSelector" | "xHeight" | "xlinkActuate" | "xlinkArcrole" | "xlinkHref" | "xlinkRole" | "xlinkShow" | "xlinkTitle" | "xlinkType" | "xmlBase" | "xmlLang" | "xmlns" | "xmlnsXlink" | "xmlSpace" | "y1" | "y2" | "yChannelSelector" | "z" | "zoomAndPan"> & {
19
19
  ref?: ((instance: SVGSVGElement | null) => void) | import("react").RefObject<SVGSVGElement> | null | undefined;
20
20
  }, "children" | keyof import("@mui/material/OverridableComponent").CommonProps | "color" | "fontSize" | "shapeRendering" | "sx" | "viewBox" | "htmlColor" | "titleAccess"> & {
21
21
  children?: import("react").ReactNode;
22
- } & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
22
+ } & import("@mui/system/createStyled").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;