Merge remote-tracking branch 'origin/master' into search1093-b

Conflicts:
	platform/search/res/templates/search.html
This commit is contained in:
Charles Hacskaylo 2016-08-08 17:51:39 -07:00
parent 8105a7edb8
commit f3bd88837f

View File

@ -19,52 +19,62 @@
this source code distribution or the Licensing information page available this source code distribution or the Licensing information page available
at runtime from the About dialog for additional information. at runtime from the About dialog for additional information.
--> -->
<div class="l-flex-col flex-elem grows holder holder-search" ng-controller="SearchController as controller"> <div class="angular-w" ng-controller="SearchController as controller">
<div class="search-bar flex-elem" <div class="l-flex-col flex-elem grows holder holder-search" ng-controller="SearchMenuController as menuController">
ng-controller="ToggleController as toggle" <div class="search-bar flex-elem l-flex-row"
ng-class="{ holder: !(ngModel.input === '' || ngModel.input === undefined) }"> ng-controller="ToggleController as toggle"
<input class="search-input" ng-class="{ holder: !(ngModel.input === '' || ngModel.input === undefined) }">
type="text" <div class="holder flex-elem grows">
ng-model="ngModel.input" <input class="search-input"
ng-keyup="controller.search()"/> type="text"
<a class="clear-icon clear-input icon-x-in-circle" ng-model="ngModel.input"
ng-class="{show: !(ngModel.input === '' || ngModel.input === undefined)}" ng-keyup="controller.search()"/>
ng-click="ngModel.input = ''; controller.search()"></a> <a class="clear-icon clear-input icon-x-in-circle"
<!-- To prevent double triggering of clicks on click away, render ng-class="{show: !(ngModel.input === '' || ngModel.input === undefined)}"
non-clickable version of the button when menu active--> ng-click="ngModel.input = ''; controller.search()"></a>
<a ng-if="!toggle.isActive()" class="menu-icon context-available"
ng-click="toggle.toggle()"></a>
<a ng-if="toggle.isActive()" class="menu-icon context-available"></a>
<mct-include key="'search-menu'" <!-- To prevent double triggering of clicks on click away, render
class="menu-element search-menu-holder" non-clickable version of the button when menu active-->
ng-class="{off: !toggle.isActive()}" <a ng-if="!toggle.isActive()" class="menu-icon context-available"
ng-model="ngModel" ng-click="toggle.toggle()"></a>
parameters="{menuVisible: toggle.setState}"> <a ng-if="toggle.isActive()" class="menu-icon context-available"></a>
</mct-include>
</div>
<div class="active-filter-display flex-elem holder"
ng-class="{off: ngModel.filtersString === '' || ngModel.filtersString === undefined || !ngModel.search}"
ng-controller="SearchMenuController as menuController">
<a class="clear-icon clear-filters icon-x-in-circle"
ng-click="ngModel.checkAll = true; menuController.checkAll()"></a>Filtered by: {{ ngModel.filtersString }}
</div>
<div class="flex-elem holder results-msg" ng-model="ngModel" ng-show="!loading && ngModel.search"> <mct-include key="'search-menu'"
{{ class="menu-element search-menu-holder"
!results.length > 0? 'No results found': ng-class="{off: !toggle.isActive()}"
results.length + ' result' + (results.length > 1? 's':'') + ' found' ng-model="ngModel"
}} parameters="{menuVisible: toggle.setState}">
</div> </mct-include>
</div>
<div class="search-results flex-elem holder grows vscroll" <a class="holder s-button flex-elem btn-cancel"
ng-class="{ off: !(loading || results.length > 0), loading: loading }"> ng-show="!(ngModel.input === '' || ngModel.input === undefined)"
<mct-representation key="'search-item'" ng-click="ngModel.input = ''; ngModel.checkAll = true; menuController.checkAll(); controller.search()">
ng-repeat="result in results" Cancel</a>
mct-object="result.object" </div>
ng-model="ngModel"
class="l-flex-row flex-elem grows"> <div class="active-filter-display flex-elem holder"
</mct-representation> ng-class="{off: ngModel.filtersString === '' || ngModel.filtersString === undefined || !ngModel.search}">
<a class="load-more-button s-button vsm" ng-if="controller.areMore()" ng-click="controller.loadMore()">More Results</a> <a class="clear-filters icon-x-in-circle s-icon-button"
ng-click="ngModel.checkAll = true; menuController.checkAll()"></a>Filtered by: {{ ngModel.filtersString }}
</div>
<div class="flex-elem holder results-msg" ng-model="ngModel" ng-show="!loading && ngModel.search">
{{
!results.length > 0? 'No results found':
results.length + ' result' + (results.length > 1? 's':'') + ' found'
}}
</div>
<div class="search-results flex-elem holder grows vscroll"
ng-class="{ off: !(loading || results.length > 0), loading: loading }">
<mct-representation key="'search-item'"
ng-repeat="result in results"
mct-object="result.object"
ng-model="ngModel"
class="l-flex-row flex-elem grows">
</mct-representation>
<a class="load-more-button s-button vsm" ng-if="controller.areMore()" ng-click="controller.loadMore()">More Results</a>
</div>
</div> </div>
</div> </div>