<commit_before>import m from 'mithril';
import _ from 'underscore';
import h from '../h';
import projectCard from './project-card';

const projectRowWithHeader = {
    view: function ({ attrs }) {
        const collection = attrs.collection,
            title = attrs.title || collection.title,
            ref = attrs.ref,
            showFriends = attrs.showFriends,
            wrapper = attrs.wrapper || `.section.u-marginbottom-40${attrs.isOdd ? '.bg-gray' : ''}`,
            showFriendsLinkComponent = (
                showFriends ?
                    m(`a.btn.btn-small.btn-terciary.btn-inline.u-right-big-only.btn-no-border[href="/connect-facebook?ref=${ref}"]`,
                        'Encontrar amigos') : ''
            ),
            collectionHeaderComponent = (
                (!_.isUndefined(collection.title) || !_.isUndefined(collection.hash)) ?
                    m('.u-marginbottom-30.u-text-center-small-only', [
                        m('div', _.map(collection.badges, badge => m(`img[src="/assets/catarse_bootstrap/${badge}.png"][width='105']`))),
                        m('.w-row', [
                            m('.w-col.w-col-8', m('.fontsize-larger', `${title}`)),
                            m('.w-col.w-col-4', [
                                m(`a.btn.btn-small.btn-terciary.btn-inline.u-right-big-only[href="/explore?ref=${ref}&${m.buildQueryString(collection.query)}"]`,
                                    {
                                        oncreate: m.route.link
                                    },
                                    'Ver todos'
                                ),
                                showFriendsLinkComponent
                            ])
                        ])
                    ]) : ''
            ),
            projectsOrLoadingIconComponent = (
                collection.loader() ?
                    h.loader() :
                    m('.w-row',
                        _.map(collection.collection(), project => m(projectCard, {
                            project,
                            ref,
                            showFriends<commit_msg>:beetle: design fix (margin bottom in mobile)<commit_after>import m from 'mithril';
import _ from 'underscore';
import h from '../h';
import projectCard from './project-card';

const projectRowWithHeader = {
    view: function ({ attrs }) {
        const collection = attrs.collection,
            title = attrs.title || collection.title,
            ref = attrs.ref,
            showFriends = attrs.showFriends,
            wrapper = attrs.wrapper || `.section.u-marginbottom-40${attrs.isOdd ? '.bg-gray' : ''}`,
            showFriendsLinkComponent = (
                showFriends ?
                    m(`a.btn.btn-small.btn-terciary.btn-inline.u-right-big-only.btn-no-border[href="/connect-facebook?ref=${ref}"]`,
                        'Encontrar amigos') : ''
            ),
            collectionHeaderComponent = (
                (!_.isUndefined(collection.title) || !_.isUndefined(collection.hash)) ?
                    m('.u-marginbottom-20.u-text-center-small-only', [
                        m('div', _.map(collection.badges, badge => m(`img[src="/assets/catarse_bootstrap/${badge}.png"][width='105']`))),
                        m('.w-row', [
                            m('.w-col.w-col-8', m('.fontsize-larger.u-marginbottom-20', `${title}`)),
                            m('.w-col.w-col-4', [
                                m(`a.btn.btn-small.btn-terciary.btn-inline.u-right-big-only[href="/explore?ref=${ref}&${m.buildQueryString(collection.query)}"]`,
                                    {
                                        oncreate: m.route.link
                                    },
                                    'Ver todos'
                                ),
                                showFriendsLinkComponent
                            ])
                        ])
                    ]) : ''
            ),
            projectsOrLoadingIconComponent = (
                collection.loader() ?
                    h.loader() :
                    m('.w-row',
                        _.map(collection.collection(), project => m(projectCard, {
                            project,
                            ref,
                            showFriends
{'fraction_non_alphanumeric': 0.13795485951174574, 'fraction_numerical': 0.004606172270842929, 'mean_word_length': 1.1564051638530288, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2478870', 'n_tokens_mistral': 1122, 'n_tokens_neox': 1085, 'n_words': 141}