<commit_before>import React from 'react';
import { useModals, NavMenu } from 'react-components';
import { c } from 'ttag';
import EventModal from '../modals/EventModal';
import MiniCalendar from '../MiniCalendar';

const AuthSidebar = () => {
    const { createModal } = useModals();
    const handleSelect = () => {};

    const list = [
        {
            icon: 'plus',
            text: c('Action').t`Add event`,
            type: 'button',
            onClick() {
                createModal(<EventModal />);
            }
        },
        {
            icon: 'calendar',
            text: 'My calendar',
            link: '/calendar'
        }
    ];

    return (
        <div className="sidebar flex noprint">
            <MiniCalendar onSelect={handleSelect} />
            <nav className="navigation flex-item-fluid scroll-if-needed mb1">
                <NavMenu list={list} />
            </nav>
        </div>
    );
};

export default AuthSidebar;<commit_msg>Add prop for mini calendar<commit_after>import React from 'react';
import { useModals, NavMenu } from 'react-components';
import { c } from 'ttag';
import moment from 'moment';

import EventModal from '../modals/EventModal';
import MiniCalendar from '../MiniCalendar';

const AuthSidebar = () => {
    const { createModal } = useModals();
    const handleSelect = () => {};

    const list = [
        {
            icon: 'plus',
            text: c('Action').t`Add event`,
            type: 'button',
            onClick() {
                createModal(<EventModal />);
            }
        },
        {
            icon: 'calendar',
            text: 'My calendar',
            link: '/calendar'
        }
    ];

    return (
        <div className="sidebar flex noprint">
            <MiniCalendar
                defaultDate={new Date()}
                setDefaultDate
                onSelect={handleSelect}
                format={moment.localeData().longDateFormat('L')}
            />
            <nav className="navigation flex-item-fluid scroll-if-needed mb1">
                <NavMenu list={list} />
            </nav>
        </div>
    );
};

export default AuthSidebar;
{'fraction_non_alphanumeric': 0.13552266419981499, 'fraction_numerical': 0.0009250693802035153, 'mean_word_length': 1.7105263157894737, 'pattern_counts': {'":': 0, '<': 17, '<?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': '979995', 'n_tokens_mistral': 590, 'n_tokens_neox': 573, 'n_words': 141}