<commit_before><link href="/app/css/find.css" rel="stylesheet">
<link href="/app/css/record.css" rel="stylesheet">
<style>

#search_controls.affix-bottom {
    /*position: absolute;*/
}

.not-active{
    color:rgb(119, 119, 119)!important;
}
.active{
    color:#2a6496!important;
}


</style>

<div ng-controller="FindController" ng-intro-options="introOptions" ng-intro-method="startIntro" ng-intro-autostart="startTour">


    <section layout="row" style="position:relative; top:20px; padding-bottom:30px;" flex>


           <md-sidenav class="md-sidenav-left md-whiteframe-z1" md-component-id="left" md-is-locked-open="$mdMedia('min-width: 1200px')"
           style="height:1150px;" >


             <md-toolbar class="bg-medgrey" >
               <h1 class="md-toolbar-tools">

                   Search &nbsp;&nbsp;&nbsp;

                   <!-- <span class="pull-right">
                       <a ng-href="#" ng-click="previewType='list'" class="not-active"
                         data-toggle="tooltip" title="View result set in list view ordered by creation date"
                         ng-class="{'active':previewType=='list'}"><i class="fa fa-list"/>
                       </a>
                       <a ng-href="#" ng-click="previewType='group'" class="not-active "
                           data-toggle="tooltip" title="View result set grouped by country"
                           ng-class="{'active':previewType=='group'}">
                           <i class="fa fa-th-large"/>
                       </a>
                   </span> -->




               </h1>
             </md-toolbar>

             <md-content layout-padding layout-margin>

                 <h3 style="padding-top:0;margin-top:0;"> Display </h3>
                 <div class="btn-group" role="group">
                   <button type="button" class="btn btn-default"  ng-class="{'bg-medgrey':previewType=='list' }"   ng-click="previewType='list'"><i class="fa fa-list"/> List records </button>
                   <button type="button" class="btn btn-default"  ng-class="{'bg-medgrey': previewType=='group' }" ng-click="previewType='group'" ><i class="fa fa-th-large"/> Group by country</button>
                 </div>
                <br><br>

                <h3> Search Filters    <button class="btn btn-default pull-right" ng-click="clearFilter()" class=" ">Clear filters</button></h3>
                <br>



                         <input type="text" ng-model="keyword" placeholder=" Keyword " class="form-control keyword" style="margin-bottom:10px;">



                         <div style="padding: 10px 0;">
                              <h4 ng-click="showNPStatus=!showNPStatus"><i class="fa" ng-class="{'fa-caret-right':showNPStatus, 'fa-caret-down':!showNPStatus}"></i> &nbsp; Nagoya Protocol Party Status</h4>
                              <div ng-show="!showNPStatus">
                              <a ng-click="queryStatus('party')" class="color-grey" ng-href="#">
                                  <span class="label label-primary" >&nbsp;</span> Party
                              </a>
                              <br>
                              <a ng-click="queryStatus('nonParty')" class="color-grey" ng-href="#">
                                  <span class="label label-default">&nbsp;</span> Non-Party
                              </a>
                          </div>
                          </div>



                         <div id="filterCheckboxes">
                             <search-filter-schemas  ng-model='schemas' field='schema_s' query='querySchema' preview-type="previewType" selected-filters="selectedSchemaFilters"></search-filter-schemas>

                             <a href="" ng-click="loadThemes=true;" data-toggle="modal" data-target="#themeModal" class="color-black"><h4>Thematic Areas</h4></a>
                             <a href="" data-toggle="modal" data-target="#countryModal" class="color-black"><h4>Countries</h4></a>
                             <a href="" ng-click="loadRegions=true;"data-toggle="modal" data-target="#regionModal" class="color-black"><h4>Regions</h4></a>


                         </div>
                          <!-- <div class="form-group">
                           <label for="sortby">Sort By</label>
                           <select ng-options="obj.value as obj.label for obj in sortOptions" ng-model="sortBy" class="form-control" ng-change="sortResults()" id="sortby"></select>
                         </div> -->




             </md-content>

         </md-sidenav>


         <md-content flex layout-margin style="margin:0 30px 30px 30px;padding:0;background-color:transparent;"  >
             <div layout="column" layout-align="top center"  >

                 <md-button ng-click="toggleLeft()" class="md-primary md-raised bg-medgrey" hide-gt-lg  style="margin: 0  0 10px 0;">
                     <i class="material-icons" style="position:relative;top:6px;">menu</i> Search Filters
                 </md-button>

                 <search-filter-themes api="thematicAreaApi" title='Thematic Areas' ng-model='thematicAreas' field='thematicAreas_ss' query='queryTheme'></search-filter-themes>
                 <search-filter-countries api="countryApi" title='Countries' ng-model='governments' field='government_s' query='queryGovernment' external-filter="countryResultFilter"></search-filter-countries>
                 <search-filter-regions api="regionsApi" title="Regions" ng-model="regions" field="government_REL_ss" query="queryRegion" facets="regionFacets"></search-filter-regions>


                 <div style="max-width:100%">

                     <button class="btn btn-primary" type="button" ng-show="partyStatusString"
                      ng-click="queryStatus()"
                             style="margin-right:2px;margin-bottom:2px">
                             {{partyStatusString}}
                          <span class="badge" >{{partyStatusString=="Non parties" ? nonPartiesCount : partiesCount}}</span>
                          &nbsp;<span aria-hidden="true">&times;</span>
                     </button>
                     &nbsp;
                     <button class="btn btn-primary" type="button" ng-repeat="filter in selectedSchemaFilters" ng-click="removeFilter(filter)"
                             style="margin-right:2px;margin-bottom:2px">
                         {{filter.isTerm ? (filter.value|term) : filter.value}}
                          <span class="badge" >{{filter.count}}</span>
                          &nbsp;<span aria-hidden="true">&times;</span>
                     </button>
                    <button class="btn btn-primary" type="button"
                     ng-repeat="filter in countryApi.getSelected()"
                     ng-click="removeCountryFilter(filter)"
                            style="margin-right:2px;margin-bottom:2px">
                        {{filter.name|lstring}}
                         <span class="badge" >{{filter.count}}</span>
                         &nbsp;<span aria-hidden="true">&times;</span>
                    </button>
                    <button class="btn btn-primary" type="button"
                     ng-repeat="filter in thematicAreaApi.getSelected()"
                     ng-click="removeThematicAreaFilter(filter)"
                            style="margin-right:2px;margin-bottom:2px">
                        {{filter.title|lstring}}
                         <span class="badge" >{{filter.count}}</span>
                         &nbsp;<span aria-hidden="true">&times;</span>
                    </button>
                    <button class="btn btn-primary" type="button"
                     ng-repeat="filter in regionsApi.getSelected()"
                     ng-click="removeRegionFilter(filter)"
                            style="margin-right:2px;margin-bottom:2px">
                        {{filter.title|lstring}}
                         <span class="badge" >{{filter.count}}</span>
                         &nbsp;<span aria-hidden="true">&times;</span>
                    </button>
                </div>

                <div preview-type="previewType" document-list documents='rawDocs' filter='*' show-pagination='true' current-page='currentPage' document-Count='documentCount' order-by="orderBy"><commit_msg>moved list/group display outside of sidenav<commit_after><link href="/app/css/find.css" rel="stylesheet">
