eli-video-interview 1.4.7 → 1.6.0
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.
- package/esm/components/Charts/ReportPie.js +2 -2
- package/esm/index.d.ts +2 -0
- package/esm/index.js +2 -0
- package/esm/modules/ai-question/Root.js +13 -13
- package/esm/modules/ai-question/components/AiAssessmentCriteria/const.d.ts +4 -0
- package/esm/modules/ai-question/components/AiAssessmentCriteria/const.js +4 -0
- package/esm/modules/ai-question/components/AiAssessmentCriteria/index.js +2 -5
- package/esm/modules/ai-question/components/QuestionUpdate/AudioUploader.d.ts +6 -0
- package/esm/modules/ai-question/components/QuestionUpdate/AudioUploader.js +74 -0
- package/esm/modules/ai-question/components/QuestionUpdate/Form.js +16 -5
- package/esm/modules/ai-question/components/QuestionUpdate/const.js +1 -1
- package/esm/modules/ai-question/components/QuestionUpdate/interface.d.ts +3 -1
- package/esm/modules/ai-report/components/AIEvaluate/index.js +1 -1
- package/esm/modules/ai-report/interface.d.ts +28 -0
- package/esm/modules/ai-report-v3/Root.d.ts +4 -0
- package/esm/modules/ai-report-v3/Root.js +110 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/Evaluate.d.ts +11 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/Evaluate.js +79 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/Graph.d.ts +22 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/Graph.js +272 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/index.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/AIEvaluate/index.js +32 -0
- package/esm/modules/ai-report-v3/components/Candidate/Candidate.d.ts +7 -0
- package/esm/modules/ai-report-v3/components/Candidate/Candidate.js +55 -0
- package/esm/modules/ai-report-v3/components/Candidate/Interface.d.ts +16 -0
- package/esm/modules/ai-report-v3/components/Candidate/Interface.js +1 -0
- package/esm/modules/ai-report-v3/components/Candidate/Podium.d.ts +6 -0
- package/esm/modules/ai-report-v3/components/Candidate/Podium.js +50 -0
- package/esm/modules/ai-report-v3/components/Candidate/index.d.ts +2 -0
- package/esm/modules/ai-report-v3/components/Candidate/index.js +2 -0
- package/esm/modules/ai-report-v3/components/CapabilityTable/CapabilityTable.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/CapabilityTable/CapabilityTable.js +62 -0
- package/esm/modules/ai-report-v3/components/CheatRisk/CheatRisk.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/CheatRisk/CheatRisk.js +42 -0
- package/esm/modules/ai-report-v3/components/Form/Form.d.ts +23 -0
- package/esm/modules/ai-report-v3/components/Form/Form.js +67 -0
- package/esm/modules/ai-report-v3/components/Form/Forms.d.ts +9 -0
- package/esm/modules/ai-report-v3/components/Form/Forms.js +45 -0
- package/esm/modules/ai-report-v3/components/Form/Nps.d.ts +6 -0
- package/esm/modules/ai-report-v3/components/Form/Nps.js +57 -0
- package/esm/modules/ai-report-v3/components/Form/index.d.ts +1 -0
- package/esm/modules/ai-report-v3/components/Form/index.js +1 -0
- package/esm/modules/ai-report-v3/components/Form/interface.d.ts +57 -0
- package/esm/modules/ai-report-v3/components/Form/interface.js +1 -0
- package/esm/modules/ai-report-v3/components/MenuAnchor/index.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/MenuAnchor/index.js +130 -0
- package/esm/modules/ai-report-v3/components/ModuleTitle.d.ts +5 -0
- package/esm/modules/ai-report-v3/components/ModuleTitle.js +24 -0
- package/esm/modules/ai-report-v3/components/NotFinish/index.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/NotFinish/index.js +32 -0
- package/esm/modules/ai-report-v3/components/RankingRange/Item.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/RankingRange/Item.js +46 -0
- package/esm/modules/ai-report-v3/components/RankingRange/index.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/RankingRange/index.js +187 -0
- package/esm/modules/ai-report-v3/components/RankingRange/interface.d.ts +26 -0
- package/esm/modules/ai-report-v3/components/RankingRange/interface.js +1 -0
- package/esm/modules/ai-report-v3/components/RankingRange/styled.d.ts +7 -0
- package/esm/modules/ai-report-v3/components/RankingRange/styled.js +11 -0
- package/esm/modules/ai-report-v3/components/ReportHeader/ReportHeader.d.ts +17 -0
- package/esm/modules/ai-report-v3/components/ReportHeader/ReportHeader.js +105 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Bar.d.ts +6 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Bar.js +68 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Failed.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Failed.js +33 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/RecommendIcon.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/RecommendIcon.js +17 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Report.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Report.js +22 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Score.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Score.js +83 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/ScoreLegend.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/ScoreLegend.js +33 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Tips.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/Tips.js +18 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/index.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/index.js +39 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/interface.d.ts +20 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/interface.js +1 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/styled.d.ts +22 -0
- package/esm/modules/ai-report-v3/components/ScoreReport/styled.js +21 -0
- package/esm/modules/ai-report-v3/components/SectionTabs/SectionTabs.d.ts +11 -0
- package/esm/modules/ai-report-v3/components/SectionTabs/SectionTabs.js +114 -0
- package/esm/modules/ai-report-v3/components/Suggestion/Suggestion.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/Suggestion/Suggestion.js +31 -0
- package/esm/modules/ai-report-v3/components/Suggestion/index.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/Suggestion/index.js +27 -0
- package/esm/modules/ai-report-v3/components/V3Header/V3Header.d.ts +11 -0
- package/esm/modules/ai-report-v3/components/V3Header/V3Header.js +154 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Abilities.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Abilities.js +42 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/BodyImages.d.ts +7 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/BodyImages.js +56 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Evaluate.d.ts +11 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Evaluate.js +79 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/QuestionItem.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/QuestionItem.js +145 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/ScoreSlider.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/ScoreSlider.js +47 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/SingleChoice.d.ts +8 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/SingleChoice.js +31 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Workplaces.d.ts +10 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/Workplaces.js +91 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/index.d.ts +6 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/index.js +24 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/interface.d.ts +17 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/interface.js +1 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/styled.d.ts +72 -0
- package/esm/modules/ai-report-v3/components/VideoQuestion/styled.js +93 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/ScoreSlider.d.ts +4 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/ScoreSlider.js +24 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/WorkPlace.d.ts +12 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/WorkPlace.js +72 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/index.d.ts +3 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/index.js +70 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/interface.d.ts +7 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/interface.js +1 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/styled.d.ts +62 -0
- package/esm/modules/ai-report-v3/components/WorkPlaces/styled.js +27 -0
- package/esm/modules/ai-report-v3/components/styled.d.ts +42 -0
- package/esm/modules/ai-report-v3/components/styled.js +140 -0
- package/esm/modules/ai-report-v3/index.d.ts +4 -0
- package/esm/modules/ai-report-v3/index.js +20 -0
- package/esm/modules/ai-report-v3/interface.d.ts +257 -0
- package/esm/modules/ai-report-v3/interface.js +1 -0
- package/esm/modules/ai-report-v3/useAiReport.d.ts +37 -0
- package/esm/modules/ai-report-v3/useAiReport.js +18 -0
- package/esm/modules/ai-report-v3/useAiReportVersion.d.ts +5 -0
- package/esm/modules/ai-report-v3/useAiReportVersion.js +45 -0
- package/esm/modules/ai-report-v3/utils.d.ts +1 -0
- package/esm/modules/ai-report-v3/utils.js +1 -0
- package/lib/components/Charts/ReportPie.js +2 -2
- package/lib/index.d.ts +2 -0
- package/lib/index.js +5 -1
- package/lib/modules/ai-question/Root.js +13 -13
- package/lib/modules/ai-question/components/AiAssessmentCriteria/const.d.ts +4 -0
- package/lib/modules/ai-question/components/AiAssessmentCriteria/const.js +5 -1
- package/lib/modules/ai-question/components/AiAssessmentCriteria/index.js +1 -4
- package/lib/modules/ai-question/components/QuestionUpdate/AudioUploader.d.ts +6 -0
- package/lib/modules/ai-question/components/QuestionUpdate/AudioUploader.js +76 -0
- package/lib/modules/ai-question/components/QuestionUpdate/Form.js +18 -7
- package/lib/modules/ai-question/components/QuestionUpdate/const.js +1 -1
- package/lib/modules/ai-question/components/QuestionUpdate/interface.d.ts +3 -1
- package/lib/modules/ai-report/components/AIEvaluate/index.js +1 -1
- package/lib/modules/ai-report/interface.d.ts +28 -0
- package/lib/modules/ai-report-v3/Root.d.ts +4 -0
- package/lib/modules/ai-report-v3/Root.js +115 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/Evaluate.d.ts +11 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/Evaluate.js +81 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/Graph.d.ts +22 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/Graph.js +276 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/index.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/AIEvaluate/index.js +37 -0
- package/lib/modules/ai-report-v3/components/Candidate/Candidate.d.ts +7 -0
- package/lib/modules/ai-report-v3/components/Candidate/Candidate.js +57 -0
- package/lib/modules/ai-report-v3/components/Candidate/Interface.d.ts +16 -0
- package/lib/modules/ai-report-v3/components/Candidate/Interface.js +2 -0
- package/lib/modules/ai-report-v3/components/Candidate/Podium.d.ts +6 -0
- package/lib/modules/ai-report-v3/components/Candidate/Podium.js +52 -0
- package/lib/modules/ai-report-v3/components/Candidate/index.d.ts +2 -0
- package/lib/modules/ai-report-v3/components/Candidate/index.js +10 -0
- package/lib/modules/ai-report-v3/components/CapabilityTable/CapabilityTable.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/CapabilityTable/CapabilityTable.js +64 -0
- package/lib/modules/ai-report-v3/components/CheatRisk/CheatRisk.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/CheatRisk/CheatRisk.js +44 -0
- package/lib/modules/ai-report-v3/components/Form/Form.d.ts +23 -0
- package/lib/modules/ai-report-v3/components/Form/Form.js +73 -0
- package/lib/modules/ai-report-v3/components/Form/Forms.d.ts +9 -0
- package/lib/modules/ai-report-v3/components/Form/Forms.js +50 -0
- package/lib/modules/ai-report-v3/components/Form/Nps.d.ts +6 -0
- package/lib/modules/ai-report-v3/components/Form/Nps.js +59 -0
- package/lib/modules/ai-report-v3/components/Form/index.d.ts +1 -0
- package/lib/modules/ai-report-v3/components/Form/index.js +8 -0
- package/lib/modules/ai-report-v3/components/Form/interface.d.ts +57 -0
- package/lib/modules/ai-report-v3/components/Form/interface.js +2 -0
- package/lib/modules/ai-report-v3/components/MenuAnchor/index.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/MenuAnchor/index.js +132 -0
- package/lib/modules/ai-report-v3/components/ModuleTitle.d.ts +5 -0
- package/lib/modules/ai-report-v3/components/ModuleTitle.js +28 -0
- package/lib/modules/ai-report-v3/components/NotFinish/index.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/NotFinish/index.js +34 -0
- package/lib/modules/ai-report-v3/components/RankingRange/Item.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/RankingRange/Item.js +48 -0
- package/lib/modules/ai-report-v3/components/RankingRange/index.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/RankingRange/index.js +192 -0
- package/lib/modules/ai-report-v3/components/RankingRange/interface.d.ts +26 -0
- package/lib/modules/ai-report-v3/components/RankingRange/interface.js +2 -0
- package/lib/modules/ai-report-v3/components/RankingRange/styled.d.ts +7 -0
- package/lib/modules/ai-report-v3/components/RankingRange/styled.js +14 -0
- package/lib/modules/ai-report-v3/components/ReportHeader/ReportHeader.d.ts +17 -0
- package/lib/modules/ai-report-v3/components/ReportHeader/ReportHeader.js +110 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Bar.d.ts +6 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Bar.js +70 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Failed.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Failed.js +34 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/RecommendIcon.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/RecommendIcon.js +22 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Report.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Report.js +27 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Score.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Score.js +86 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/ScoreLegend.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/ScoreLegend.js +35 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Tips.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/Tips.js +20 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/index.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/index.js +44 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/interface.d.ts +20 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/interface.js +2 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/styled.d.ts +22 -0
- package/lib/modules/ai-report-v3/components/ScoreReport/styled.js +24 -0
- package/lib/modules/ai-report-v3/components/SectionTabs/SectionTabs.d.ts +11 -0
- package/lib/modules/ai-report-v3/components/SectionTabs/SectionTabs.js +116 -0
- package/lib/modules/ai-report-v3/components/Suggestion/Suggestion.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/Suggestion/Suggestion.js +33 -0
- package/lib/modules/ai-report-v3/components/Suggestion/index.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/Suggestion/index.js +32 -0
- package/lib/modules/ai-report-v3/components/V3Header/V3Header.d.ts +11 -0
- package/lib/modules/ai-report-v3/components/V3Header/V3Header.js +159 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Abilities.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Abilities.js +47 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/BodyImages.d.ts +7 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/BodyImages.js +61 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Evaluate.d.ts +11 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Evaluate.js +81 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/QuestionItem.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/QuestionItem.js +150 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/ScoreSlider.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/ScoreSlider.js +49 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/SingleChoice.d.ts +8 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/SingleChoice.js +33 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Workplaces.d.ts +10 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/Workplaces.js +93 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/index.d.ts +6 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/index.js +29 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/interface.d.ts +17 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/interface.js +2 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/styled.d.ts +72 -0
- package/lib/modules/ai-report-v3/components/VideoQuestion/styled.js +96 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/ScoreSlider.d.ts +4 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/ScoreSlider.js +26 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/WorkPlace.d.ts +12 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/WorkPlace.js +74 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/index.d.ts +3 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/index.js +75 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/interface.d.ts +7 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/interface.js +2 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/styled.d.ts +62 -0
- package/lib/modules/ai-report-v3/components/WorkPlaces/styled.js +30 -0
- package/lib/modules/ai-report-v3/components/styled.d.ts +42 -0
- package/lib/modules/ai-report-v3/components/styled.js +146 -0
- package/lib/modules/ai-report-v3/index.d.ts +4 -0
- package/lib/modules/ai-report-v3/index.js +25 -0
- package/lib/modules/ai-report-v3/interface.d.ts +257 -0
- package/lib/modules/ai-report-v3/interface.js +2 -0
- package/lib/modules/ai-report-v3/useAiReport.d.ts +37 -0
- package/lib/modules/ai-report-v3/useAiReport.js +25 -0
- package/lib/modules/ai-report-v3/useAiReportVersion.d.ts +5 -0
- package/lib/modules/ai-report-v3/useAiReportVersion.js +49 -0
- package/lib/modules/ai-report-v3/utils.d.ts +1 -0
- package/lib/modules/ai-report-v3/utils.js +5 -0
- package/package.json +5 -5
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
13
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
14
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
15
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
16
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
17
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
18
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
22
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
23
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
24
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
|
+
function step(op) {
|
|
26
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
+
while (_) try {
|
|
28
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
|
+
switch (op[0]) {
|
|
31
|
+
case 0: case 1: t = op; break;
|
|
32
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
33
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
34
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
35
|
+
default:
|
|
36
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
37
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
38
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
39
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
40
|
+
if (t[2]) _.ops.pop();
|
|
41
|
+
_.trys.pop(); continue;
|
|
42
|
+
}
|
|
43
|
+
op = body.call(thisArg, _);
|
|
44
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
45
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
49
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
50
|
+
if (!m) return o;
|
|
51
|
+
var i = m.call(o), r, ar = [], e;
|
|
52
|
+
try {
|
|
53
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
54
|
+
}
|
|
55
|
+
catch (error) { e = { error: error }; }
|
|
56
|
+
finally {
|
|
57
|
+
try {
|
|
58
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
59
|
+
}
|
|
60
|
+
finally { if (e) throw e.error; }
|
|
61
|
+
}
|
|
62
|
+
return ar;
|
|
63
|
+
};
|
|
64
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
65
|
+
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
66
|
+
import { AddIcon, Box, Button, Dialog, Message, Typography } from 'fbm-ui';
|
|
67
|
+
import { useImmer } from 'use-immer';
|
|
68
|
+
import ScrollDialogContent from "../../../../components/ScrollDialogContent";
|
|
69
|
+
import { useAiReportStore } from "../../../../store/ai-report/global-store";
|
|
70
|
+
import RankingRangeItem from './Item';
|
|
71
|
+
var RankingRange = function (_a) {
|
|
72
|
+
var open = _a.open, onClose = _a.onClose;
|
|
73
|
+
var isCall = useRef(false);
|
|
74
|
+
var _b = __read(useState(false), 2), loading = _b[0], setLoading = _b[1];
|
|
75
|
+
var _c = __read(useImmer([]), 2), interval = _c[0], updateInterval = _c[1];
|
|
76
|
+
var _d = useAiReportStore(function (store) { return [store.scoreRankIntervals]; }), scoreRankIntervals = _d.scoreRankIntervals, onScoreRankIntervalsChange = _d.onScoreRankIntervalsChange, onScoreRankIntervalsSubmit = _d.onScoreRankIntervalsSubmit;
|
|
77
|
+
var formatScoreRankIntervals = useCallback(function (scoreRankIntervals) {
|
|
78
|
+
isCall.current = false;
|
|
79
|
+
updateInterval(scoreRankIntervals.map(function (item) { return (__assign(__assign({}, item), { scoreRankIntervals: {
|
|
80
|
+
startRankProportion: item.scoreRankIntervals.startRankProportion * 100,
|
|
81
|
+
endRankProportion: item.scoreRankIntervals.endRankProportion * 100,
|
|
82
|
+
} })); }));
|
|
83
|
+
}, [updateInterval]);
|
|
84
|
+
useEffect(function () {
|
|
85
|
+
formatScoreRankIntervals(scoreRankIntervals || []);
|
|
86
|
+
}, [scoreRankIntervals, formatScoreRankIntervals]);
|
|
87
|
+
useEffect(function () {
|
|
88
|
+
var rankIntervals = interval.map(function (_a) {
|
|
89
|
+
var _b = _a.scoreRankIntervals, startRankProportion = _b.startRankProportion, endRankProportion = _b.endRankProportion;
|
|
90
|
+
return ({
|
|
91
|
+
startRankProportion: startRankProportion / 100,
|
|
92
|
+
endRankProportion: endRankProportion / 100,
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
if (isCall.current) {
|
|
96
|
+
onScoreRankIntervalsChange && onScoreRankIntervalsChange(rankIntervals);
|
|
97
|
+
}
|
|
98
|
+
}, [interval, onScoreRankIntervalsChange]);
|
|
99
|
+
var handleAdd = useCallback(function () {
|
|
100
|
+
var lastItem = interval[interval.length - 1];
|
|
101
|
+
var lastStartRankProportion = lastItem === null || lastItem === void 0 ? void 0 : lastItem.scoreRankIntervals.startRankProportion;
|
|
102
|
+
if (interval.length === 5) {
|
|
103
|
+
Message.error('最多添加5条记录');
|
|
104
|
+
}
|
|
105
|
+
else if (lastStartRankProportion === 99) {
|
|
106
|
+
Message.error('最后一条记录起始值为99无法分割');
|
|
107
|
+
}
|
|
108
|
+
else {
|
|
109
|
+
updateInterval(function (draft) {
|
|
110
|
+
var insertStartRank = lastItem ? Math.ceil(lastStartRankProportion + (99 - lastStartRankProportion) / 2) : 100;
|
|
111
|
+
draft.splice(interval.length - 1, 0, {
|
|
112
|
+
rank: interval.length,
|
|
113
|
+
score: {
|
|
114
|
+
startScore: 0,
|
|
115
|
+
endScore: 0,
|
|
116
|
+
isFloat: false,
|
|
117
|
+
isInInterval: false,
|
|
118
|
+
},
|
|
119
|
+
scoreRankIntervals: {
|
|
120
|
+
startRankProportion: lastItem ? lastStartRankProportion : 0,
|
|
121
|
+
endRankProportion: insertStartRank,
|
|
122
|
+
},
|
|
123
|
+
});
|
|
124
|
+
draft[interval.length].scoreRankIntervals.startRankProportion = lastItem ? insertStartRank : 0;
|
|
125
|
+
});
|
|
126
|
+
isCall.current = true;
|
|
127
|
+
}
|
|
128
|
+
}, [interval, updateInterval]);
|
|
129
|
+
var handleChange = useCallback(function (value, index) {
|
|
130
|
+
var prevValue = index === 0 ? 1 : interval[index - 1].scoreRankIntervals.endRankProportion + 1;
|
|
131
|
+
var nextValue = index === interval.length - 1 ? 100 : interval[index + 1].scoreRankIntervals.endRankProportion;
|
|
132
|
+
var canChange = value >= prevValue && value <= nextValue && value !== interval[index].scoreRankIntervals.endRankProportion;
|
|
133
|
+
if (canChange) {
|
|
134
|
+
updateInterval(function (draft) {
|
|
135
|
+
draft[index].scoreRankIntervals.endRankProportion = value;
|
|
136
|
+
draft[index + 1].scoreRankIntervals.startRankProportion = value;
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
else {
|
|
140
|
+
updateInterval(function (draft) {
|
|
141
|
+
draft[index] = __assign({}, interval[index]);
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
isCall.current = true;
|
|
145
|
+
}, [interval, updateInterval]);
|
|
146
|
+
var handleDelete = useCallback(function (index) {
|
|
147
|
+
updateInterval(function (draft) {
|
|
148
|
+
var deleteItem = interval[index];
|
|
149
|
+
draft.splice(index, 1);
|
|
150
|
+
draft[index - 1].scoreRankIntervals.endRankProportion = deleteItem.scoreRankIntervals.endRankProportion;
|
|
151
|
+
});
|
|
152
|
+
isCall.current = true;
|
|
153
|
+
}, [interval, updateInterval]);
|
|
154
|
+
var handleOk = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
155
|
+
var rankIntervals, error_1;
|
|
156
|
+
return __generator(this, function (_a) {
|
|
157
|
+
switch (_a.label) {
|
|
158
|
+
case 0:
|
|
159
|
+
if (!onScoreRankIntervalsSubmit) return [3 /*break*/, 4];
|
|
160
|
+
rankIntervals = interval.map(function (_a) {
|
|
161
|
+
var _b = _a.scoreRankIntervals, startRankProportion = _b.startRankProportion, endRankProportion = _b.endRankProportion;
|
|
162
|
+
return ({
|
|
163
|
+
startRankProportion: startRankProportion / 100,
|
|
164
|
+
endRankProportion: endRankProportion / 100,
|
|
165
|
+
});
|
|
166
|
+
});
|
|
167
|
+
setLoading(true);
|
|
168
|
+
_a.label = 1;
|
|
169
|
+
case 1:
|
|
170
|
+
_a.trys.push([1, 3, , 4]);
|
|
171
|
+
return [4 /*yield*/, onScoreRankIntervalsSubmit(rankIntervals)];
|
|
172
|
+
case 2:
|
|
173
|
+
_a.sent();
|
|
174
|
+
setLoading(false);
|
|
175
|
+
onClose();
|
|
176
|
+
return [3 /*break*/, 4];
|
|
177
|
+
case 3:
|
|
178
|
+
error_1 = _a.sent();
|
|
179
|
+
setLoading(false);
|
|
180
|
+
return [3 /*break*/, 4];
|
|
181
|
+
case 4: return [2 /*return*/];
|
|
182
|
+
}
|
|
183
|
+
});
|
|
184
|
+
}); };
|
|
185
|
+
return (_jsx(Dialog, __assign({ open: open, title: "\u6392\u540D\u533A\u95F4\u8BBE\u7F6E", size: "sm", okProps: { loading: loading }, onClose: onClose, onOk: handleOk }, { children: _jsx(ScrollDialogContent, { children: _jsxs(Box, __assign({ sx: { padding: 3 } }, { children: [_jsxs(Box, __assign({ display: "flex", sx: { mb: 2 } }, { children: [_jsx(Typography, __assign({ flex: "1 0", variant: "body1" }, { children: "\u6392\u540D\u524D" })), _jsx(Typography, __assign({ flex: "1 0", variant: "body1" }, { children: "\u5206\u6570" }))] })), interval.map(function (item, index) { return (_jsx(RankingRangeItem, { item: item, index: index, disabled: index === interval.length - 1, onChange: handleChange, onDelete: handleDelete }, item.rank)); }), _jsx(Button, __assign({ icon: _jsx(AddIcon, {}), sx: { mt: 2 }, variant: "outlined", color: "inherit", onClick: handleAdd }, { children: "\u6DFB\u52A0\u6392\u540D\u533A\u95F4" }))] })) }) })));
|
|
186
|
+
};
|
|
187
|
+
export default RankingRange;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export interface ScoreRankIntervals {
|
|
2
|
+
startRankProportion: number;
|
|
3
|
+
endRankProportion: number;
|
|
4
|
+
}
|
|
5
|
+
export interface Score {
|
|
6
|
+
startScore: number;
|
|
7
|
+
endScore: number;
|
|
8
|
+
isFloat: boolean;
|
|
9
|
+
isInInterval: boolean;
|
|
10
|
+
}
|
|
11
|
+
export interface ScoreRankInterval {
|
|
12
|
+
rank: number;
|
|
13
|
+
scoreRankIntervals: ScoreRankIntervals;
|
|
14
|
+
score: Score;
|
|
15
|
+
}
|
|
16
|
+
export interface RankingRangeItemProps {
|
|
17
|
+
index: number;
|
|
18
|
+
disabled: boolean;
|
|
19
|
+
item: ScoreRankInterval;
|
|
20
|
+
onChange: (value: number, index: number) => void;
|
|
21
|
+
onDelete: (index: number) => void;
|
|
22
|
+
}
|
|
23
|
+
export interface RankingRangeProps {
|
|
24
|
+
open: boolean;
|
|
25
|
+
onClose: () => void;
|
|
26
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const RangeInput: import("@emotion/styled").StyledComponent<import("fbm-ui").BaseInputProps & import("@mui/material").OutlinedInputProps & import("@mui/material").InputProps & {
|
|
3
|
+
children?: import("react").ReactNode;
|
|
4
|
+
} & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
5
|
+
export declare const RangeTypography: import("@emotion/styled").StyledComponent<import("fbm-ui/lib/components/Typography").TypographyProps & {
|
|
6
|
+
children?: import("react").ReactNode;
|
|
7
|
+
} & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Input, styled, Typography } from 'fbm-ui';
|
|
2
|
+
export var RangeInput = styled(Input)({
|
|
3
|
+
width: 82,
|
|
4
|
+
});
|
|
5
|
+
export var RangeTypography = styled(Typography)(function (_a) {
|
|
6
|
+
var theme = _a.theme;
|
|
7
|
+
return ({
|
|
8
|
+
color: "".concat(theme.palette.primary.main, " !important"),
|
|
9
|
+
lineHeight: '38px !important',
|
|
10
|
+
});
|
|
11
|
+
});
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { AiReportUrl, CandidateInfo } from '../Candidate/Interface';
|
|
3
|
+
export interface ReportHeaderProps {
|
|
4
|
+
status: number;
|
|
5
|
+
customScore?: number;
|
|
6
|
+
onRefreshSuccess: () => void;
|
|
7
|
+
fetchCandidateInfo: () => Promise<CandidateInfo>;
|
|
8
|
+
fetchReportUrl: () => Promise<AiReportUrl>;
|
|
9
|
+
}
|
|
10
|
+
declare const ReportHeader: ({ customScore, onRefreshSuccess, fetchCandidateInfo, status, fetchReportUrl }: {
|
|
11
|
+
customScore: any;
|
|
12
|
+
onRefreshSuccess: any;
|
|
13
|
+
fetchCandidateInfo: any;
|
|
14
|
+
status: any;
|
|
15
|
+
fetchReportUrl: any;
|
|
16
|
+
}) => JSX.Element;
|
|
17
|
+
export default ReportHeader;
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
13
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
14
|
+
if (!m) return o;
|
|
15
|
+
var i = m.call(o), r, ar = [], e;
|
|
16
|
+
try {
|
|
17
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
18
|
+
}
|
|
19
|
+
catch (error) { e = { error: error }; }
|
|
20
|
+
finally {
|
|
21
|
+
try {
|
|
22
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
23
|
+
}
|
|
24
|
+
finally { if (e) throw e.error; }
|
|
25
|
+
}
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
29
|
+
import AIEvaluate from '../AIEvaluate';
|
|
30
|
+
import { CandidateReport, PodiumReport } from '../Candidate';
|
|
31
|
+
import { DinTypography, ReportBadge, ReportLabel } from '../styled';
|
|
32
|
+
import { INTERVIEW_STATUS } from "../../../../enum/ai-report";
|
|
33
|
+
import { PostAiInterviewRefresh } from "../../../../services/ai-report";
|
|
34
|
+
import { useAiReportStore } from "../../../../store/ai-report/global-store";
|
|
35
|
+
import { formatScore } from "../../../../utils/utils";
|
|
36
|
+
import { useRequest } from 'ahooks';
|
|
37
|
+
import dayjs from 'dayjs';
|
|
38
|
+
import { RefreshIcon, ShareIcon } from 'fbm-icons';
|
|
39
|
+
import { Box, Button, IconButton, Message, Popover, Typography } from 'fbm-ui';
|
|
40
|
+
import { Stack } from 'fbm-ui/lib/mui';
|
|
41
|
+
import { useEffect, useMemo, useState } from 'react';
|
|
42
|
+
var ReportHeader = function (_a) {
|
|
43
|
+
var customScore = _a.customScore, onRefreshSuccess = _a.onRefreshSuccess, fetchCandidateInfo = _a.fetchCandidateInfo, status = _a.status, fetchReportUrl = _a.fetchReportUrl;
|
|
44
|
+
var _b = __read(useState(false), 2), openRefresh = _b[0], setOpenRefresh = _b[1];
|
|
45
|
+
var _c = __read(useState(null), 2), reportUrl = _c[0], setReportUrl = _c[1];
|
|
46
|
+
var _d = useAiReportStore(function (store) { return [
|
|
47
|
+
store.token,
|
|
48
|
+
store.reportResult,
|
|
49
|
+
store.operableButtons,
|
|
50
|
+
]; }), token = _d.token, reportResult = _d.reportResult, operableButtons = _d.operableButtons, onExportReportClick = _d.onExportReportClick;
|
|
51
|
+
var _e = reportResult || {}, score = _e.score, createTime = _e.createTime, model = _e.model;
|
|
52
|
+
var _f = __read(useState(score || 0), 2), feScore = _f[0], setScore = _f[1];
|
|
53
|
+
var _g = useRequest(function () { return PostAiInterviewRefresh(token); }, {
|
|
54
|
+
manual: true,
|
|
55
|
+
onSuccess: function () {
|
|
56
|
+
onRefreshSuccess();
|
|
57
|
+
Message.success('刷新成功');
|
|
58
|
+
},
|
|
59
|
+
}), run = _g.run, loading = _g.loading;
|
|
60
|
+
var level = useMemo(function () {
|
|
61
|
+
if (feScore >= 80)
|
|
62
|
+
return 'high';
|
|
63
|
+
if (feScore >= 60)
|
|
64
|
+
return 'middle';
|
|
65
|
+
return 'low';
|
|
66
|
+
}, [feScore]);
|
|
67
|
+
useEffect(function () {
|
|
68
|
+
if (!fetchReportUrl)
|
|
69
|
+
return;
|
|
70
|
+
fetchReportUrl()
|
|
71
|
+
.then(function (_a) {
|
|
72
|
+
var url = _a.url;
|
|
73
|
+
setReportUrl(url);
|
|
74
|
+
})
|
|
75
|
+
.catch(function () { return Message.error('获取报告链接失败'); });
|
|
76
|
+
}, [fetchReportUrl]);
|
|
77
|
+
var content = (_jsxs(Box, __assign({ padding: 2 }, { children: [_jsx(Typography, __assign({ variant: "body1", color: "secondary" }, { children: "\u5237\u65B0\u540E\u5C06\u6309\u6700\u65B0\u7B97\u5206\u89C4\u5219\u8BA1\u7B97\uFF0C\u662F\u5426\u786E\u8BA4\u5237\u65B0" })), _jsx(Box, __assign({ paddingTop: 1, textAlign: "right" }, { children: _jsx(Button, __assign({ loading: loading, onClick: run }, { children: "\u5237\u65B0" })) }))] })));
|
|
78
|
+
useEffect(function () {
|
|
79
|
+
if (typeof customScore === 'number' && customScore > -1) {
|
|
80
|
+
setScore(customScore);
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
setScore(score || 0);
|
|
84
|
+
}
|
|
85
|
+
if (!loading)
|
|
86
|
+
setOpenRefresh(false);
|
|
87
|
+
}, [loading, customScore, score]);
|
|
88
|
+
return (_jsxs(Stack, __assign({ position: "relative" }, { children: [model === 'pro' && _jsx(ReportBadge, {}), _jsx(ReportLabel, { level: status === INTERVIEW_STATUS.COMPLETED ? level : 'calculation' }), _jsxs(Stack, __assign({ direction: "row", alignItems: "center", justifyContent: "space-between", sx: {
|
|
89
|
+
width: 'calc(100% - 180px)',
|
|
90
|
+
position: 'absolute',
|
|
91
|
+
top: 0,
|
|
92
|
+
zIndex: 2,
|
|
93
|
+
} }, { children: [_jsxs(Stack, __assign({ direction: "row", alignItems: "center", pl: 3, py: 3 }, { children: [_jsxs(Typography, __assign({ variant: "caption", sx: {
|
|
94
|
+
color: 'rgba(74, 74, 74, 0.86)',
|
|
95
|
+
} }, { children: ["\u62A5\u544A\u751F\u6210\u65F6\u95F4\uFF1A", dayjs(createTime && createTime * 1000).format('YYYY-MM-DD HH:mm')] })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('refresh')) && (_jsx(Popover, __assign({ open: openRefresh, content: content, onClickAway: function () { return setOpenRefresh(false); } }, { children: _jsx(IconButton, __assign({ onClick: function () { return setOpenRefresh(true); } }, { children: _jsx(RefreshIcon, { sx: {
|
|
96
|
+
color: '#009908',
|
|
97
|
+
} }) })) })))] })), _jsx(DinTypography, __assign({ variant: "h5", textAlign: "center", color: "#009D56", sx: { alignSelf: 'center' } }, { children: "AI \u9762\u8BD5\u62A5\u544A" })), (operableButtons === null || operableButtons === void 0 ? void 0 : operableButtons.includes('export')) ? (_jsx(Button, __assign({ endIcon: _jsx(ShareIcon, {}), variant: "text", onClick: onExportReportClick, sx: { borderRadius: 18, border: '1px solid #4caf50' } }, { children: "\u5BFC\u51FA\u62A5\u544A" }))) : reportUrl ? (_jsx("a", __assign({ href: reportUrl, title: "\u67E5\u770B\u5728\u7EBF\u62A5\u544A", style: {
|
|
98
|
+
textDecoration: 'none',
|
|
99
|
+
} }, { children: _jsx(Button, __assign({ endIcon: _jsx(ShareIcon, {}), variant: "text", sx: { borderRadius: 18, border: '1px solid #4caf50' } }, { children: "\u67E5\u770B\u5728\u7EBF\u62A5\u544A" })) }))) : (_jsx(Box, {}))] })), _jsxs(Stack, { children: [fetchCandidateInfo && status === INTERVIEW_STATUS.COMPLETED && _jsx(CandidateReport, { fetchCandidateInfo: fetchCandidateInfo }), !fetchCandidateInfo && status === INTERVIEW_STATUS.COMPLETED && _jsx(PodiumReport, { score: formatScore(feScore || 0) }), status !== INTERVIEW_STATUS.COMPLETED && (_jsx(Box, { sx: {
|
|
100
|
+
position: 'relative',
|
|
101
|
+
width: 541,
|
|
102
|
+
height: 342,
|
|
103
|
+
} }))] }), status === INTERVIEW_STATUS.COMPLETED && (_jsx(Stack, __assign({ width: 1, direction: "row" }, { children: _jsx(AIEvaluate, {}) })))] })));
|
|
104
|
+
};
|
|
105
|
+
export default ReportHeader;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
13
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
14
|
+
if (!m) return o;
|
|
15
|
+
var i = m.call(o), r, ar = [], e;
|
|
16
|
+
try {
|
|
17
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
18
|
+
}
|
|
19
|
+
catch (error) { e = { error: error }; }
|
|
20
|
+
finally {
|
|
21
|
+
try {
|
|
22
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
23
|
+
}
|
|
24
|
+
finally { if (e) throw e.error; }
|
|
25
|
+
}
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
29
|
+
import { rankPercent } from '../../utils';
|
|
30
|
+
import { scoreRankIntervalModeColors } from "../../../../constants/ai-report";
|
|
31
|
+
import { useAiReportStore } from "../../../../store/ai-report/global-store";
|
|
32
|
+
import { Box, Typography } from 'fbm-ui';
|
|
33
|
+
import { useEffect, useState } from 'react';
|
|
34
|
+
var Bar = function (_a) {
|
|
35
|
+
var _b = _a.model, model = _b === void 0 ? 'standard' : _b;
|
|
36
|
+
var _c = __read(useState(1), 2), currentRank = _c[0], setCurrentRank = _c[1];
|
|
37
|
+
var _d = __read(useState(''), 2), text = _d[0], setText = _d[1];
|
|
38
|
+
var _e = useAiReportStore(function (store) { return [store.reportResult, store.scoreRankIntervals]; }), reportResult = _e.reportResult, scoreRankIntervals = _e.scoreRankIntervals, reportRank = _e.reportRank;
|
|
39
|
+
var _f = (reportResult || {}).score, score = _f === void 0 ? 0 : _f;
|
|
40
|
+
useEffect(function () {
|
|
41
|
+
var floatInterval = scoreRankIntervals === null || scoreRankIntervals === void 0 ? void 0 : scoreRankIntervals.find(function (interval) { return score >= interval.score.startScore && score <= interval.score.endScore; });
|
|
42
|
+
if (floatInterval) {
|
|
43
|
+
var rank = floatInterval.rank;
|
|
44
|
+
setCurrentRank(rank);
|
|
45
|
+
}
|
|
46
|
+
if (reportRank === null || reportRank === void 0 ? void 0 : reportRank.total) {
|
|
47
|
+
setText("\u51FB\u8D25\u4E86".concat(rankPercent((reportRank === null || reportRank === void 0 ? void 0 : reportRank.rank) || 0, (reportRank === null || reportRank === void 0 ? void 0 : reportRank.total) || 0).toFixed(0), "%\u5019\u9009\u4EBA"));
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
setText('');
|
|
51
|
+
}
|
|
52
|
+
}, [score, reportRank, scoreRankIntervals]);
|
|
53
|
+
if (!scoreRankIntervals || (scoreRankIntervals === null || scoreRankIntervals === void 0 ? void 0 : scoreRankIntervals.length) === 0)
|
|
54
|
+
return null;
|
|
55
|
+
return (_jsxs(Box, { children: [_jsxs(Typography, __assign({ color: "inherit", variant: "body2", flexShrink: 0 }, { children: [text, "\u00A0"] })), _jsx(Box, __assign({ display: "flex", alignItems: "center", sx: { height: 12, mt: 0.5 } }, { children: scoreRankIntervals === null || scoreRankIntervals === void 0 ? void 0 : scoreRankIntervals.map(function (_a, index) {
|
|
56
|
+
var _b;
|
|
57
|
+
var rank = _a.rank, _c = _a.scoreRankIntervals, startRankProportion = _c.startRankProportion, endRankProportion = _c.endRankProportion;
|
|
58
|
+
return [
|
|
59
|
+
_jsx(Box, { sx: {
|
|
60
|
+
width: "".concat((endRankProportion - startRankProportion) * 100, "%"),
|
|
61
|
+
height: currentRank === rank ? 'calc(100% + 4px)' : '100%',
|
|
62
|
+
background: (_b = scoreRankIntervalModeColors === null || scoreRankIntervalModeColors === void 0 ? void 0 : scoreRankIntervalModeColors[model]) === null || _b === void 0 ? void 0 : _b[index],
|
|
63
|
+
border: '2px solid rgb(255, 255, 255)',
|
|
64
|
+
} }, rank),
|
|
65
|
+
];
|
|
66
|
+
}) }))] }));
|
|
67
|
+
};
|
|
68
|
+
export default Bar;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
+
import { BackgroundImage, // , Colors, SwitchTitle
|
|
14
|
+
} from "../../../../enum/ai-report";
|
|
15
|
+
import { INTERVIEW_STATUS } from "../../../../enum/ai-report";
|
|
16
|
+
// import { SwitchIcon } from 'fbm-icons';
|
|
17
|
+
import { Box, Button, CancelIcon, RefreshIcon, Typography } from 'fbm-ui';
|
|
18
|
+
var FAILED = INTERVIEW_STATUS.FAILED;
|
|
19
|
+
var Failed = function (_a) {
|
|
20
|
+
var loading = _a.loading, status = _a.status, onRefresh = _a.onRefresh, _b = _a.model, model = _b === void 0 ? 'standard' : _b, onSwitchReportModel = _a.onSwitchReportModel;
|
|
21
|
+
return (_jsxs(Box, __assign({ loading: loading, display: "flex", alignItems: "center", padding: "32px 24px", sx: {
|
|
22
|
+
px: 3,
|
|
23
|
+
height: 280,
|
|
24
|
+
background: "url('".concat(BackgroundImage[model], "') no-repeat center center / cover"),
|
|
25
|
+
overflow: 'hidden',
|
|
26
|
+
borderRadius: '0 0 62px 62px',
|
|
27
|
+
} }, { children: [status === FAILED && (_jsx(CancelIcon, { style: {
|
|
28
|
+
color: '#ff6c6c',
|
|
29
|
+
width: '24px',
|
|
30
|
+
height: '24px',
|
|
31
|
+
} })), _jsx(Typography, __assign({ variant: "body2", color: "textSecondary" }, { children: status === FAILED ? '报告计算失败,请手动' : '报告正在计算中,请稍后查看或手动' })), _jsx(Button, __assign({ variant: "text", endIcon: _jsx(RefreshIcon, {}), size: "small", style: { color: '#576B95', padding: '0px 4px' }, onClick: onRefresh }, { children: "\u5237\u65B0\u62A5\u544A" }))] })));
|
|
32
|
+
};
|
|
33
|
+
export default Failed;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
+
import SvgIcon from '@mui/material/SvgIcon';
|
|
14
|
+
var RecommendIcon = function (props) {
|
|
15
|
+
return (_jsx(SvgIcon, __assign({}, props, { viewBox: "0 0 120 120" }, { children: _jsx("path", { d: "M84.407 24.379a2.648 2.648 0 0 1 1.186 2.298c-.131 4.575 3.655 8.601 8.247 8.731a2.656 2.656 0 0 1 2.415 3.58 8.473 8.473 0 0 0 .119 6.286 8.543 8.543 0 0 0 4.889 4.634 2.656 2.656 0 0 1 .898 4.42 8.43 8.43 0 0 0-.343 12.008 2.656 2.656 0 0 1-.82 4.238 8.472 8.472 0 0 0-4.362 4.53 8.42 8.42 0 0 0 .18 6.733 2.656 2.656 0 0 1-2.491 3.764 8.427 8.427 0 0 0-8.73 8.246 2.65 2.65 0 0 1-3.58 2.415 8.473 8.473 0 0 0-6.287.118 8.405 8.405 0 0 0-4.475 4.49 2.642 2.642 0 0 1-.73 1.389c-1.045 1.044-2.746 1.16-3.775-.02l-.085-.084c-1.79-1.79-3.916-2.676-6.164-2.678a8.475 8.475 0 0 0-5.831 2.345 2.659 2.659 0 0 1-4.24-.82 8.487 8.487 0 0 0-4.53-4.362 8.42 8.42 0 0 0-6.733.178 2.656 2.656 0 0 1-3.763-2.49c.133-4.577-3.66-8.602-8.248-8.732a2.651 2.651 0 0 1-2.415-3.58 8.473 8.473 0 0 0-.119-6.286 8.546 8.546 0 0 0-4.889-4.634 2.656 2.656 0 0 1-.898-4.42 8.432 8.432 0 0 0 .344-12.007 2.656 2.656 0 0 1 .82-4.24 8.424 8.424 0 0 0 4.182-11.262 2.656 2.656 0 0 1 2.49-3.764 8.427 8.427 0 0 0 8.731-8.246 2.65 2.65 0 0 1 3.58-2.415 8.436 8.436 0 0 0 10.919-5.007 2.663 2.663 0 0 1 1.96-1.679 2.702 2.702 0 0 1 2.461.782l.011.011c1.79 1.79 3.914 2.675 6.166 2.677a8.472 8.472 0 0 0 5.832-2.346 2.661 2.661 0 0 1 4.239.825 8.426 8.426 0 0 0 11.26 4.181 2.648 2.648 0 0 1 2.58.193Zm-3.778 5.706c-2.532.45-5.14.172-7.522-.798a13.723 13.723 0 0 1-5.704-4.315 13.705 13.705 0 0 1-14.178-.216 13.626 13.626 0 0 1-5.884 4.757 13.68 13.68 0 0 1-7.086.978 13.68 13.68 0 0 1-3.564 6.205 13.624 13.624 0 0 1-6.613 3.671c.45 2.532.174 5.139-.796 7.52a13.672 13.672 0 0 1-4.319 5.71 13.706 13.706 0 0 1 1.87 6.903 13.627 13.627 0 0 1-2.085 7.278 13.683 13.683 0 0 1 5.742 12.965 13.667 13.667 0 0 1 6.203 3.563 13.627 13.627 0 0 1 3.674 6.615c2.532-.45 5.14-.173 7.522.798 2.25.911 4.218 2.4 5.706 4.317a13.705 13.705 0 0 1 14.176.214 13.618 13.618 0 0 1 5.884-4.757 13.68 13.68 0 0 1 7.088-.98 13.664 13.664 0 0 1 3.562-6.203 13.624 13.624 0 0 1 6.61-3.675c-.45-2.532-.174-5.14.797-7.522a13.67 13.67 0 0 1 4.32-5.702 13.705 13.705 0 0 1 .215-14.185 13.683 13.683 0 0 1-5.74-12.963c-4.839-1.274-8.771-5.36-9.878-10.178Zm-37.034 47.32a2.656 2.656 0 1 1-3.756 3.756 2.656 2.656 0 0 1 3.756-3.757Zm5.635 5.634a2.656 2.656 0 1 1-3.756 3.756 2.656 2.656 0 0 1 3.756-3.756ZM36.77 71.082a2.656 2.656 0 1 1-1.376 5.132 2.656 2.656 0 0 1 1.376-5.132ZM50.819 33.61a1.328 1.328 0 0 1-.318 2.278 26.351 26.351 0 0 0-8.786 5.833 26.491 26.491 0 0 0-5.835 8.784 1.328 1.328 0 0 1-2.46-.996 29.024 29.024 0 0 1 6.417-9.666 28.977 28.977 0 0 1 9.666-6.417c.44-.178.942-.108 1.316.184Zm36.508 36.428.094.11c.294.388.353.905.153 1.349a29.024 29.024 0 0 1-6.417 9.666 28.977 28.977 0 0 1-9.666 6.417 1.323 1.323 0 0 1-1.728-.732 1.328 1.328 0 0 1 .73-1.73 26.351 26.351 0 0 0 8.786-5.833 26.491 26.491 0 0 0 5.835-8.784 1.328 1.328 0 0 1 2.307-.353Zm-13.559 3.55-1.473 1.473-3.756-1.172 2.9 2.9-1.593 1.593-3.44-3.441-1.263 1.262c-1.457 1.458-2.329 1.458-4.027 0l-.917-.766 1.082-2.134 1.082.902c.661.54.827.466 1.307-.015l.992-.992-3.53-3.531 1.592-1.593 3.531 3.531.406-.405 2.464.901-4.433-4.433 1.578-1.577 7.498 7.498ZM58.171 45.97l1.352 2.043c-.766.466-1.547.887-2.329 1.248l1.939 1.938 1.307-2.029 1.818 1.638-1.397 2.119 2.239 2.239-1.698 1.698-2.435-2.435-1.487 1.488 2.194 2.194-1.608 1.608-2.194-2.194-1.518 1.517 2.194 2.194-1.668 1.668-2.194-2.194-1.532 1.533 2.795 2.795-1.683 1.683-8.295-8.295 7.048-7.047-.526.105.856-2.78c.33-.06.646-.135.962-.21l-.631-.63-1.863 1.862c.3.15.57.3.841.421l-.796 1.037-.782 1.022-1.142-.601-3.621 3.62c-1.337 1.338-2.104 1.443-3.591.286l-1.097-.856 1.217-2.3 1.007.767c.45.36.826.196 1.232-.21l2.54-2.54c-.872-.42-1.624-.871-2.195-1.111l1.458-2.24c.721.391 1.623.932 2.614 1.473l2.405-2.404-1.398-1.397 1.848-1.849 1.398 1.398 2.103-2.104 1.698 1.848-2.028 2.029 1.052 1.052-1.142 1.142c1.728-.526 3.125-1.202 4.733-2.24Zm16.844 17.175 1.698 1.848-.766.766 3.185 3.186-1.653 1.652-3.185-3.185-.676.676-1.773-1.773.676-.676-2.885-2.885-.376.376.917 1.427-.752.3 6.657 6.657-1.623 1.623-7.483-7.483c-1.112.3-2.179.526-3.32.616l-6.191 6.19-1.728-1.727 4.432-4.433a27.952 27.952 0 0 1-2.509-.285l.857-2.66c2.193.42 4.282.466 6.31.15l-2.479-2.48 1.623-1.622 3.471 3.471.736-.285-.991-.992.646-.646-3.186-3.186 1.653-1.653 3.186 3.186.841-.842 1.728 1.879-.766.766 2.885 2.885.841-.841Zm-24.207-4.313-1.788-1.788-1.533 1.533 1.789 1.788 1.532-1.533Zm3.186-3.185-1.788-1.789-1.518 1.518 1.788 1.788 1.518-1.517Zm3.095-3.096-1.788-1.788-1.488 1.488 1.789 1.788 1.487-1.488Zm29.701-7.073a2.656 2.656 0 1 1-3.756 3.757 2.656 2.656 0 0 1 3.756-3.757Zm-5.635-5.634A2.656 2.656 0 1 1 77.4 43.6a2.656 2.656 0 0 1 3.756-3.756Zm-6.825-6.322a2.656 2.656 0 1 1-1.375 5.131 2.656 2.656 0 0 1 1.375-5.131Z", fill: "currentColor", fillRule: "evenodd" }) })));
|
|
16
|
+
};
|
|
17
|
+
export default RecommendIcon;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
+
import ReportPie from "../../../../components/Charts/ReportPie";
|
|
14
|
+
import ScoreBigBall from "../../../../components/ScoreBigBall";
|
|
15
|
+
import { useAiReportStore } from "../../../../store/ai-report/global-store";
|
|
16
|
+
import { Box } from 'fbm-ui';
|
|
17
|
+
var Report = function () {
|
|
18
|
+
var reportResult = useAiReportStore(function (store) { return [store.reportResult]; }).reportResult;
|
|
19
|
+
var _a = reportResult || {}, orderToken = _a.orderToken, score = _a.score, status = _a.status, _b = _a.collection, collection = _b === void 0 ? [] : _b;
|
|
20
|
+
return (_jsx(Box, __assign({ width: 400, flexShrink: 0 }, { children: _jsxs(Box, __assign({ height: 300, sx: { position: 'relative' } }, { children: [_jsx(ReportPie, { id: orderToken || '', source: collection }), _jsx(ScoreBigBall, { score: score || 0, status: status })] })) })));
|
|
21
|
+
};
|
|
22
|
+
export default Report;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
13
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
14
|
+
if (!m) return o;
|
|
15
|
+
var i = m.call(o), r, ar = [], e;
|
|
16
|
+
try {
|
|
17
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
18
|
+
}
|
|
19
|
+
catch (error) { e = { error: error }; }
|
|
20
|
+
finally {
|
|
21
|
+
try {
|
|
22
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
23
|
+
}
|
|
24
|
+
finally { if (e) throw e.error; }
|
|
25
|
+
}
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
29
|
+
import RankingRange from '../RankingRange';
|
|
30
|
+
import Bar from './Bar';
|
|
31
|
+
import RecommendIcon from './RecommendIcon';
|
|
32
|
+
import { RefreshIconRoot, ScoreTypography, ScoreUnitTypography } from './styled';
|
|
33
|
+
// import Tips from './Tips';
|
|
34
|
+
import { BackgroundImage, Colors, // SwitchTitle
|
|
35
|
+
} from "../../../../enum/ai-report";
|
|
36
|
+
import { useAiReportStore } from "../../../../store/ai-report/global-store";
|
|
37
|
+
import { formatScore } from "../../../../utils/utils";
|
|
38
|
+
import dayjs from 'dayjs';
|
|
39
|
+
// import { SwitchIcon } from 'fbm-icons';
|
|
40
|
+
import { Box, Button, DownloadIcon, // InfoOutlineIcon,
|
|
41
|
+
Popover, Typography, } from 'fbm-ui';
|
|
42
|
+
import { Stack } from 'fbm-ui/lib/mui';
|
|
43
|
+
import { useEffect, useState } from 'react';
|
|
44
|
+
var Score = function (_a) {
|
|
45
|
+
var customScore = _a.customScore, loading = _a.loading, onRefresh = _a.onRefresh, onSwitchReportModel = _a.onSwitchReportModel, _b = _a.model, model = _b === void 0 ? 'standard' : _b;
|
|
46
|
+
var _c = __read(useState(false), 2), openRankingRange = _c[0], setOpenRankingRange = _c[1];
|
|
47
|
+
var _d = __read(useState(false), 2), openRefresh = _d[0], setOpenRefresh = _d[1];
|
|
48
|
+
var _e = useAiReportStore(function (store) { return [store.reportResult, store.operableButtons]; }), reportResult = _e.reportResult, operableButtons = _e.operableButtons, onExportReportClick = _e.onExportReportClick;
|
|
49
|
+
var _f = reportResult || {}, score = _f.score, createTime = _f.createTime;
|
|
50
|
+
var _g = __read(useState(score || 0), 2), feScore = _g[0], setScore = _g[1];
|
|
51
|
+
useEffect(function () {
|
|
52
|
+
if (typeof customScore === 'number' && customScore > -1) {
|
|
53
|
+
setScore(customScore);
|
|
54
|
+
}
|
|
55
|
+
else {
|
|
56
|
+
setScore(score || 0);
|
|
57
|
+
}
|
|
58
|
+
if (!loading)
|
|
59
|
+
setOpenRefresh(false);
|
|
60
|
+
}, [loading, customScore, score]);
|
|
61
|
+
var content = (_jsxs(Box, __assign({ padding: 2 }, { children: [_jsx(Typography, __assign({ variant: "body1", color: "secondary" }, { children: "\u5237\u65B0\u540E\u5C06\u6309\u6700\u65B0\u7B97\u5206\u89C4\u5219\u8BA1\u7B97\uFF0C\u662F\u5426\u786E\u8BA4\u5237\u65B0" })), _jsx(Box, __assign({ paddingTop: 1, textAlign: "right" }, { children: _jsx(Button, __assign({ loading: loading, onClick: onRefresh }, { children: "\u5237\u65B0" })) }))] })));
|
|
62
|
+
return (_jsxs(Stack, __assign({ display: "flex", sx: {
|
|
63
|
+
px: 3,
|
|
64
|
+
height: 280,
|
|
65
|
+
background: "url('".concat(BackgroundImage[model], "') no-repeat center center / cover"),
|
|
66
|
+
overflow: 'hidden',
|
|
67
|
+
borderRadius: '0 0 62px 62px',
|
|
68
|
+
} }, { children: [model === 'pro' && (_jsx(Box, __assign({ display: "flex", alignItems: "center", justifyContent: "center", width: 92, height: 30, sx: {
|
|
69
|
+
position: 'absolute',
|
|
70
|
+
top: 0,
|
|
71
|
+
left: 0,
|
|
72
|
+
backgroundColor: Colors[model],
|
|
73
|
+
borderBottomRightRadius: 16,
|
|
74
|
+
} }, { children: _jsx(Typography, __assign({ variant: "body2", fontWeight: "medium", color: "white" }, { children: "\u9AD8\u7CBE\u51C6\u5EA6" })) }))), _jsx(RankingRange, { open: openRankingRange, onClose: function () { return setOpenRankingRange(false); } }), _jsx(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')) && (_jsx(_Fragment, { children: _jsx(Button, __assign({ variant: "outlined", size: "small", icon: _jsx(DownloadIcon, {}), sx: {
|
|
75
|
+
ml: 1,
|
|
76
|
+
color: 'inherit',
|
|
77
|
+
borderColor: 'inherit',
|
|
78
|
+
'&:hover': {
|
|
79
|
+
borderColor: 'inherit',
|
|
80
|
+
},
|
|
81
|
+
}, onClick: onExportReportClick }, { children: "\u5BFC\u51FA\u62A5\u544A" })) })) })), _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] }) }))] }))] })));
|
|
82
|
+
};
|
|
83
|
+
export default Score;
|