mirror of
https://github.com/discourse/discourse.git
synced 2025-06-05 14:07:30 +08:00
DEV: Import every instance of Ember.computed function (#8267)
* DEV: Import every instance of Ember.computed function * export default for Ember.computed
This commit is contained in:

committed by
GitHub

parent
790a7e2095
commit
2ae21e9c35
@ -1,3 +1,4 @@
|
||||
import { gt, and } from "@ember/object/computed";
|
||||
import { schedule } from "@ember/runloop";
|
||||
import Component from "@ember/component";
|
||||
import {
|
||||
@ -13,9 +14,9 @@ export default Component.extend({
|
||||
childrenExpanded: false,
|
||||
classNames: ["themes-list-item"],
|
||||
classNameBindings: ["theme.selected:selected"],
|
||||
hasComponents: Ember.computed.gt("children.length", 0),
|
||||
displayComponents: Ember.computed.and("hasComponents", "theme.isActive"),
|
||||
displayHasMore: Ember.computed.gt("theme.childThemes.length", MAX_COMPONENTS),
|
||||
hasComponents: gt("children.length", 0),
|
||||
displayComponents: and("hasComponents", "theme.isActive"),
|
||||
displayHasMore: gt("theme.childThemes.length", MAX_COMPONENTS),
|
||||
|
||||
click(e) {
|
||||
if (!$(e.target).hasClass("others-count")) {
|
||||
|
Reference in New Issue
Block a user