123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108 |
- // 输入框组件
- import { positionList } from './article';
- import { commonSetProperty, serialNumberStyleList } from './common';
- // 模式列表
- export const modelList = [
- {
- value: 'pinyin',
- label: '拼音',
- },
- {
- value: 'chinese',
- label: '汉字',
- },
- {
- value: 'english',
- label: '英文',
- },
- ];
- // 输入框样式
- export const inputStyleList = [
- {
- value: 'horizontal_line',
- label: '横线',
- },
- {
- value: 'input',
- label: '输入框',
- },
- ];
- export const fontList = [
- {
- value: 'arial, helvetica, sans-serif',
- label: 'Arial',
- isPinyin: false,
- },
- {
- value: 'League',
- label: '拼音=League',
- isPinyin: true,
- },
- {
- value: '楷体,微软雅黑',
- label: '楷体=楷体,微软雅黑',
- isPinyin: false,
- },
- {
- value: '黑体,微软雅黑',
- label: '黑体=黑体,微软雅黑;',
- isPinyin: false,
- },
- {
- value: '宋体,微软雅黑',
- label: '宋体=宋体,微软雅黑;',
- isPinyin: false,
- },
- ];
- export const fontSizeList = [12, 14, 16, 18, 20, 22, 24, 26, 28, 30];
- export const textAlignList = [
- {
- value: 'left',
- label: '左对齐',
- },
- {
- value: 'center',
- label: '居中对齐',
- },
- {
- value: 'right',
- label: '右对齐',
- },
- ];
- export function getInputProperty() {
- return {
- ...commonSetProperty,
- sn_style: serialNumberStyleList[0].value,
- sn_background_color: '#ea3232', // 序号背景色
- is_enable_pinyin: true, // 是否启用拼音
- pinyin_position: positionList[0].value, // 拼音位置
- is_enable_sentence_case: true, // 句首大写
- is_enable_auto_correct: true, // 自动修正
- model: modelList[0].value, // 模式
- input_style: inputStyleList[0].value, // 输入框样式
- font: fontList[1].value, // 字体
- font_size: fontSizeList[3], // 字体大小
- text_align: textAlignList[0].value, // 文本对齐方式
- text_color: '#1d2129', // 文本颜色
- background_color: '#ffffff', // 背景色
- };
- }
- export function getInputData() {
- return {
- type: 'input',
- title: '输入框',
- property: getInputProperty(),
- answer: {
- text: '', // 答案文本
- },
- content: '', // 文本内容
- };
- }
|