<commit_before><!DOCTYPE html>
<html>
  <head>
    <title>Frame UI Example</title>

    <!-- Instantiate SMART, to access the container's SMART Connect Host -->
    <script  src='http://sandbox-dev.smartplatforms.org:8001/framework/smart/scripts/smart-api-client.js'>
    </script>

    <!-- Instantiate SMART_HOST, to provide a SMART Connect Host to framed apps-->
    <script  src='http://sandbox-dev.smartplatforms.org/static/smart_common/resources/smart-api-container.js'>
    </script>
    
    <!-- Glue to link the above libraries -->
    <script  src='http://sandbox-dev.smartplatforms.org:8001/framework/smart/scripts/smart-frame-ui.js'>
    </script>

    <script>
     $ = jQuery = SMART.jQuery;

     SMART.ready(function() {
         

       $("#record_name").text(SMART.record.full_name);

       var iframes = [$("#app1"), $("#app2"), $("#app3")];
       SMART.MANIFESTS_get(function(response) {

         var carousel = jQuery("#carousel"),
             manifests = response.json;
             
           carousel.html("");
           var click_count = -1;

           // Highlight the next iframe in sequence to be populated by an app
           var pending_click = function() {
               jQuery("iframe").css("border", "1px solid black");
               var next_frame = iframes[++click_count % iframes.length];
               next_frame.css("border", "7px dashed yellow");
           }

           pending_click();

           // Populate a carousel element for each available app.
           jQuery.each(manifests, function(i,m) {
             var app = jQuery("<img src='"+m.icon+"' title='"+m.name+ ": " + m.description + "'>");
             carousel.append(app);
             app.click(function(){
               var next_frame = iframes[click_count % iframes.length];
               SMART_HOST.launch_app(m, SMART.context, {elt: next_frame});
               pending_click();
             });
           });
       });
     });

     SMART_HOST.get_iframe = function (app_instance, callback){
       callback(app_instance.options.elt[0]);
     };

    </script>
  </head>
  <body>
    <b>Choose some apps from the carousel below!</b><br>
    <div id="record_name">loading patient...</div>
    <span id="carousel">carousel here...</span><br><br>

      <iframe SEAMLESS src="about:blank" id="app1" width="290px" height="280px" style="float:left"> </iframe>
      <iframe SEAMLESS src="about:blank" id="app2" width="600px" height="280px" style="float:left"> </iframe>
      <iframe SEAMLESS src="about:blank" id="app3" width="100%" height="500px"> </iframe>
  </body>
</html>
<commit_msg>Update the refernces to the dev sandbox to point at the production box (EMR frame sample app)<commit_after><!DOCTYPE html>
<html>
  <head>
    <title>Frame UI Example</title>

    <!-- Instantiate SMART, to access the container's SMART Connect Host -->
    <script  src='http://sample-apps.smartplatforms.org/framework/smart/scripts/smart-api-client.js'>
    </script>

    <!-- Instantiate SMART_HOST, to provide a SMART Connect Host to framed apps-->
    <script  src='http://sandbox.smartplatforms.org/static/smart_common/resources/smart-api-container.js'>
    </script>
    
    <!-- Glue to link the above libraries -->
    <script  src='http://sample-apps.smartplatforms.org/framework/smart/scripts/smart-frame-ui.js'>
    </script>

    <script>
     $ = jQuery = SMART.jQuery;

     SMART.ready(function() {
         

       $("#record_name").text(SMART.record.full_name);

       var iframes = [$("#app1"), $("#app2"), $("#app3")];
       SMART.MANIFESTS_get(function(response) {

         var carousel = jQuery("#carousel"),
             manifests = response.json;
             
           carousel.html("");
           var click_count = -1;

           // Highlight the next iframe in sequence to be populated by an app
           var pending_click = function() {
               jQuery("iframe").css("border", "1px solid black");
               var next_frame = iframes[++click_count % iframes.length];
               next_frame.css("border", "7px dashed yellow");
           }

           pending_click();

           // Populate a carousel element for each available app.
           jQuery.each(manifests, function(i,m) {
             var app = jQuery("<img src='"+m.icon+"' title='"+m.name+ ": " + m.description + "'>");
             carousel.append(app);
             app.click(function(){
               var next_frame = iframes[click_count % iframes.length];
               SMART_HOST.launch_app(m, SMART.context, {elt: next_frame});
               pending_click();
             });
           });
       });
     });

     SMART_HOST.get_iframe = function (app_instance, callback){
       callback(app_instance.options.elt[0]);
     };

    </script>
  </head>
  <body>
    <b>Choose some apps from the carousel below!</b><br>
    <div id="record_name">loading patient...</div>
    <span id="carousel">carousel here...</span><br><br>

      <iframe SEAMLESS src="about:blank" id="app1" width="290px" height="280px" style="float:left"> </iframe>
      <iframe SEAMLESS src="about:blank" id="app2" width="600px" height="280px" style="float:left"> </iframe>
      <iframe SEAMLESS src="about:blank" id="app3" width="100%" height="500px"> </iframe>
  </body>
</html>

{'fraction_non_alphanumeric': 0.1591166477916195, 'fraction_numerical': 0.0120800302000755, 'mean_word_length': 2.4953825857519787, 'pattern_counts': {'":': 2, '<': 75, '<?xml version=': 0, '>': 75, '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': '3621706', 'n_tokens_mistral': 1685, 'n_tokens_neox': 1587, 'n_words': 342}