protected function makeVisibilityAction($data)
    {
        extract($data);

        // Check if this model supports editing the visibility
        if ($many_to_many
            || !app('decoy.user')->can('publish', $controller)
            || !array_key_exists('public', $this->attributes)) {
            return;
        }

        // Create the markup
        $public = $this->getAttribute('public');
        return sprintf('<a class="visibility js-tooltip" data-placement="left" title="%s">
                <span class="glyphicon glyphicon-eye-%s"></span>
            </a>',
            $public ? __('decoy::base.standard_list.private') : __('decoy::base.standard_list.publish'),
            $public ? 'open' : 'close'
        );
    }