<commit_before><%namespace name='static' file='/static_content.html'/>
<html>
	<head>
    ## It'd be better to have this in a place like lms/css/vendor/candy,
    ## but the candy_res/ folder contains images and other junk, and it
    ## all needs to stay together for the Candy.js plugin to work.
    <link rel="stylesheet" href="${static.url('candy_res/default.css')}" />
    <link rel="stylesheet" href="${static.url('candy_res/candy_custom.css')}" />

    ## Load in jQuery from standard edX location.
    <script type="text/javascript" src="${static.url('js/vendor/jquery.min.js')}"></script>

    ## Include the Candy.js libraries. Wooooo.
    <script type="text/javascript" src="${static.url('js/vendor/candy_libs/libs.min.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/candy.min.js')}"></script>
	</head>
	<body>
    ## Candy.js renders itself in an element with #candy
		<div id="candy"></div>

    ## Initialize the Candy.js plugin
    <script type="text/javascript">
      $(document).ready(function() {
        Candy.init("${bosh_url}", {
          core: { debug: true, autojoin: ["${course_room}"] },
          //core: { debug: true, autojoin: ["<EMAIL>"] },
          view: { resources: "${static.url('candy_res/')}"}
        });
	
	$('#chat-toolbar #chat-sound-control').remove();

        Candy.Core.connect("${username}", "${password}");
	
	$("#candy").focus();
      });
    </script>
	</body>
</html><commit_msg>Modify chat login form to not prompt for uname/pwd<commit_after><%namespace name='static' file='/static_content.html'/>
<html>
	<head>
    ## It'd be better to have this in a place like lms/css/vendor/candy,
    ## but the candy_res/ folder contains images and other junk, and it
    ## all needs to stay together for the Candy.js plugin to work.
    <link rel="stylesheet" href="${static.url('candy_res/default.css')}" />
    <link rel="stylesheet" href="${static.url('candy_res/candy_custom.css')}" />

    ## Load in jQuery from standard edX location.
    <script type="text/javascript" src="${static.url('js/vendor/jquery.min.js')}"></script>

    ## Include the Candy.js libraries. Wooooo.
    <script type="text/javascript" src="${static.url('js/vendor/candy_libs/libs.min.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/candy.min.js')}"></script>
	</head>
	<body>
    ## Candy.js renders itself in an element with #candy
		<div id="candy"></div>

    ## Initialize the Candy.js plugin
    <script type="text/javascript">
      $(document).ready(function() {
        Candy.init("${bosh_url}", {
          core: { debug: true, autojoin: ["${course_room}"] },
          //core: { debug: true, autojoin: ["<EMAIL>"] },
          view: { resources: "${static.url('candy_res/')}"}
        });
	
	$('#chat-toolbar #chat-sound-control').remove();

        /* After a period of inactivity, users will be disconnected
         * from the chat server and prompted to log in again. They
         * won't know their username/password, however, since we take
         * care of that for them.
         *
         * Therefore, we override this function so that the user
         * never sees a true login form. We just give them a button
         * to click when they're ready to (re)connect.
         */
        Candy.View.Pane.Chat.Modal.showLoginForm = function(message, presetJid) {
          var loginMsg = "Click below to connect to the chat server" +
                         "<p>&nbsp</p>" +
                         "<button id='connect'>Connect</button>";
          Candy.View.Pane.Chat.Modal.show(loginMsg);
          $("#connect").click(function() {
            Candy.Core.connect("${username}", "${password}");
          });
        }

        Candy.Core.connect("${username}", "${password}");
	
	$("#candy").focus();
      });
    </script>
	</body>
</html>
{'fraction_non_alphanumeric': 0.1781921781921782, 'fraction_numerical': 0.0, 'mean_word_length': 2.9448416751787536, 'pattern_counts': {'":': 0, '<': 47, '<?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': '4880006', 'n_tokens_mistral': 1206, 'n_tokens_neox': 1177, 'n_words': 300}