<commit_before><div ng-controller="MainCtrl">
	<alert ng-repeat="alert in alerts" type="{{alert.type}}">{{alert.msg}}</alert>

	<h2>Perfect Your Durfee Swipe</h2>
	<p>Top off your lunch swipe every time.</p>

	<div id="shopping-bag-list" ng-show="srvc.model.shoppingBag.items.length">
		<p>Your Bag:</p>
		<ul ng-repeat="item in srvc.model.shoppingBag.items">
			<li>
				{{item.name}} (x{{item.count}}): {{item.price * item.count | currency}} 
				<a href="#" ng-click="removeItemFromBag(item);">remove</a>
			</li>
		</ul>
	</div>
	<p>Total price: {{srvc.model.shoppingBag.totalPrice | currency}}</p>
	<p>
		Remaining credit: {{srvc.model.shoppingBag.remainingCredit(srvc.model) | currency}}
		<button ng-click="openCreditLimitModal();" type="button">Adjust Credit Limit</button>
	</p>

	<form id="lookup-form" ng-submit="lookUpItem();" novalidate>
		<input ng-model="srvc.model.searchInput" type="text" 
			placeholder=" search for products"
			typeahead="item as item.name for item in products | filter:{'name':$viewValue} | limitTo:8"
			typeahead-template-url="typeahead.html"
			typeahead-on-select="onItemSelected();">
		<input type="submit" value="Submit">
	</form>

	<div id="suggestions">
		<br>
		<button ng-click="toggleSuggestions();" type="button">{{srvc.model.suggestionsLabel}}</button>
		<ul ng-show="displaySuggestions();" ng-repeat="item in productsUnderLimit()">
			<li>
				{{item.name}}: {{item.price | currency}}
				<a href="#" ng-click="addItemToBag(item)">add</a>
			</li>
			<li ng-show="!productsUnderLimit().length">
				No products found; remaining credit too low.
			</li>
		</ul>
	</div>
	<br>
</div>

<script type="text/ng-template" id="creditLimitModal.html">
	<form name="creditLimitForm" ng-submit="updateCreditLimit($scope.newCreditLimit);">
		<div class="modal-header">
			<h3>Adjust the credit limit</h3>
		</div>
		<div class="modal-body">
			<p>Enter a new credit limit:</p>
			<input type="number" name="input" ng-model="$scope.newCreditLimit" min="0" required>
		</div>
		<div class="modal-footer">
			<button type="submit">Update Limit</button><commit_msg>Fixed no products found display error<commit_after><div ng-controller="MainCtrl">
	<alert ng-repeat="alert in alerts" type="{{alert.type}}">{{alert.msg}}</alert>

	<h2>Perfect Your Durfee Swipe</h2>
	<p>Top off your lunch swipe every time.</p>

	<div id="shopping-bag-list" ng-show="srvc.model.shoppingBag.items.length">
		<p>Your Bag:</p>
		<ul ng-repeat="item in srvc.model.shoppingBag.items">
			<li>
				{{item.name}} (x{{item.count}}): {{item.price * item.count | currency}} 
				<a href="#" ng-click="removeItemFromBag(item);">remove</a>
			</li>
		</ul>
	</div>
	<p>Total price: {{srvc.model.shoppingBag.totalPrice | currency}}</p>
	<p>
		Remaining credit: {{srvc.model.shoppingBag.remainingCredit(srvc.model) | currency}}
		<button ng-click="openCreditLimitModal();" type="button">Adjust Credit Limit</button>
	</p>

	<form id="lookup-form" ng-submit="lookUpItem();" novalidate>
		<input ng-model="srvc.model.searchInput" type="text" 
			placeholder=" search for products"
			typeahead="item as item.name for item in products | filter:{'name':$viewValue} | limitTo:8"
			typeahead-template-url="typeahead.html"
			typeahead-on-select="onItemSelected();">
		<input type="submit" value="Submit">
	</form>

	<div id="suggestions">
		<br>
		<button ng-click="toggleSuggestions();" type="button">{{srvc.model.suggestionsLabel}}</button>
		<div ng-show="displaySuggestions();">
			<ul ng-repeat="item in productsUnderLimit()">
				<li>
					{{item.name}}: {{item.price | currency}}
					<a href="#" ng-click="addItemToBag(item)">add</a>
				</li>
			</ul>
			<p ng-show="!productsUnderLimit().length">
				No products found; remaining credit too low.
			</p>
		</div>
	</div>
	<br>
</div>

<script type="text/ng-template" id="creditLimitModal.html">
	<form name="creditLimitForm" ng-submit="updateCreditLimit($scope.newCreditLimit);">
		<div class="modal-header">
			<h3>Adjust the credit limit</h3>
		</div>
		<div class="modal-body">
			<p>Enter a new credit limit:</p>
			<input type="number" name="input" ng-model="$scope.newCreditLimit" min="0" required>
		</div>
		<div class="modal-footer">
			<button type="submit">Update Limit</button>
{'fraction_non_alphanumeric': 0.1980221332705439, 'fraction_numerical': 0.0028255238992229807, 'mean_word_length': 4.891816920943135, 'pattern_counts': {'":': 0, '<': 117, '<?xml version=': 0, '>': 117, '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': '3783402', 'n_tokens_mistral': 1670, 'n_tokens_neox': 1491, 'n_words': 296}