<template name="messageSearch">
	<div class="content">
		<div class="list-view search-messages-list">
			<div class="title">
				<h2>{{_ "Search_Messages"}}</h2>
				<p>{{_ "You_can_search_using_RegExp_eg"}} <code class="code-colors inline">/^text$/i</code></p>
			</div>
			<div class="control">
				<form class="search-form" role="form">
					<div class="input-line search">
						<input type="text" id="message-search" class="search content-background-color" placeholder="{{tSearchMessages}}" autocomplete="off" />
						<i class="icon-search secondary-font-color"></i>
					</div>
				</form>
			</div>
			{{#if currentSearchTerm}}
				{{#unless searchResultMessages}}
					<h2>{{_ "No_results_found"}}</h2>
				{{/unless}}
			{{/if}}
		</div>
		{{#if currentSearchTerm}}
			{{#if searchResultMessages}}
				<ul class="list clearfix">
					{{#each searchResultMessages}}
						{{#nrr nrrargs 'message' message}}{{/nrr}}
					{{/each}}
				</ul>
				{{#if hasMore}}
					<div class="load-more">
						{{> loading}}
					</div>
				{{/if}}
			{{/if}}
		{{/if}}
	</div>
</template>
