mirror of
https://github.com/discourse/discourse.git
synced 2024-11-29 02:36:18 +08:00
1a78e12f4e
- moderation tab - sorting/pagination - improved third party reports support - trending charts - better perf - many fixes - refactoring - new reports Co-Authored-By: Simon Cossar <scossar@users.noreply.github.com>
19 lines
590 B
JavaScript
19 lines
590 B
JavaScript
import computed from "ember-addons/ember-computed-decorators";
|
|
|
|
export default Ember.Component.extend({
|
|
tagName: "th",
|
|
classNames: ["admin-report-table-header"],
|
|
classNameBindings: ["label.property", "isCurrentSort"],
|
|
attributeBindings: ["label.title:title"],
|
|
|
|
@computed("currentSortLabel.sort_property", "label.sort_property")
|
|
isCurrentSort(currentSortField, labelSortField) {
|
|
return currentSortField === labelSortField;
|
|
},
|
|
|
|
@computed("currentSortDirection")
|
|
sortIcon(currentSortDirection) {
|
|
return currentSortDirection === 1 ? "caret-up" : "caret-down";
|
|
}
|
|
});
|