<commit_before><?php

function BBCodeParser($text = null)
{
    $parser = new \SBBCodeParser\Node_Container_Document();

    if ($text == null)
        return $parser;

    return $parser->parse($text)
        ->detect_links()
        ->detect_emails()
        ->detect_emoticons()
        ->get_html();
}<commit_msg>Update helper untuk menampilkan emoticon<commit_after><?php

function BBCodeParser($text = null)
{
    $parser = new \SBBCodeParser\Node_Container_Document();

    if ($text == null){
        return $parser;
    }

    $parser->add_emoticons(array(
		':)'=> asset('plugins/sceditor/emoticons/smile.png'),
		':angel:'=> asset('plugins/sceditor/emoticons/angel.png'),
		':angry:'=> asset('plugins/sceditor/emoticons/angry.png'),
		'8-)'=> asset('plugins/sceditor/emoticons/cool.png'),
		':&#039;('=> asset('plugins/sceditor/emoticons/cwy.png'),
		':ermm:'=> asset('plugins/sceditor/emoticons/ermm.png'),
		':D'=> asset('plugins/sceditor/emoticons/grin.png'),
		'<3'=> asset('/emoticons/heart.png'),
		':('=> asset('/emoticons/sad.png'),
		':O'=> asset('/emoticons/shocked.png'),
		':P'=> asset('/emoticons/tongue.png'),
		';)'=> asset('/emoticons/wink.png'),
		':alien:'=> asset('/emoticons/alien.png'),
		':blink:'=> asset('/emoticons/blink.png'),
		':blush:'=> asset('/emoticons/blush.png'),
		':cheerful:'=> asset('/emoticons/cheerful.png'),
		':devil:'=> asset('/emoticons/devil.png'),
		':dizzy:'=> asset('/emoticons/dizzy.png'),
		':getlost:'=> asset('/emoticons/getlost.png'),
		':happy:'=> asset('/emoticons/happy.png'),
		':kissing:'=> asset('/emoticons/kissing.png'),
		':ninja:'=> asset('/emoticons/ninja.png'),
		':pinch:'=> asset('/emoticons/pinch.png'),
		':pouty:'=> asset('/emoticons/pouty.png'),
		':sick:'=> asset('/emoticons/sick.png'),
		':sideways:'=> asset('/emoticons/sideways.png'),
		':silly:'=> asset('/emoticons/silly.png'),
		':sleeping:'=> asset('/emoticons/sleeping.png'),
		':unsure:'=> asset('/emoticons/unsure.png'),
		':woot:'=> asset('/emoticons/w00t.png'),
		':wassat:'=> asset('/emoticons/wassat.png'),
		':whistling:'=> asset('/emoticons/whistling.png'),
		':love:'=> asset('/emoticons/wub.png')
	));

    return $parser->parse($text)
        ->detect_links()
        ->detect_emails()
        ->detect_emoticons()
        ->get_html();
}
{'fraction_non_alphanumeric': 0.2501091226538629, 'fraction_numerical': 0.0030554343081623746, 'mean_word_length': 4.380281690140845, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 47, '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': '2488297', 'n_tokens_mistral': 894, 'n_tokens_neox': 853, 'n_words': 104}