Commit Graph

49 Commits

Author SHA1 Message Date
Zdravko Curic d0d5f0c912
DEV: Add Ember.PromiseProxyMixin to ember modules (#9312) 2020-03-30 11:37:14 -04:00
Jarek Radosz 48ba65f406
DEV: Clean up Ember imports (#8979)
Includes:
* Import `computed` helpers
* Import `@ember/application`
* Import `isBlank` from `@ember/utils`
* Import `A` from `@ember/array`
* Import `EmberArray` from `@ember/array`
* Import `ArrayProxy` from `@ember/array/proxy`
* Import `warn` from `@ember/debug`
* Import `EmberObject` from `@ember/object`
* Import `Application` from `@ember/application`
* Import `EmberRouter` from `@ember/routing/router`
* Import `isPresent` from `@ember/utils`
* Import `computed` from `@ember/object`
* Import `guidFor` from `@ember/object`
* Import `isArray` from `@ember/array`
* Import `TextField` from `@ember/component`
* Import `TextArea` from `@ember/component`
* Import `Promise` from `rsvp`
* Import `Evented` from `@ember/object/evented`
* Replace deprecated `ember-addons/ember-computed-decorators` imports
2020-03-06 23:49:28 +01:00
Jarek Radosz c607870f08
DEV: Add more `@ember` imports (#9012) 2020-02-21 14:27:04 +01:00
Joffrey JAFFEUX 25ebfd5998
DEV: allows to import isPresent (#8993) 2020-02-18 23:41:15 +01:00
Mark VanLandingham 499b57a9ed
DEV: Ember linting - disallow Ember.* variable usage (#8782) 2020-02-05 10:14:42 -06:00
Jarek Radosz 4ab696dd2f
DEV: Add the `@action` decorator (#8836)
This also enables`@action` use in plugin connectors.

Setting `actions` earlier allows `setupComponents` to use them, for example, when setting up event listeners.
2020-02-04 11:42:25 +01:00
Mark VanLandingham 94e8fd68bf
FIX: Remove uneeded from discourse loader (#8390) 2019-11-21 11:46:27 -06:00
Mark VanLandingham 5ba63f8a98
FIX: Aliases for require functioning (#8387) 2019-11-21 11:39:50 -06:00
Robin Ward 947416004f FIX: EventTarget error 2019-11-20 15:51:42 -05:00
Robin Ward d7ae052efe DEV: Don't allow `Promise` unless imported from `"rsvp"`
We want to make sure we are using the correct promise implementation so
let's lint out the browser version.
2019-11-20 15:24:59 -05:00
Daniel Waterworth d541183906 DEV: Make it possible to deprecate plugin outlet properties 2019-11-20 13:56:26 +00:00
Robin Ward f518065654 FIX: computed is part of `@ember/object` not `@ember/object/computed` 2019-11-13 11:58:09 -05:00
romanrizzi c9bd463e9d DEV: Let is not supported, use var instead 2019-11-12 14:58:16 -03:00
Mark VanLandingham 213ebc3b32
DEV: Deprecation warning for aliased module usage (#8341) 2019-11-12 10:20:14 -06:00
Robin Ward 34665d3f96 FIX: In case `@ember/object` hasn't been loaded yet 2019-11-11 15:56:58 -05:00
Robin Ward e39d89ecd9 REFACTOR: Remove `InputValidation` which was simply an `Ember.Object` 2019-11-11 15:48:56 -05:00
Mark VanLandingham 20266325fc combined import definitions in discourse-loader 2019-11-11 10:37:21 -05:00
Mark VanLandingham 1bbb9b30fc DEV: Import isNone for @ember/utils 2019-11-11 10:37:21 -05:00
Mark VanLandingham e51efce356
DEV: Remove all instances of Ember.computed (#8324) 2019-11-08 12:28:11 -06:00
Mark VanLandingham 47e3e56905
FIX: Alias modules that are required AND imported (#8315) 2019-11-08 09:48:02 -06:00
Mark VanLandingham 6275c05c0d
DEV: Move computed to discourseComputed (#8312) 2019-11-07 15:38:28 -06:00
Mark VanLandingham 9ffdbf912f
DEV: Import ember ENV instead of Ember.testing (#8305) 2019-11-07 11:20:35 -06:00
Mark VanLandingham edc135d9c5
DEV: Import set, setProperties, helper, and string functions (#8297) 2019-11-05 12:43:49 -06:00
Mark VanLandingham 014f19b6ea
DEV: Import Promise from rsvp (#8296) 2019-11-05 10:37:32 -06:00
Mark VanLandingham fa56ba89a5 Import getProperties from @ember/object 2019-11-04 14:24:30 -05:00
Robin Ward 640a05c4ee REFACTOR: Remove `Ember.get` 2019-11-01 13:50:15 -04:00
Robin Ward 90f934a660 REFACTOR: Use a module for `Ember.isEmpty` 2019-11-01 13:50:15 -04:00
Mark VanLandingham 11f50eee3b
DEV: Remove pretty_text import hack & still work server-side (#8266)
* FIX: move attachment_css_class constant out of upload-short-url for discourse-markdown-it

* Use setTimeout instead of ember later

* WIP. Not sure if this worked.

* oneboxer cache in separate file

* Reset onebox cache still

* set functions for oneboxers cache
2019-10-31 11:54:46 -05:00
Mark VanLandingham 02a886ce13
DEV: Import `Ember.on` from @ember/object/evented (#8268)
* DEV: Import `Ember.on` from @ember/object/evented

* Dont import "on" outsie of the js or admin app

* Fixed error when resolving merge conflicts
2019-10-30 17:05:27 -05:00
Mark VanLandingham 2ae21e9c35
DEV: Import every instance of Ember.computed function (#8267)
* DEV: Import every instance of Ember.computed function

* export default for Ember.computed
2019-10-30 15:28:29 -05:00
Mark VanLandingham ba4b557114 DEV: Remove Ember.Mixin to import @ember/object/mixin (#8269) 2019-10-30 15:03:08 -04:00
Robin Ward 8d34f4bbd9 Revert "Revert Ember.run refactors"
This reverts commit fcb1ca52f9.
2019-10-30 09:48:24 -04:00
Robin Ward fcb1ca52f9 Revert Ember.run refactors
This reverts commit 5ca60fcb6b.
2019-10-29 17:10:47 -04:00
Robin Ward cfa5d123a3 Temporary fix: Don't use ember imports in pretty text 2019-10-29 16:45:05 -04:00
Robin Ward 249dff85c7 FIX: Use modules for `Ember.run.debounce` hack in testing 2019-10-29 16:25:37 -04:00
Robin Ward 5ca60fcb6b REFACTOR: Use imports for `Ember.run` 2019-10-29 15:31:56 -04:00
Mark VanLandingham c7475ee03b
DEV: Import EmberObject rather than global variable (#8256)
* DEV: Import ember/object rather than Ember.Object globally

* fixed broken object proxy import

* prettier on js

* added @ember/object/proxy to loader

* added unstaged file

* Fixed objet proxy reference is loader

* Linting!
2019-10-29 14:23:50 -05:00
Robin Ward 230541c975 REFACTOR: Use Ember modules for `@ember/service` 2019-10-29 13:29:08 -04:00
Robin Ward a99c705c21 REFACTOR: Replace `Ember.controller.inject` with import
Puts it more in line with updated ember code
2019-10-29 13:17:38 -04:00
Robin Ward 9347108f02 Support for importing jQuery
Also remove Ember.Qunit error about Ember.$ for now
2019-10-23 13:25:25 -04:00
Robin Ward e18af18fec Support and examples for `Ember.Object` and `Ember.Controller` imports
We should stop using global variables and instead import these as
needed.
2019-10-23 12:55:11 -04:00
Robin Ward 283a0add80
Support for importing `@ember/component` and `@ember/routing/route` (#8214)
This will allow us to take the first step in updating our modules
to be consistent with example Ember code and to align with Ember CLI.
2019-10-22 09:47:27 -04:00
Robin Ward 3085b923f6 Removed `MOVED_MODULES` which is 3 years old 2019-10-21 11:59:13 -04:00
Robin Ward 9dcdbcfd5b Run prettier on the loader 2019-10-21 11:56:15 -04:00
Régis Hanol 0f5aeab003 DEV: enable no-alert & no-console eslint rules 2018-11-14 23:17:56 +01:00
Robin Ward 754c1e5438 Upgrade to Babel 6 2017-07-05 15:25:23 -04:00
Robin Ward daabdd2ccf FIX: Topic status icons weren't being displayed 2016-11-21 16:18:41 -05:00
Robin Ward edd49bc953 FIX: ESLint 2016-11-15 12:10:18 -05:00
Robin Ward 0f9e45f283 Allow the loader to understand when files are moved 2016-11-15 11:41:16 -05:00