<commit_before><form novalidate name="contentForm"
    ng-controller="Umbraco.Dialogs.Template.QueryBuilderController"
    ng-submit="close()"
    val-form-manager>
	
	<style>
		.umb-querybuilder .row {font-size: 12px; line-height: 12px}

		.umb-querybuilder .row a.btn{font-size: 12px; background: lightyellow}

		.umb-querybuilder .row > div{
			padding: 20px;
			border-bottom: 1px solid #efefef;
		}
	</style>

	<div class="umb-panel">

		<div class="umb-panel-header">
		    <h1 class="headline" style="margin: 10px 0 0 0">Build a query</h1>
		</div>

		<div class="umb-panel-body with-footer umb-querybuilder">
			  
			  <div class="row">  
  					<div>
  						I want

  						<div class="btn-group">
  						  <a class="btn btn-link dropdown-toggle" 
  						  		data-toggle="dropdown" href="#">
  						    		{{query.contentType.name}}
  						    <span class="caret"></span>
  						  </a>
  						    <ul class="dropdown-menu">
  						        <li ng-repeat="contentType in contentTypes">
  						            <a href ng-click="query.contentType = contentType">
  						                {{contentType.name}}
  						            </a>
  						        </li>

  						    </ul>
  						</div>	

  						<span>from</span> 
  						
  						<a href class="btn btn-link"  ng-click="chooseSource(query)">
  								{{query.source.name}}
  								<span class="caret"></span>	
  						</a>
  					</div>

			      <div ng-repeat="filter in query.filters">
			          
			          <span ng-if="$first">Where</span>
			          <span ng-if="!$first">And</span>

			          <div class="btn-group">

			              <a class="btn btn-link dropdown-toggle" 
			                 data-toggle="dropdown" href="#">
			                  {{filter.property.name}}
			                  <span class="caret"></span>
			              </a>

			              <ul class="dropdown-menu">
			                  <li ng-repeat="property in properties">
			                      <a href ng-click="filter.property = property">
			                          {{property.name}}
			                      </a>
			                  </li>
			              </ul>

			          </div>
						
			          <div class="btn-group" ng-if="filter.property">
			              <a class="btn btn-link dropdown-toggle" 
			                 data-toggle="dropdown" href="#">
			                  {{filter.term.name}}
			                  <span class="caret"></span>
			              </a>
			              <ul class="dropdown-menu">
			                  <li ng-repeat="term in getPropertyOperators(filter.property)">
			                      <a href ng-click="filter.term = term">
			                          {{term.name}}
			                      </a>
			                  </li>
			              </ul>
			          </div>

			          <input type="text" ng-if="filter.term" style="width:90px;" ng-model="filter.constraintValue" />
                 
			          <a href ng-click="addFilter(query)">
			              <i class="icon-add"></i>
			          </a>
                      
                    <a href ng-if="query.filters.length > 1" ng-click="trashFilter(query)">
                        <i class="icon-trash"></i>
                    </a>
                         
			      </div>	


					
			      <div>
						
						Order by 

						<div class="btn-group">
						  <a class="btn btn-link dropdown-toggle" 
						  		data-toggle="dropdown" href="#">
						    		{{query.sort.property.name}}
						    <span class="caret"></span>
						  </a>

						  <ul class="dropdown-menu">
						  	<li ng-repeat="property in properties">
						  		<a href ng-click="setSortProperty(query, property)">
					  				{{property.name}}
					  			</a>
						  	</li>
						  </ul>
						  
						</div>


						<a href class="btn" ng-click="changeSortOrder(query)">
							{{query.sort.direction}}
						</a>
					</div>
			  </div>
                    
		    
            <h4>Returns {{result.resultCount}} items in {{result.executionTime}} miliseconds</h4>
               
		    <ul class="nav unstyled">
			    <li ng-repeat="item in result.sampleResults">
		                  <i class="icon icon-document blue"></i> {{item.name}}
			          </li>
            </ul>  
			
		    <pre>{{result.queryExpression}}</pre>
		</div>	

		<div class="umb-panel-footer" >
			<div class="umb-el-wrap umb-panel-buttons">
		        <div class="btn-toolbar umb-btn-toolbar pull-right">
		            <a href ng-click="close()" class="btn btn-link">
		                <localize key="general_close">Close</localize>
		            </a>
                    
                    <a href ng-click="submit(result.queryExpression)" class="btn btn-primary">Insert</a>
		        </div>
		      </div>
			</div>
		</div>
	</div>
