<commit_before>###
Drag tasks handle (and other support)
###

{React, rclass, rtypes}  = require('../smc-react')

{Icon, Tip} = require('../r_misc')

{SortableHandle} = require('react-sortable-hoc')

DragHandle = rclass
    render: ->
        <Icon style={cursor:'pointer'} name='reorder' />

SortableDragHandle = SortableHandle(DragHandle)

DisabledDragHandle = rclass
    render : ->
        <Tip title={'Select Custom Order to enable dragging tasks.'} delayShow={700}>
            <DragHandle />
        </Tip>

exports.DragHandle = rclass
    propTypes :
        sortable : rtypes.bool

    render: ->
        if @props.sortable
            color = '#888'
            Handle = SortableDragHandle
        else
            color = '#ddd'
            Handle = DisabledDragHandle
        <div style={fontSize:'17pt', color:color, flex:1}>
            <Handle />
        </div><commit_msg>tasks: fix width<commit_after>###
Drag tasks handle (and other support)
###

{React, rclass, rtypes}  = require('../smc-react')

{Icon, Tip} = require('../r_misc')

{SortableHandle} = require('react-sortable-hoc')

DragHandle = rclass
    render: ->
        <Icon style={cursor:'pointer'} name='reorder' />

SortableDragHandle = SortableHandle(DragHandle)

DisabledDragHandle = rclass
    render : ->
        <Tip title={'Select Custom Order to enable dragging tasks.'} delayShow={700}>
            <DragHandle />
        </Tip>

exports.DragHandle = rclass
    propTypes :
        sortable : rtypes.bool

    render: ->
        if @props.sortable
            color = '#888'
            Handle = SortableDragHandle
        else
            color = '#ddd'
            Handle = DisabledDragHandle
        <div style={fontSize:'17pt', color:color, width:'40px'}>
            <Handle />
        </div>
{'fraction_non_alphanumeric': 0.13837535014005603, 'fraction_numerical': 0.010644257703081233, 'mean_word_length': 2.376181474480151, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7462687', 'n_tokens_mistral': 542, 'n_tokens_neox': 526, 'n_words': 123}