DEV: ember-cli refactor for TextField and TextArea imports (#9480)
In order to be able to use ember-cli we need to fix the import statements for `TextField` and `TextArea` in the code base. The only change I don't fully understand is the one in `discourse-loader.js`, but adding the components to that file make it all work.
This commit is contained in:
parent
e49212d0bc
commit
5b98161f2f
|
@ -19,9 +19,7 @@ var define, requirejs;
|
||||||
default: Ember.ArrayProxy
|
default: Ember.ArrayProxy
|
||||||
},
|
},
|
||||||
"@ember/component": {
|
"@ember/component": {
|
||||||
default: Ember.Component,
|
default: Ember.Component
|
||||||
TextArea: Ember.TextArea,
|
|
||||||
TextField: Ember.TextField
|
|
||||||
},
|
},
|
||||||
"@ember/controller": {
|
"@ember/controller": {
|
||||||
default: Ember.Controller,
|
default: Ember.Controller,
|
||||||
|
@ -129,6 +127,12 @@ var define, requirejs;
|
||||||
"@ember/component/helper": {
|
"@ember/component/helper": {
|
||||||
default: Ember.Helper
|
default: Ember.Helper
|
||||||
},
|
},
|
||||||
|
"@ember/component/text-field": {
|
||||||
|
default: Ember.TextField
|
||||||
|
},
|
||||||
|
"@ember/component/text-area": {
|
||||||
|
default: Ember.TextArea
|
||||||
|
},
|
||||||
"@ember/error": {
|
"@ember/error": {
|
||||||
default: Ember.error
|
default: Ember.error
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { TextArea } from "@ember/component";
|
import TextArea from "@ember/component/text-area";
|
||||||
import { schedule } from "@ember/runloop";
|
import { schedule } from "@ember/runloop";
|
||||||
import { on, observes } from "discourse-common/utils/decorators";
|
import { on, observes } from "discourse-common/utils/decorators";
|
||||||
import autosize from "discourse/lib/autosize";
|
import autosize from "discourse/lib/autosize";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { TextField } from "@ember/component";
|
import TextField from "discourse/components/text-field";
|
||||||
import { on } from "discourse-common/utils/decorators";
|
import { on } from "discourse-common/utils/decorators";
|
||||||
|
|
||||||
export default TextField.extend({
|
export default TextField.extend({
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { TextField } from "@ember/component";
|
import TextField from "discourse/components/text-field";
|
||||||
import discourseComputed from "discourse-common/utils/decorators";
|
import discourseComputed from "discourse-common/utils/decorators";
|
||||||
|
|
||||||
export default TextField.extend({
|
export default TextField.extend({
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { TextField } from "@ember/component";
|
import TextField from "@ember/component/text-field";
|
||||||
import discourseComputed from "discourse-common/utils/decorators";
|
import discourseComputed from "discourse-common/utils/decorators";
|
||||||
import { siteDir, isRTL, isLTR } from "discourse/lib/text-direction";
|
import { siteDir, isRTL, isLTR } from "discourse/lib/text-direction";
|
||||||
import { next, debounce, cancel } from "@ember/runloop";
|
import { next, debounce, cancel } from "@ember/runloop";
|
||||||
|
|
Loading…
Reference in New Issue