<commit_before>class Skr.Components.PrintFormChooser extends Lanes.React.Component

    propTypes:
        label: React.PropTypes.string.isRequired
        model: Lanes.PropTypes.Model.isRequired
        choices: React.PropTypes.array

    getDefaultProps: ->
        name: 'form'

    onChange: (val) ->
        if @props.onChange
            @props.onChange?(val, @props)
        else
            @props.model[@props.name] = val

    renderValue: (value) ->
        value

    render: ->
        choices = @props.choices || @props.model.constructor.Templates
        value = @props.value or @props.model[@props.name]
        console.log @props.model.form, @props

        <LC.FieldWrapper {...@props} value={value}>

            <Lanes.Vendor.ReactWidgets.DropdownList
                data={choices}
                value={value}
                onChange={@onChange}
            />
        </LC.FieldWrapper>
        # value = @props.value or @props.model[@props.name]
        # props = _.omit(@props, 'choices', 'name')
        # <LC.FormGroup editing={@isEditingRecord()}
        #     className="field" {...props}
        # >
        #     {if @isEditingRecord() then @renderEdit(value) else @renderValue(value)}
        # </LC.FormGroup>
<commit_msg>Remove dead code<commit_after>class Skr.Components.PrintFormChooser extends Lanes.React.Component

    propTypes:
        label: React.PropTypes.string.isRequired
        model: Lanes.PropTypes.Model.isRequired
        choices: React.PropTypes.array

    getDefaultProps: ->
        name: 'form'

    onChange: (val) ->
        if @props.onChange
            @props.onChange?(val, @props)
        else
            @props.model[@props.name] = val

    renderValue: (value) ->
        value

    render: ->
        choices = @props.choices || @props.model.constructor.Templates
        value = @props.value or @props.model[@props.name]
        <LC.FieldWrapper {...@props} value={value}>
            <Lanes.Vendor.ReactWidgets.DropdownList
                data={choices}
                value={value}
                onChange={@onChange}
            />
        </LC.FieldWrapper>

{'fraction_non_alphanumeric': 0.12792877225866917, 'fraction_numerical': 0.0, 'mean_word_length': 1.9818435754189945, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 19, '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': '4497703', 'n_tokens_mistral': 631, 'n_tokens_neox': 624, 'n_words': 108}