| | |
| | | }, |
| | | }) |
| | | |
| | | let _style = {opacity: isDragging ? 0 : 1} |
| | | let _style = {opacity: isDragging ? 0.3 : 1} |
| | | |
| | | if (card.style) { |
| | | _style = {...card.style, opacity: isDragging ? 0 : 1} |
| | | _style = {...card.style, opacity: isDragging ? 0.3 : 1} |
| | | _style = resetStyle(_style) |
| | | } |
| | | if (card.eleType === 'picture' && card.maxWidth) { |
| | |
| | | able = false |
| | | } |
| | | |
| | | let _style_ = null |
| | | |
| | | if (card.style && card.style.clear === 'left') { |
| | | _style_ = {clear: 'left'} |
| | | } |
| | | |
| | | return ( |
| | | <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={ |
| | | <div className="mk-popover-control" onDoubleClick={(e) => e.stopPropagation()}> |
| | |
| | | {['text', 'number', 'slider', 'sequence', 'formula'].includes(card.eleType) ? <MarkColumn field={card.field || ''} columns={fields} type={card.eleType} marks={card.marks} onSubmit={(vals) => updateMarks({...card, marks: vals})} /> : null } |
| | | </div> |
| | | } trigger="hover"> |
| | | <div ref={node => drag(drop(node))} className={'ant-col card-cell ant-col-' + card.width}> |
| | | <div ref={node => drag(drop(node))} style={_style_} className={'ant-col card-cell ant-col-' + card.width}> |
| | | <div style={_style} onClick={clickComponent} onDoubleClick={() => able && editCard(id)} id={card.uuid}> |
| | | {getContent()} |
| | | </div> |