king
2024-04-25 050e480c054c278ea8845e75e64466dee6bc0966
2024-04-25
12个文件已修改
124 ■■■■■ 已修改文件
src/menu/components/card/cardcellcomponent/dragaction/index.scss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/card/cardcellcomponent/index.jsx 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/share/actioncomponent/index.jsx 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/share/normalheader/index.jsx 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/share/normalheader/index.scss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/stylecontroller/index.jsx 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/stylecontroller/index.scss 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/cardcellList/index.scss 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/group/normal-group/index.scss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/iframe/index.scss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/share/normalheader/index.scss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/tree/antd-tree/index.scss 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/card/cardcellcomponent/dragaction/index.scss
@@ -4,6 +4,7 @@
    font-style: inherit;
    font-weight: inherit;
    text-decoration: inherit;
    font-family: inherit;
  }
  .ant-mk-text:not(.line1):not(.line) {
    word-break: break-word;
src/menu/components/card/cardcellcomponent/index.jsx
@@ -151,9 +151,13 @@
      } else {
        options.push('width', 'minHeight', 'float')
        _style.minHeight = _style.minHeight || '28px'
        _style.textAlign = _style.textAlign || 'center'
      }
      if (element.wrapStyle) {
        _style.float = element.wrapStyle.textAlign || 'left'
      } else {
        _style.float = _style.float || 'center'
      }
    } else if (element.eleType === 'picture') {
      options = ['background', 'border', 'margin']
@@ -168,6 +172,10 @@
      options = ['padding', 'margin']
    } else if (element.eleType === 'splitline') {
      options = ['padding', 'margin']
    }
    if (['text', 'number', 'formula', 'currentDate'].includes(element.eleType)) {
      options.push('fontFamily')
      _style.fontFamily = _style.fontFamily ? _style.fontFamily.split(',') : []
    }
    if (element.eleType !== 'button' && element.eleType !== 'tag') {
@@ -204,8 +212,16 @@
    let _card = fromJS(card).toJS()
    if (['text', 'number', 'formula', 'currentDate', 'sequence', 'icon'].includes(_card.eleType)) {
      _card.style = style
      _card.style = fromJS(style).toJS()
      let line = _card.height || null
      if (style.fontFamily) {
        if (style.fontFamily.length === 0) {
          delete _card.style.fontFamily
        } else {
          _card.style.fontFamily = style.fontFamily.join(',')
        }
      }
      if (['currentDate', 'sequence'].includes(_card.eleType) || (_card.eleType === 'icon' && _card.tipType !== 'text')) {
        line = 1
@@ -239,9 +255,17 @@
    } else if (_card.eleType === 'button') { // 拆分style
      _card.style = fromJS(style).toJS()
      if (style.float) {
      if (style.float === 'center') {
        delete _card.style.float
      } else if (style.float) {
        _card.wrapStyle = {textAlign: style.float}
        delete _card.style.float
      }
      if (style.textAlign === 'center') {
        delete _card.style.textAlign
      }
      if (style.minHeight === '28px') {
        delete _card.style.minHeight
      }
    } else if (_card.eleType === 'picture') {
      _card.style = style
@@ -380,6 +404,9 @@
          if (!['text', 'number', 'icon'].includes(res.eleType)) {
            delete res.style.display
          }
          if (!['text', 'number', 'formula', 'currentDate'].includes(res.eleType)) {
            delete res.style.fontFamily
          }
          
          if (res.eleType === 'splitline' && (cell.eleType !== 'splitline' || cell.focus)) {
            res.style.paddingTop = '5px'
src/menu/components/share/actioncomponent/index.jsx
@@ -120,7 +120,17 @@
    const { card, actionlist } = this.state
    let _card = fromJS(card).toJS()
    _card.style = style
    _card.style = fromJS(style).toJS()
    if (_card.style.paddingLeft === '15px') {
      delete _card.style.paddingLeft
    }
    if (_card.style.paddingRight === '15px') {
      delete _card.style.paddingRight
    }
    if (_card.style.minHeight === '28px') {
      delete _card.style.minHeight
    }
    let _actionlist = actionlist.map(cell => {
      if (cell.uuid === _card.uuid) return _card
@@ -138,6 +148,10 @@
    let _style = element.style ? fromJS(element.style).toJS() : {}
    let options = ['font', 'border', 'background', 'margin', 'padding', 'minHeight']
    _style.paddingLeft = _style.paddingLeft || '15px'
    _style.paddingRight = _style.paddingRight || '15px'
    _style.minHeight = _style.minHeight || '28px'
    this.setState({
      card: element
    })
src/menu/components/share/normalheader/index.jsx
@@ -36,11 +36,22 @@
  }
  getStyle = (style) => {
    if (!style.borderBottomWidth) {
      style.borderBottomWidth = '0px'
    let _style = fromJS(style).toJS()
    if (!_style.borderBottomWidth) {
      _style.borderBottomWidth = '0px'
    }
    if (_style.fontFamily) {
      if (_style.fontFamily.length === 0) {
        delete _style.fontFamily
      } else {
        _style.fontFamily = _style.fontFamily.join(',')
      }
    }
    if (_style.lineHeight === 2.8) {
      delete _style.lineHeight
    }
    let _config = {...this.props.config, headerStyle: style}
    let _config = {...this.props.config, headerStyle: _style}
    
    this.props.updateComponent(_config)
  }
@@ -48,9 +59,13 @@
  changeStyle = () => {
    const { config } = this.props
    let options = ['font', 'border', 'background', 'padding']
    let _style = config.headerStyle ? fromJS(config.headerStyle).toJS() : {}
    let options = ['font', 'border', 'background', 'padding', 'fontFamily']
    MKEmitter.emit('changeStyle', options, config.headerStyle, this.getStyle)
    _style.fontFamily = _style.fontFamily ? _style.fontFamily.split(',') : []
    _style.lineHeight = _style.lineHeight || 2.8
    MKEmitter.emit('changeStyle', options, _style, this.getStyle)
  }
  render() {
src/menu/components/share/normalheader/index.scss
@@ -12,6 +12,7 @@
    text-decoration: inherit;
    font-weight: inherit;
    font-style: inherit;
    font-family: inherit;
    float: left;
    line-height: inherit;
    margin-left: 10px;
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 } from 'antd'
import {
  ColumnHeightOutlined,
  FontSizeOutlined,
@@ -726,6 +726,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">
@@ -1038,7 +1057,7 @@
                    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>
src/menu/stylecontroller/index.scss
@@ -127,6 +127,22 @@
                  }
                }
              }
              .ant-checkbox-group {
                margin-top: 10px;
                .ant-checkbox-wrapper {
                  color: rgba(255, 255, 255, 0.85);
                  margin-right: 4px;
                  margin-bottom: 2px;
                  .ant-checkbox + span {
                    padding-left: 6px;
                  }
                  .ant-checkbox:not(.ant-checkbox-checked) {
                    .ant-checkbox-inner {
                      background-color: rgba(255, 255, 255, 0.85);
                    }
                  }
                }
              }
            }
          }
        }
src/tabviews/custom/components/card/cardcellList/index.scss
@@ -21,6 +21,7 @@
    font-style: inherit;
    font-weight: inherit;
    text-decoration: inherit;
    font-family: inherit;
    color: inherit;
    .anticon-copy {
      color: var(--mk-sys-color);
@@ -30,6 +31,7 @@
    font-style: inherit;
    font-weight: inherit;
    text-decoration: inherit;
    font-family: inherit;
    .sequence-wrap {
      display: inline-block;
      width: 21px;
@@ -45,6 +47,7 @@
      font-style: inherit;
      font-weight: inherit;
      text-decoration: inherit;
      font-family: inherit;
    }
  }
  .ant-mk-text:not(.line1):not(.line) {
src/tabviews/custom/components/group/normal-group/index.scss
@@ -13,6 +13,7 @@
      text-decoration: inherit;
      font-weight: inherit;
      font-style: inherit;
      font-family: inherit;
      float: left;
      line-height: inherit;
      margin-left: 10px;
src/tabviews/custom/components/iframe/index.scss
@@ -22,6 +22,7 @@
      font-weight: inherit;
      font-style: inherit;
      line-height: inherit;
      font-family: inherit;
      margin-left: 10px;
      position: relative;
      z-index: 1;
src/tabviews/custom/components/share/normalheader/index.scss
@@ -12,6 +12,7 @@
    text-decoration: inherit;
    font-weight: inherit;
    font-style: inherit;
    font-family: inherit;
    float: left;
    line-height: inherit;
    margin-left: 10px;
src/tabviews/custom/components/tree/antd-tree/index.scss
@@ -19,6 +19,7 @@
      text-decoration: inherit;
      font-weight: inherit;
      font-style: inherit;
      font-family: inherit;
      float: left;
      line-height: 45px;
      margin-left: 10px;
@@ -163,8 +164,8 @@
      width: 100%;
      border-radius: 0px;
      border: 0px !important;
      color: rgba(0, 0, 0, 0.85)!important;
      background: transparent !important;
      // color: rgba(0, 0, 0, 0.85)!important;
      // background: transparent !important;
      min-height: 36px;
    }
    button:not(:last-child) {