From e1d8b67d9219f1631e855542155d6db21aa31a97 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期三, 10 七月 2024 14:23:38 +0800 Subject: [PATCH] 2024-07-10 --- src/menu/stylecontroller/index.jsx | 30 +++++++++++++++++++++++++----- 1 files changed, 25 insertions(+), 5 deletions(-) diff --git a/src/menu/stylecontroller/index.jsx b/src/menu/stylecontroller/index.jsx index 7a0b562..850eafb 100644 --- a/src/menu/stylecontroller/index.jsx +++ b/src/menu/stylecontroller/index.jsx @@ -1,6 +1,6 @@ import React, {Component} from 'react' import { is, fromJS } from 'immutable' -import { Collapse, Form, Col, InputNumber, Input, Select, Radio, Drawer, Button, message } from 'antd' +import { Collapse, Form, Col, InputNumber, Input, Select, Radio, Drawer, Button, message, Checkbox, Tooltip } from 'antd' import { ColumnHeightOutlined, FontSizeOutlined, @@ -30,7 +30,8 @@ SwapOutlined, EnterOutlined, DragOutlined, - EyeOutlined + EyeOutlined, + QuestionCircleOutlined } from '@ant-design/icons' import MKEmitter from '@/utils/events.js' @@ -726,6 +727,25 @@ </Radio.Group> </Form.Item> </Col> : null} + {options.includes('fontFamily') ? <Col span={24}> + <Form.Item + colon={false} + label=" " + labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + > + <Checkbox.Group options={[ + { label: '寰蒋闆呴粦', value: 'Microsoft YaHei' }, + { label: '瀹嬩綋', value: 'Simsun' }, + { label: '榛戜綋', value: 'Simhei' }, + { label: '浠垮畫', value: 'FangSong' }, + { label: '妤蜂綋', value: 'KaiTi' }, + // { label: 'Helvetica', value: 'Helvetica' }, + // { label: 'Arial', value: 'Arial' }, + // { label: 'Verdana', value: 'Verdana' }, + // { label: 'Georgia', value: 'Georgia' }, + ]} defaultValue={card.fontFamily} onChange={(val) => this.changeNormalStyle(val, 'fontFamily')} /> + </Form.Item> + </Col> : null} </Panel> : null} {options.includes('background') || options.includes('backgroundColor') ? <Panel header="鑳屾櫙" key="background"> <Col span={24} className="bg-color-panel"> @@ -1031,14 +1051,14 @@ </Form.Item> </Col> </Panel> : null} - {options.includes('float') ? <Panel header="瀵归綈鏂瑰紡" key="float"> + {options.includes('float') ? <Panel header={<Tooltip placement="topLeft" title="鎸夐挳鐩稿浜庢爡鏍肩殑浣嶇疆锛屾敞锛氳缃搴︽椂鏈夋晥銆�">瀵归綈鏂瑰紡<QuestionCircleOutlined style={{marginLeft: '3px'}} /></Tooltip>} key="float"> <Col span={24}> <Form.Item colon={false} label={<SwapOutlined title="瀵归綈"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Radio.Group style={{whiteSpace: 'nowrap'}} defaultValue={card.float || (type === 'mk-button' ? 'center' : 'left')} onChange={(e) => this.changeNormalStyle(e.target.value, 'float')}> + <Radio.Group style={{whiteSpace: 'nowrap'}} defaultValue={card.float || 'left'} onChange={(e) => this.changeNormalStyle(e.target.value, 'float')}> <Radio value="left">宸�</Radio> <Radio value="center">灞呬腑</Radio> <Radio value="right">鍙�</Radio> @@ -1076,7 +1096,7 @@ <Col span={24}> <Form.Item colon={false} - label={<SwapOutlined title="娴姩"/>} + label={<SwapOutlined title="鏄剧ず"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > <Radio.Group style={{whiteSpace: 'nowrap'}} defaultValue={card.display || 'block'} onChange={(e) => this.changeNormalStyle(e.target.value, 'display')}> -- Gitblit v1.8.0