<commit_before><!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!--<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link rel='stylesheet' type='text/css' href='./css/tilss.css'>
    <title>Tills - Collarate on lists!</title>
  </head>
  <body>
    <div class="container">
      <h1>
           Welcome to Tills!
      </h1>
      <div class="lead">
          Tills is a simple app for writing up lists. Lists can also be collarated on and changes to lists by other users
          will show up immediatelly. You can for example share a shopping list with your friend. One can for example add items
          on a desktop and the other on mobile.
      </div>
    <div id="loginDiv">
        <!-- <a href="#" onclick="onLoginButtonClicked()" id="login">Login</a> -->
        <a href="#" data-bind="click: $data.displayLogin" id="login">Login</a>
    </div>
    <div id="listsDiv" data-bind='visible: $data.loggedUser'>
        <h1>My lists</h1>
        <div class="list" data-bind='foreach: lists'>
            <div class="listheader">
                <h4>
                    "<span data-bind='text: listname'></span>"
                    <button type="button" data-bind="click: $data.deleteList">x</button>
                </h4>
            </div>
            <div class="items_list">
                <ul data-bind='foreach: items' class="list-group">
                    <li data-bind="attr: {id: 'item'+ itemid()}" class="list-group-item">
                        <span data-bind="text: item, click: $data.toggleEditor, attr: {id: 'item_text'+ itemid()}"></span>
                        <div class="item_edit" hidden="hidden" data-bind="attr: {id: 'item_edit'+ itemid()}">
                            <input data-bind='value: $data.newitem' class="form-control"></input>
                            <button type="button" data-bind="click: $data.updateItem">OK</button>
                            <button type="button" data-bind="click: $data.toggleEditor">cancel</button>
                        </div>
                        <button data-bind="click: $data.deleteItem, attr: {id: 'item_delete'+ itemid()}" class="btn btn-danger btn-sm">
                            <span class="glyphicon glyphicon-trash"/></button>
                    </li>
                </ul>
            </div>
            <div class="item_add">
                <input data-bind="attr: {id: 'newitem'+ listid()}" type='text' placeholder="Add new item..."/>
                <button type="button" data-bind="click: $data.addNewItem">add</button>
                <br /><br />
            </div>
        </div>

        <h2> Create a new list </h2>
        <input type='text' id='listname' placeholder='List name'/>
        <button type="button" data-bind="click: $data.addNewList">add</button>

    </div>
    </div>
    <!-- KnockoutJS debug console
    <pre>Knockout debug: </pre>
    <pre data-bind="text: ko.toJSON($data, null, 2)"></pre> -->

    <script type='text/javascript' src='https://cdn.firebase.com/v0/firebase.js'></script>
    <script type='text/javascript' src='https://cdn.firebase.com/js/simple-login/1.2.5/firebase-simple-login.js'></script>
    <script type='text/javascript' src='https://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js'></script>
    <script type='text/javascript' src='https://ajax.aspnetcdn.com/ajax/knockout/knockout-3.0.0.js'></script>
    <!-- <script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script> -->
    <script src="js/bootstrap.min.js"></script>
    <script src="./js/tilss.js" type="text/javascript" >
    </script>
    <script type='text/javascript'>
        $(document).ready(function(){
          // Activate knockout.js
          //ko.applyBindings(new AppViewModel(fbRef));
        });
    </script>

  </body>
</html>
<commit_msg>Fixed fb login. Also now correctly hides page if not logged in.<commit_after><!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!--<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link rel='stylesheet' type='text/css' href='./css/tilss.css'>
    <title>Tills - Collarate on lists!</title>
  </head>
  <body>
    <div class="container">
      <h1>
           Welcome to Tills!
      </h1>
      <div class="lead">
          Tills is a simple app for writing down lists. Lists can also be collarated on and changes to lists by other users
          will show up immediatelly. You can for example share a shopping list with your friend. One can for example add items
          on a desktop and the other on mobile.
      </div>
    <div id="loginDiv">
        <a href="#" onclick='auth.login("facebook")' id="login">Login</a>
        <!--<a href="#" data-bind="click: $data.displayLogin" id="login">Login</a>        -->
    </div>
    <div id="listsDiv" data-bind='visible: $data.loggedUser' style='display:none;'>
        <h1>My lists</h1>
        <div class="list" data-bind='foreach: lists'>
            <div class="listheader">
                <h4>
                    "<span data-bind='text: listname'></span>"
                    <button type="button" data-bind="click: $data.deleteList">x</button>
                </h4>
            </div>
            <div class="items_list">
                <ul data-bind='foreach: items' class="list-group">
                    <li data-bind="attr: {id: 'item'+ itemid()}" class="list-group-item">
                        <span data-bind="text: item, click: $data.toggleEditor, attr: {id: 'item_text'+ itemid()}"></span>
                        <div class="item_edit" hidden="hidden" data-bind="attr: {id: 'item_edit'+ itemid()}">
                            <input data-bind='value: $data.newitem' class="form-control"></input>
                            <button type="button" data-bind="click: $data.updateItem">OK</button>
                            <button type="button" data-bind="click: $data.toggleEditor">cancel</button>
                        </div>
                        <button data-bind="click: $data.deleteItem, attr: {id: 'item_delete'+ itemid()}" class="btn btn-danger btn-sm">
                            <span class="glyphicon glyphicon-trash"/></button>
                    </li>
                </ul>
            </div>
            <div class="item_add">
                <input data-bind="attr: {id: 'newitem'+ listid()}" type='text' placeholder="Add new item..."/>
                <button type="button" data-bind="click: $data.addNewItem">add</button>
                <br /><br />
            </div>
        </div>

        <h2> Create a new list </h2>
        <input type='text' id='listname' placeholder='List name'/>
        <button type="button" data-bind="click: $data.addNewList">add</button>

    </div>
    </div>
    <!-- KnockoutJS debug console
    <pre>Knockout debug: </pre>
    <pre data-bind="text: ko.toJSON($data, null, 2)"></pre> -->

    <script type='text/javascript' src='https://cdn.firebase.com/v0/firebase.js'></script>
    <script type='text/javascript' src='https://cdn.firebase.com/js/simple-login/1.2.5/firebase-simple-login.js'></script>
    <script type='text/javascript' src='https://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js'></script>
    <script type='text/javascript' src='https://ajax.aspnetcdn.com/ajax/knockout/knockout-3.0.0.js'></script>
    <!-- <script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script> -->
    <script src="js/bootstrap.min.js"></script>
    <script src="./js/tilss.js" type="text/javascript" >
    </script>
    <script type='text/javascript'>
        $(document).ready(function(){
          // Activate knockout.js
          //ko.applyBindings(new AppViewModel(fbRef));
        });
    </script>

  </body>
</html>

{'fraction_non_alphanumeric': 0.18033584813823314, 'fraction_numerical': 0.006570941834996349, 'mean_word_length': 2.3087761674718195, 'pattern_counts': {'":': 0, '<': 195, '<?xml version=': 0, '>': 195, 'https://': 8, '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': '7073065', 'n_tokens_mistral': 2599, 'n_tokens_neox': 2519, 'n_words': 530}