</form><commit_msg>Localizing hardcoded strings<commit_after><form novalidate name="contentForm"
    ng-controller="Umbraco.Dialogs.Template.QueryBuilderController"
    ng-submit="close()"
    val-form-manager>
	
	<style>
		.umb-querybuilder .row {font-size: 12px; line-height: 12px}

		.umb-querybuilder .row a.btn{font-size: 12px; background: lightyellow}

		.umb-querybuilder .row > div{
			padding: 20px;
			border-bottom: 1px solid #efefef;
		}
	</style>

	<div class="umb-panel">

		<div class="umb-panel-header">
		    <h1 class="headline" style="margin: 10px 0 0 0"><localize key="templte_buildQuery">Build a query</localize></h1>
		</div>

		<div class="umb-panel-body with-footer umb-querybuilder">
			  
			  <div class="row">  
  					<div>
  						I want

  						<div class="btn-group">
  						  <a class="btn btn-link dropdown-toggle" 
  						  		data-toggle="dropdown" href="#">
  						    		{{query.contentType.name}}
  						    <span class="caret"></span>
  						  </a>
  						    <ul class="dropdown-menu">
  						        <li ng-repeat="contentType in contentTypes">
  						            <a href ng-click="query.contentType = contentType">
  						                {{contentType.name}}
  						            </a>
  						        </li>

  						    </ul>
  						</div>	

  						<span>from</span> 
  						
  						<a href class="btn btn-link"  ng-click="chooseSource(query)">
  								{{query.source.name}}
  								<span class="caret"></span>	
  						</a>
  					</div>

			      <div ng-repeat="filter in query.filters">
			          
			          <span ng-if="$first">Where</span>
			          <span ng-if="!$first">And</span>

			          <div class="btn-group">

			              <a class="btn btn-link dropdown-toggle" 
			                 data-toggle="dropdown" href="#">
			                  {{filter.property.name}}
			                  <span class="caret"></span>
			              </a>

			              <ul class="dropdown-menu">
			                  <li ng-repeat="property in properties">
			                      <a href ng-click="filter.property = property">
			                          {{property.name}}
			                      </a>
			                  </li>
			              </ul>

			          </div>
						
			          <div class="btn-group" ng-if="filter.property">
			              <a class="btn btn-link dropdown-toggle" 
			                 data-toggle="dropdown" href="#">
			                  {{filter.term.name}}
			                  <span class="caret"></span>
			              </a>
			              <ul class="dropdown-menu">
			                  <li ng-repeat="term in getPropertyOperators(filter.property)">
			                      <a href ng-click="filter.term = term">
			                          {{term.name}}
			                      </a>
			                  </li>
			              </ul>
			          </div>

			          <input type="text" ng-if="filter.term" style="width:90px;" ng-model="filter.constraintValue" />
                 
			          <a href ng-click="addFilter(query)">
			              <i class="icon-add"></i>
			          </a>
                      
                    <a href ng-if="query.filters.length > 1" ng-click="trashFilter(query)">
                        <i class="icon-trash"></i>
                    </a>
                         
			      </div>	


					
			      <div>
						
						Order by 

						<div class="btn-group">
						  <a class="btn btn-link dropdown-toggle" 
						  		data-toggle="dropdown" href="#">
						    		{{query.sort.property.name}}
						    <span class="caret"></span>
						  </a>

						  <ul class="dropdown-menu">
						  	<li ng-repeat="property in properties">
						  		<a href ng-click="setSortProperty(query, property)">
					  				{{property.name}}
					  			</a>
						  	</li>
						  </ul>
						  
						</div>


						<a href class="btn" ng-click="changeSortOrder(query)">
							{{query.sort.direction}}
						</a>
					</div>
			  </div>
                    
		    
            <h4>Returns {{result.resultCount}} items in {{result.executionTime}} miliseconds</h4>
               
		    <ul class="nav unstyled">
			    <li ng-repeat="item in result.sampleResults">
		                  <i class="icon icon-document blue"></i> {{item.name}}
			          </li>
            </ul>  
			
		    <pre>{{result.queryExpression}}</pre>
		</div>	

		<div class="umb-panel-footer" >
			<div class="umb-el-wrap umb-panel-buttons">
		        <div class="btn-toolbar umb-btn-toolbar pull-right">
		            <a href ng-click="close()" class="btn btn-link">
		                <localize key="general_close">Close</localize>
		            </a>
                    
                    <a href ng-click="submit(result.queryExpression)" class="btn btn-primary"><localize key="general_insert">Insert</localize></a>
		        </div>
		      </div>
			</div>
		</div>
	</div>
</form>
{'fraction_non_alphanumeric': 0.15055320028952537, 'fraction_numerical': 0.004342880777582463, 'mean_word_length': 1.3527122354658234, 'pattern_counts': {'":': 0, '<': 231, '<?xml version=': 0, '>': 235, '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': '6002680', 'n_tokens_mistral': 3766, 'n_tokens_neox': 2770, 'n_words': 525}