| | |
| | | } |
| | | } |
| | | }) |
| | | const opacity = isDragging ? 0 : 1 |
| | | const opacity = isDragging ? 0.5 : 1 |
| | | |
| | | const edit = () => { |
| | | editCard(id) |
| | |
| | | } |
| | | |
| | | const changeStyle = () => { |
| | | let options = ['font'] |
| | | let options = ['font1'] |
| | | |
| | | MKEmitter.emit('changeStyle', ['form', card.uuid], options, card.style || {}) |
| | | } |
| | |
| | | formItem = (<Input style={{marginTop: '4px'}} placeholder={card.placeholder || ''} value={card.initval} />) |
| | | } else if (card.type === 'number') { |
| | | formItem = (<InputNumber value={card.initval} precision={card.decimal} />) |
| | | } else if (card.type === 'multiselect' || card.type === 'select' || card.type === 'link') { |
| | | } else if (card.type === 'multiselect' || card.type === 'select' || card.type === 'link' || card.type === 'cascader') { |
| | | formItem = (<Select value={selectval}></Select>) |
| | | } else if (card.type === 'color') { |
| | | formItem = (<ColorSketch value={card.initval || 'transparent'}/>) |
| | |
| | | <Checkbox value="D">D</Checkbox> |
| | | </Checkbox.Group>) |
| | | } else if (card.type === 'hint') { |
| | | formItem = <div style={{marginTop: '10px', color: 'rgba(0, 0, 0, 0.85)', lineHeight: '1.5', ...card.style}}>{card.message}</div> |
| | | formItem = <div style={{marginTop: '8px', color: 'rgba(0, 0, 0, 0.85)', lineHeight: '1.5', ...card.style}}>{card.message}</div> |
| | | } else if (card.type === 'formula') { |
| | | formItem = <div style={{marginTop: '8px', color: 'rgba(0, 0, 0, 0.85)', lineHeight: '1.5', ...card.style}}>{card.formula}{card.postfix || ''}</div> |
| | | } else if (card.type === 'split') { |
| | | formItem = <div className="split-line" style={card.style}>{card.label}</div> |
| | | } else if (card.type === 'checkcard') { |
| | |
| | | if (card.type === 'brafteditor' && card.hidelabel === 'true') { |
| | | _label = null |
| | | } else if (card.type === 'hint' && !card.label) { |
| | | className += ' no-label' |
| | | _label = ' ' |
| | | } |
| | | |