<link href="/app/css/record.css" rel="stylesheet">
<style>

#search_controls.affix-bottom {
    /*position: absolute;*/
}

.not-active{
    color:rgb(119, 119, 119)!important;
}
.active{
    color:#2a6496!important;
}


</style>

<div ng-controller="FindController" ng-intro-options="introOptions" ng-intro-method="startIntro" ng-intro-autostart="startTour">


    <section layout="row" style="position:relative; top:20px; padding-bottom:30px;" flex>


           <md-sidenav class="md-sidenav-left md-whiteframe-z1" md-component-id="left" md-is-locked-open="$mdMedia('min-width: 1200px')"
           style="height:1150px;" >


             <md-toolbar class="bg-medgrey" >
               <h1 class="md-toolbar-tools">

                   Search Filters

                   <button style="position:relative;left:70px;" class="btn btn-xs btn-default" ng-click="clearFilter()" class=" ">Clear filters</button>

               </h1>
             </md-toolbar>

             <md-content layout-padding layout-margin>


                         <input type="text" ng-model="keyword" placeholder=" Keyword " class="form-control keyword" style="margin-bottom:10px;">



                         <div style="padding: 10px 0;">
                              <h4 ng-click="showNPStatus=!showNPStatus"><i class="fa" ng-class="{'fa-caret-right':showNPStatus, 'fa-caret-down':!showNPStatus}"></i> &nbsp; Nagoya Protocol Party Status</h4>
                              <div ng-show="!showNPStatus">
                              <a ng-click="queryStatus('party')" class="color-grey" ng-href="#">
                                  <span class="label label-primary" >&nbsp;</span> Party
                              </a>
                              <br>
                              <a ng-click="queryStatus('nonParty')" class="color-grey" ng-href="#">
                                  <span class="label label-default">&nbsp;</span> Non-Party
                              </a>
                          </div>
                          </div>



                         <div id="filterCheckboxes">
                             <search-filter-schemas  ng-model='schemas' field='schema_s' query='querySchema' preview-type="previewType" selected-filters="selectedSchemaFilters"></search-filter-schemas>

                             <a href="" ng-click="loadThemes=true;" data-toggle="modal" data-target="#themeModal" class="color-black"><h4>Thematic Areas</h4></a>
                             <a href="" data-toggle="modal" data-target="#countryModal" class="color-black"><h4>Countries</h4></a>
                             <a href="" ng-click="loadRegions=true;"data-toggle="modal" data-target="#regionModal" class="color-black"><h4>Regions</h4></a>


                         </div>
                          <!-- <div class="form-group">
                           <label for="sortby">Sort By</label>
                           <select ng-options="obj.value as obj.label for obj in sortOptions" ng-model="sortBy" class="form-control" ng-change="sortResults()" id="sortby"></select>
                         </div> -->




             </md-content>

         </md-sidenav>


         <md-content flex layout-margin style="margin:0 30px 30px 30px;padding:0;background-color:transparent;"  >






             <div layout="column" layout-align="top center"  >

                 <md-button ng-click="toggleLeft()" class="md-primary md-raised bg-medgrey" hide-gt-lg  style="width:100%;margin: 0  0 10px 0;">
                     <i class="material-icons" style="position:relative;top:6px;">menu</i> Search Filters
                 </md-button>

                  <div layout="row" layout-align="top center"  >

                    <div flex="66">
                        <button class="btn btn-primary" type="button" ng-show="partyStatusString"
                         ng-click="queryStatus()"
                                style="margin-right:2px;margin-bottom:2px">
                                {{partyStatusString}}
                             <span class="badge" >{{partyStatusString=="Non parties" ? nonPartiesCount : partiesCount}}</span>
                             &nbsp;<span aria-hidden="true">&times;</span>
                        </button>

                        <button class="btn btn-primary" type="button" ng-repeat="filter in selectedSchemaFilters" ng-click="removeFilter(filter)"
                                style="margin-right:2px;margin-bottom:2px">
                            {{filter.isTerm ? (filter.value|term) : filter.value}}
                             <span class="badge" >{{filter.count}}</span>
                             &nbsp;<span aria-hidden="true">&times;</span>
                        </button>
                       <button class="btn btn-primary" type="button"
                        ng-repeat="filter in countryApi.getSelected()"
                        ng-click="removeCountryFilter(filter)"
                               style="margin-right:2px;margin-bottom:2px">
                           {{filter.name|lstring}}
                            <span class="badge" >{{filter.count}}</span>
                            &nbsp;<span aria-hidden="true">&times;</span>
                       </button>
                       <button class="btn btn-primary" type="button"
                        ng-repeat="filter in thematicAreaApi.getSelected()"
                        ng-click="removeThematicAreaFilter(filter)"
                               style="margin-right:2px;margin-bottom:2px">
                           {{filter.title|lstring}}
                            <span class="badge" >{{filter.count}}</span>
                            &nbsp;<span aria-hidden="true">&times;</span>
                       </button>
                       <button class="btn btn-primary" type="button"
                        ng-repeat="filter in regionsApi.getSelected()"
                        ng-click="removeRegionFilter(filter)"
                               style="margin-right:2px;margin-bottom:2px">
                           {{filter.title|lstring}}
                            <span class="badge" >{{filter.count}}</span>
                            &nbsp;<span aria-hidden="true">&times;</span>
                       </button>
                    </div>

                    <div flex="33" class="text-right">
                        <div class="btn-group" role="group">
                          <button type="button" class="btn btn-default"  ng-class="{'bg-blue':previewType=='list' }"   ng-click="previewType='list'"><i class="fa fa-list"/> List records </button>
                          <button type="button" class="btn btn-default"  ng-class="{'bg-blue': previewType=='group' }" ng-click="previewType='group'" ><i class="fa fa-th-large"/> Group by country</button>
                        </div>
                    </div>

                  </div>

                 <search-filter-themes api="thematicAreaApi" title='Thematic Areas' ng-model='thematicAreas' field='thematicAreas_ss' query='queryTheme'></search-filter-themes>
                 <search-filter-countries api="countryApi" title='Countries' ng-model='governments' field='government_s' query='queryGovernment' external-filter="countryResultFilter"></search-filter-countries>
                 <search-filter-regions api="regionsApi" title="Regions" ng-model="regions" field="government_REL_ss" query="queryRegion" facets="regionFacets"></search-filter-regions>


                <div preview-type="previewType" document-list documents='rawDocs' filter='*' show-pagination='true' current-page='currentPage' document-Count='documentCount' order-by="orderBy">
{'fraction_non_alphanumeric': 0.1500527917520651, 'fraction_numerical': 0.009316191540898081, 'mean_word_length': 1.7819626814098135, 'pattern_counts': {'":': 0, '<': 243, '<?xml version=': 0, '>': 243, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '485954', 'n_tokens_mistral': 4484, 'n_tokens_neox': 4122, 'n_words': 698}