<commit_before><?php
namespace Concrete\Authentication\Community;

use Concrete\Core\Authentication\Type\Community\Service\Community;
use Concrete\Core\Authentication\Type\OAuth\OAuth2\GenericOauth2TypeController;

class Controller extends GenericOauth2TypeController
{

    public function supportsRegistration()
    {
        return \Config::get('auth.community.registration_enabled', false);
    }

    public function getAuthenticationTypeIconHTML()
    {
        return '<div class="ccm-concrete-authentication-type-svg" data-src="/concrete/images/authentication/concrete/concrete.svg">' .
                    file_get_contents(DIR_BASE_CORE . '/images/authentication/concrete/concrete.svg') .
               '</div>';
    }

    public function getHandle()
    {
        return 'community';
    }

    /**
     * @return Community
     */
    public function getService()
    {
        if (!$this->service) {
            $this->service = \Core::make('community_service');
        }
        return $this->service;
    }

    public function saveAuthenticationType($args)
    {
        \Config::save('auth.community.appid', $args['apikey']);
        \Config::save('auth.community.secret', $args['apisecret']);
        \Config::save('auth.community.registration_enabled', $args['registration_enabled']);
    }

    public function edit()
    {
        $this->set('form', \Loader::helper('form'));
        $this->set('apikey', \Config::get('auth.community.appid', ''));
        $this->set('apisecret', \Config::get('auth.community.secret', ''));
    }

    /**
     * @return Array
     */
    public function getAdditionalRequestParameters() {
        return array('state' => time());
    }

    public function getExtractor() {
        try {
            return parent::getExtractor();
        } catch (\Exception $e) {
            dd($e);
        }
    }

}
<commit_msg>Resize and center c5 hand in auth type interface<commit_after><?php
namespace Concrete\Authentication\Community;

use Concrete\Core\Authentication\Type\Community\Service\Community;
use Concrete\Core\Authentication\Type\OAuth\OAuth2\GenericOauth2TypeController;

class Controller extends GenericOauth2TypeController
{

    public function supportsRegistration()
    {
        return \Config::get('auth.community.registration_enabled', false);
    }

    public function getAuthenticationTypeIconHTML()
    {
        return '<div class="ccm-concrete-authentication-type-svg" style="width:20px;display:inline-block" data-src="/concrete/images/authentication/concrete/concrete.svg">' .
                    file_get_contents(DIR_BASE_CORE . '/images/authentication/concrete/concrete.svg') .
               '</div>';
    }

    public function getHandle()
    {
        return 'community';
    }

    /**
     * @return Community
     */
    public function getService()
    {
        if (!$this->service) {
            $this->service = \Core::make('community_service');
        }
        return $this->service;
    }

    public function saveAuthenticationType($args)
    {
        \Config::save('auth.community.appid', $args['apikey']);
        \Config::save('auth.community.secret', $args['apisecret']);
        \Config::save('auth.community.registration_enabled', $args['registration_enabled']);
    }

    public function edit()
    {
        $this->set('form', \Loader::helper('form'));
        $this->set('apikey', \Config::get('auth.community.appid', ''));
        $this->set('apisecret', \Config::get('auth.community.secret', ''));
    }

    /**
     * @return Array
     */
    public function getAdditionalRequestParameters() {
        return array('state' => time());
    }

    public function getExtractor() {
        try {
            return parent::getExtractor();
        } catch (\Exception $e) {
            dd($e);
        }
    }

}

{'fraction_non_alphanumeric': 0.14831284331676695, 'fraction_numerical': 0.0023541721161391576, 'mean_word_length': 2.7307317073170734, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 21, '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': '7655145', 'n_tokens_mistral': 1102, 'n_tokens_neox': 1057, 'n_words': 167}