import template from '../templates/toolbarCheckboxItem.html';

const classes = {
    CHECKED: 'editor_checked'
};

export default Marionette.ItemView.extend({
    className: 'toolbar-btn',

    template: Handlebars.compile(template),

    ui: {
        check: '.js-check'
    },

    onRender() {
        if (this.model.get('isActive')) {
            this.ui.check.toggleClass(classes.CHECKED);
        }
    },

    events: {
        click: '__handleClick'
    },

    __handleClick() {
        const oldState = this.model.get('isActive');
        this.model.set('isActive', !oldState);
        this.ui.check.toggleClass(classes.CHECKED);
        this.trigger('action:click', this.model);
    }
});

@@ -320,22 +320,23 @@
 .get('is
-Active
+Checked
 ')) %7B%0A  
@@ -525,22 +525,23 @@
 .get('is
-Active
+Checked
 ');%0A    
@@ -566,14 +566,15 @@
 ('is
-Active
+Checked
 ', !

rename property