import { stemTypeList, questionNumberTypeList, scoreTypeList, switchOption, fontSizeList } from './common'; /** * 解析智能识别数据 * @param {array} arr 智能识别数据 * @returns object */ export function analysisRecognitionReadAloudData(arr) { if (arr.length === 0) return {}; let reg = /^文段[::]/; let text = reg.test(arr[0]) ? arr[0].replace(reg, '') : ''; return { 'data.text': text }; } // 朗读题数据模板 export const readAloudData = { type: 'read_aloud', // 题型 stem: '', // 题干 description: '', // 提示 text: '', // 文段 file_id_list: [], // 文件 id 列表 answer: { score: 1, score_type: scoreTypeList[0].value, }, // 答案 // 题型属性 property: { stem_type: stemTypeList[1].value, // 题干类型 question_number: '1', // 题号 stem_question_number_font_size: fontSizeList[6], // 题干题号 is_enable_listening: switchOption[0].value, // 是否开启听力 is_enable_description: switchOption[1].value, // 是否开启提示 score: 1, // 分值 score_type: scoreTypeList[0].value, // 分值类型 }, // 其他属性 other: { question_number_type: questionNumberTypeList[1].value, // 题号类型 }, };