king
2021-12-22 bd1dfc9e6c9b9f8076ca2783ce598e0936b4c664
src/mob/components/search/single-search/index.jsx
@@ -1,7 +1,8 @@
import React, { Component } from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Popover, Icon, Input, Button } from 'antd'
import { Popover, Input, Button } from 'antd'
import { ToolOutlined, ScanOutlined, EditOutlined, FontColorsOutlined, DeleteOutlined } from '@ant-design/icons'
import zhCN from '@/locales/zh-CN/model.js'
import enUS from '@/locales/en-US/model.js'
@@ -138,19 +139,19 @@
      <div className="single-search-edit-list" onClick={this.clickComponent} id={card.uuid} style={_style}>
        <div className="search-wrap" style={{borderRadius: card.wrap.borderRadius || 0, height: card.wrap.height || 32}}>
          <Input placeholder={card.wrap.label} value={card.wrap.initval || ''} />
          {card.wrap.scan === 'show' ? <Icon type="scan" style={{lineHeight: `${card.wrap.height || 32}px`}} /> : null}
          {card.wrap.scan === 'show' ? <ScanOutlined style={{lineHeight: `${card.wrap.height || 32}px`}} /> : null}
          {card.wrap.show === 'text' ? <Button type="primary">搜索</Button> : <Button icon="search" type="primary"></Button>}
        </div>
        <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={
          <div className="mk-popover-control">
            <NormalForm title="搜索设置" width={800} update={this.updateWrap} getForms={this.getWrapForms}>
              <Icon type="edit" style={{color: '#1890ff'}} title="编辑"/>
              <EditOutlined style={{color: '#1890ff'}} title="编辑"/>
            </NormalForm>
            <Icon className="style" title="调整样式" onClick={this.changeStyle} type="font-colors" />
            <Icon className="close" title="delete" type="delete" onClick={() => this.props.deletecomponent(card.uuid)} />
            <FontColorsOutlined className="style" title="调整样式" onClick={this.changeStyle}/>
            <DeleteOutlined className="close" onClick={() => this.props.deletecomponent(card.uuid)} />
          </div>
        } trigger="hover">
          <Icon type="tool" />
          <ToolOutlined />
        </Popover>
      </div>
    )