<commit_before>
//- If we have flashes to display, we'll read them all and add a class to the navbar.
- for(var fc,flashes=[],f;f=(flash||[]).pop();)fc='flash '+f.type,flashes.push(f);

#navbar(class=fc)
    .icon.tick
    .icon.warn
    .icon.info
    .icon.note
    a.logo(href='/' title='Noumena Home')
    //- We need a bit of complexity here because we'll add diferent markup/classes
    //- depending on whether we have flash messages to display.
    if flashes.length
        h1(style='opacity:0')= title
        each item in flashes
            //- We'll build attributes manually, so as to skip "style" on last h1.
            - var attr = item === flashes[flashes.length - 1] ? {} : {style: 'opacity:0'};
            - attr['data-flash-type'] = item.type;
            h1&attributes(attr)= item.message
    else
        h1= title
    if loggedIn
        - var t = 'Logged in as "' + currentUser.name + '". Follow this link to log out.';
        a#account(href='/login' title=t)
            p logged in as
            b= currentUser.name
    else
        a#account(href='/login' title='Not logged in. Follow this link to log in.')
            p click here to
            b log in<commit_msg>Add tooltip to flash messages in navbar.<commit_after>
//- If we have flashes to display, we'll read them all and add a class to the navbar.
- for(var fc,flashes=[],f;f=(flash||[]).pop();)fc='flash '+f.type,flashes.push(f);

#navbar(class=fc)
    .icon.tick
    .icon.warn
    .icon.info
    .icon.note
    a.logo(href='/' title='Noumena Home')
    //- We need a bit of complexity here because we'll add diferent markup/classes
    //- depending on whether we have flash messages to display.
    if flashes.length
        h1(style='opacity:0')= title
        each item in flashes
            //- We'll attach style attribute manually, so as to skip it on last h1.
            - var attr = item === flashes[flashes.length - 1] ? {} : {style: 'opacity:0'};
            h1(title=item.message data-flash-type=item.type)&attributes(attr)= item.message
    else
        h1= title
    if loggedIn
        - var t = 'Logged in as "' + currentUser.name + '". Follow this link to log out.';
        a#account(href='/login' title=t)
            p logged in as
            b= currentUser.name
    else
        a#account(href='/login' title='Not logged in. Follow this link to log in.')
            p click here to
            b log in
{'fraction_non_alphanumeric': 0.12928541924824452, 'fraction_numerical': 0.0057827344072697235, 'mean_word_length': 2.212201591511936, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '2050206', 'n_tokens_mistral': 765, 'n_tokens_neox': 742, 'n_words': 253}