Update the filtered tree styling

This commit is contained in:
scott1702 2015-08-24 14:59:41 +12:00
parent ab59113612
commit 4f05c4c4f8
4 changed files with 43 additions and 7 deletions

View File

@ -158,6 +158,19 @@
window.location = location.protocol + '//' + location.host + location.pathname;
}
});
$('.cms-tree-filtered').entwine({
onmatch: function () {
var self = this,
setHeight = function () {
var height = $('.cms-content-tools .cms-panel-content').height() - self.parent().siblings('.cms-content-toolbar').outerHeight(true);
self.css('height', height + 'px');
};
setHeight();
$(window).on('resize', window.ss.debounce(setHeight, 300));
}
});
});
}(jQuery));

View File

@ -94,7 +94,7 @@ en:
DUPLICATEDWITHCHILDREN: 'Duplicated ''{title}'' and children successfully'
EMAIL: Email
EditTree: 'Edit Tree'
ListFiltered: 'Filtered list.'
ListFiltered: 'Showing search results.'
MENUTITLE: 'Edit Page'
NEWPAGE: 'New {pagetype}'
PAGENOTEXISTS: 'This page doesn''t exist'
@ -122,7 +122,7 @@ en:
TabContent: Content
TabHistory: History
TabSettings: Settings
TreeFiltered: 'Search results.'
TreeFiltered: 'Showing search results.'
TreeFilteredClear: Clear
MENUTITLE: 'Edit Page'
ARCHIVE: Archive

View File

@ -6,15 +6,20 @@
<div class="cms-panel-content center">
<% if $TreeIsFiltered %>
<div class="cms-tree-filtered cms-notice">
<strong><% _t('CMSMain.ListFiltered', 'Filtered list.') %></strong>
<div class="cms-notice cms-tree-filtered">
<strong><% _t('CMSMain.ListFiltered', 'Showing search results.') %></strong>
<a href="$LinkPages" class="cms-panel-link">
<% _t('CMSMain.TreeFilteredClear', 'Clear') %>
</a>
<div class="cms-list" data-url-list="$Link(getListViewHTML)">
$ListViewForm
</div>
</div>
<% end_if %>
<% else %>
<div class="cms-list" data-url-list="$Link(getListViewHTML)">
$ListViewForm
</div>
<% end_if %>
</div>

View File

@ -9,12 +9,28 @@ $ExtraTreeTools
<div class="center">
<% if $TreeIsFiltered %>
<div class="cms-tree-filtered cms-notice">
<strong><% _t('CMSMain.TreeFiltered', 'Search results.') %></strong>
<strong><% _t('CMSMain.TreeFiltered', 'Showing search results.') %></strong>
<a href="javascript:void(0)" class="clear-filter">
<% _t('CMSMain.TreeFilteredClear', 'Clear') %>
</a>
<div class="cms-tree <% if $TreeIsFiltered %>filtered-list<% end_if %>"
data-url-tree="$LinkWithSearch($Link(getsubtree))"
data-url-savetreenode="$Link(savetreenode)"
data-url-updatetreenodes="$Link(updatetreenodes)"
data-url-addpage="{$LinkPageAdd('AddForm/?action_doAdd=1', 'ParentID=%s&amp;PageType=%s')}"
data-url-editpage="$LinkPageEdit('%s')"
data-url-duplicate="{$Link('duplicate/%s')}"
data-url-duplicatewithchildren="{$Link('duplicatewithchildren/%s')}"
data-url-listview="{$Link('?view=list')}"
data-hints="$SiteTreeHints.XML"
data-childfilter="$Link('childfilter')"
data-extra-params="SecurityID=$SecurityID">
$SiteTreeAsUL
</div>
</div>
<% end_if %>
<% else %>
<div class="cms-tree <% if $TreeIsFiltered %>filtered-list<% end_if %>"
data-url-tree="$LinkWithSearch($Link(getsubtree))"
@ -30,4 +46,6 @@ $ExtraTreeTools
data-extra-params="SecurityID=$SecurityID">
$SiteTreeAsUL
</div>
<% end_if %>
</div>