<commit_before><?php

/**
 * Text Editor (use wp_editor)
 */
class plugme_form_control_texteditor extends plugme_form_control
{
    /**
     * Default options
     * @var array
     */
    protected $default_options = array(
        'label'       => '',
        'description' => '',  
        'attrs'       => array(
            'required'    => false,
            'placeholder' => '',
        ),
        'settings'    => array(
            'teeny'         => true,
            'textarea_rows' => 8,
            'tabindex'      => 1,
            'media_buttons' => false
        )
    );

    /**
     * Generated the control
     * 
     * @return string
     */
    public function generate()
    {
        $attrs = $this->attributes();
        
        ob_start();
        wp_editor(stripslashes($this->data), $this->name, $this->options['settings']);
        $wp_editor = ob_get_contents();
        ob_end_clean();
<commit_msg>show media upload button by default<commit_after><?php

/**
 * Text Editor (use wp_editor)
 */
class plugme_form_control_texteditor extends plugme_form_control
{
    /**
     * Default options
     * @var array
     */
    protected $default_options = array(
        'label'       => '',
        'description' => '',  
        'attrs'       => array(
            'required'    => false,
            'placeholder' => '',
        ),
        'settings'    => array(
            'teeny'         => true,
            'textarea_rows' => 8,
            'tabindex'      => 1,
            'media_buttons' => true
        )
    );

    /**
     * Generated the control
     * 
     * @return string
     */
    public function generate()
    {
        $attrs = $this->attributes();
        
        ob_start();
        wp_editor(stripslashes($this->data), $this->name, $this->options['settings']);
        $wp_editor = ob_get_contents();
        ob_end_clean();

{'fraction_non_alphanumeric': 0.14445034519383962, 'fraction_numerical': 0.002124269782262347, 'mean_word_length': 1.6022099447513811, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 31, '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': '3085006', 'n_tokens_mistral': 550, 'n_tokens_neox': 543, 'n_words': 105}